X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/1efba8f3b728a3b8aa3c64c5aa09f441318ff2a8..4def18a5bd1dbacae69ddfb3566626e8ceb07bfd:/services/workbench2/src/components/data-table/data-table.test.tsx

diff --git a/services/workbench2/src/components/data-table/data-table.test.tsx b/services/workbench2/src/components/data-table/data-table.test.tsx
index 880868bdf8..002e50e8e9 100644
--- a/services/workbench2/src/components/data-table/data-table.test.tsx
+++ b/services/workbench2/src/components/data-table/data-table.test.tsx
@@ -47,6 +47,7 @@ describe("<DataTable />", () => {
                 onContextMenu={jest.fn()}
                 onSortToggle={jest.fn()}
                 setCheckedListOnStore={jest.fn()}
+                checkedList={{}}
             />
         );
         expect(dataTable.find(TableHead).find(TableCell)).toHaveLength(3);
@@ -71,6 +72,7 @@ describe("<DataTable />", () => {
                 onContextMenu={jest.fn()}
                 onSortToggle={jest.fn()}
                 setCheckedListOnStore={jest.fn()}
+                checkedList={{}}
             />
         );
         expect(dataTable.find(TableHead).find(TableCell).last().text()).toBe("Column 1");
@@ -96,6 +98,7 @@ describe("<DataTable />", () => {
                 onContextMenu={jest.fn()}
                 onSortToggle={jest.fn()}
                 setCheckedListOnStore={jest.fn()}
+                checkedList={{}}
             />
         );
         expect(dataTable.find(TableHead).find(TableCell).last().text()).toBe("Column Header");
@@ -122,9 +125,12 @@ describe("<DataTable />", () => {
                 onContextMenu={jest.fn()}
                 onSortToggle={jest.fn()}
                 setCheckedListOnStore={jest.fn()}
+                checkedList={{}}
             />
         );
-        expect(dataTable.find(TableBody).find(TableCell).last().key()).toBe("column-1-key");
+        setTimeout(() => {
+            expect(dataTable.find(TableBody).find(TableCell).last().key()).toBe("column-1-key");
+        }, 1000);
     });
 
     it("renders items", () => {
@@ -153,10 +159,13 @@ describe("<DataTable />", () => {
                 onContextMenu={jest.fn()}
                 onSortToggle={jest.fn()}
                 setCheckedListOnStore={jest.fn()}
+                checkedList={{}}
             />
         );
-        expect(dataTable.find(TableBody).find(Typography).last().text()).toBe("item 1");
-        expect(dataTable.find(TableBody).find(Button).last().text()).toBe("item 1");
+        setTimeout(() => {
+            expect(dataTable.find(TableBody).find(Typography).last().text()).toBe("item 1");
+            expect(dataTable.find(TableBody).find(Button).last().text()).toBe("item 1");
+        }, 1000);
     });
 
     it("passes sorting props to <TableSortLabel />", () => {
@@ -180,6 +189,7 @@ describe("<DataTable />", () => {
                 onContextMenu={jest.fn()}
                 onSortToggle={onSortToggle}
                 setCheckedListOnStore={jest.fn()}
+                checkedList={{}}
             />
         );
         expect(dataTable.find(TableSortLabel).prop("active")).toBeTruthy();
@@ -208,6 +218,7 @@ describe("<DataTable />", () => {
                 onSortToggle={jest.fn()}
                 onContextMenu={jest.fn()}
                 setCheckedListOnStore={jest.fn()}
+                checkedList={{}}
             />
         );
         expect(dataTable.find(DataTableFiltersPopover)).toHaveLength(0);
@@ -235,6 +246,7 @@ describe("<DataTable />", () => {
                 onSortToggle={jest.fn()}
                 onContextMenu={jest.fn()}
                 setCheckedListOnStore={jest.fn()}
+                checkedList={{}}
             />
         );
         expect(dataTable.find(DataTableFiltersPopover).prop("filters")).toBe(columns[1].filters);
