diff --git a/frontend/app/components/UsabilityTesting/UsabilityTesting.tsx b/frontend/app/components/UsabilityTesting/UsabilityTesting.tsx index 0982fa5e7..accfdc510 100644 --- a/frontend/app/components/UsabilityTesting/UsabilityTesting.tsx +++ b/frontend/app/components/UsabilityTesting/UsabilityTesting.tsx @@ -136,7 +136,7 @@ function TestsTable() { } > {uxtestingStore.tests.map((test) => ( - + ))} @@ -175,11 +175,16 @@ const statusMap = { closed: "Completed", } -function Row({ test }: { test: UxTListEntry }) { +function Row({ test, siteId }: { test: UxTListEntry, siteId: string }) { const link = usabilityTestingView(test.testId.toString()) const editLink = usabilityTestingEdit(test.testId.toString()) + const history = useHistory() + + const redirect = () => { + history.push(withSiteId(test.status === 'preview' ? editLink : link, siteId)) + } return ( -
+
} />