('copy');
const handleCopy = React.useCallback(() => {
@@ -34,5 +35,5 @@ export const CopyToClipboard: React.FunctionComponent<{
});
}, [value]);
const iconElement = icon === 'check' ? icons.check() : icon === 'cross' ? icons.cross() : icons.copy();
- return ;
+ return ;
};
diff --git a/packages/html-reporter/src/testCaseView.css b/packages/html-reporter/src/testCaseView.css
index d87cf3aacb..42f72bf438 100644
--- a/packages/html-reporter/src/testCaseView.css
+++ b/packages/html-reporter/src/testCaseView.css
@@ -73,4 +73,10 @@
display: flex;
flex-direction: row;
flex-wrap: wrap;
-}
\ No newline at end of file
+}
+
+.copy-button-container {
+ display: inline-flex;
+ margin-left: 8px;
+ vertical-align: bottom;
+}
diff --git a/packages/html-reporter/src/testCaseView.tsx b/packages/html-reporter/src/testCaseView.tsx
index 5bed3c8309..a9e8e1859f 100644
--- a/packages/html-reporter/src/testCaseView.tsx
+++ b/packages/html-reporter/src/testCaseView.tsx
@@ -26,6 +26,7 @@ import { TestResultView } from './testResultView';
import { linkifyText } from '@web/renderUtils';
import { hashStringToInt, msToString } from './utils';
import { clsx } from '@web/uiUtils';
+import { CopyToClipboard } from './copyToClipboard';
export const TestCaseView: React.FC<{
projectNames: string[],
@@ -74,6 +75,9 @@ function TestCaseAnnotationView({ annotation: { type, description } }: { annotat
{type}
{description && : {linkifyText(description)}}
+ {description &&
+
+ }
);
}