Fix tests passing
authorDaniel Kos <daniel.kos@contractors.roche.com>
Wed, 6 Jun 2018 06:44:10 +0000 (08:44 +0200)
committerDaniel Kos <daniel.kos@contractors.roche.com>
Wed, 6 Jun 2018 06:44:40 +0000 (08:44 +0200)
Feature #13535

Arvados-DCO-1.1-Signed-off-by: Daniel Kos <daniel.kos@contractors.roche.com>:

src/components/project-list/project-list.tsx
src/components/tree/tree.test.tsx [new file with mode: 0644]
src/views/workbench/workbench.test.tsx
tsconfig.test.json

index 3526da391cd6d2585140b9c993d31029f676a674..ec16a677f45a83926f7ec79d15c17913ba10d10a 100644 (file)
@@ -4,9 +4,8 @@
 
 import * as React from 'react';
 import { Theme } from "@material-ui/core";
 
 import * as React from 'react';
 import { Theme } from "@material-ui/core";
-import { StyleRulesCallback, WithStyles } from "@material-ui/core/styles";
+import { StyleRulesCallback, WithStyles, withStyles } from "@material-ui/core/styles";
 import Paper from "@material-ui/core/Paper/Paper";
 import Paper from "@material-ui/core/Paper/Paper";
-import withStyles from "@material-ui/core/es/styles/withStyles";
 import Table from "@material-ui/core/Table/Table";
 import TableHead from "@material-ui/core/TableHead/TableHead";
 import TableRow from "@material-ui/core/TableRow/TableRow";
 import Table from "@material-ui/core/Table/Table";
 import TableHead from "@material-ui/core/TableHead/TableHead";
 import TableRow from "@material-ui/core/TableRow/TableRow";
diff --git a/src/components/tree/tree.test.tsx b/src/components/tree/tree.test.tsx
new file mode 100644 (file)
index 0000000..6a5f410
--- /dev/null
@@ -0,0 +1,3 @@
+// Copyright (C) The Arvados Authors. All rights reserved.
+//
+// SPDX-License-Identifier: AGPL-3.0
index f7128a7417f3c0cd1000205b701b27946ff4ffe0..b1657bc35f6de244ffc71db154bf467a1d9d6d54 100644 (file)
@@ -8,10 +8,19 @@ import Workbench from '../../views/workbench/workbench';
 import { Provider } from "react-redux";
 import configureStore from "../../store/store";
 import createBrowserHistory from "history/createBrowserHistory";
 import { Provider } from "react-redux";
 import configureStore from "../../store/store";
 import createBrowserHistory from "history/createBrowserHistory";
+import { ConnectedRouter } from "react-router-redux";
+
+const history = createBrowserHistory();
 
 it('renders without crashing', () => {
     const div = document.createElement('div');
     const store = configureStore({ projects: [], router: { location: null } }, createBrowserHistory());
 
 it('renders without crashing', () => {
     const div = document.createElement('div');
     const store = configureStore({ projects: [], router: { location: null } }, createBrowserHistory());
-    ReactDOM.render(<Provider store={store}><Workbench/></Provider>, div);
+    ReactDOM.render(
+        <Provider store={store}>
+            <ConnectedRouter history={history}>
+                <Workbench/>
+            </ConnectedRouter>
+        </Provider>,
+    div);
     ReactDOM.unmountComponentAtNode(div);
 });
     ReactDOM.unmountComponentAtNode(div);
 });
index 65ffdd493929cf996f7f185609fb9f3f7f14184b..2c7b284162f4cafdbef8875c7ae7cb517c8e7abd 100644 (file)
@@ -3,4 +3,4 @@
   "compilerOptions": {
     "module": "commonjs"
   }
   "compilerOptions": {
     "module": "commonjs"
   }
-}
\ No newline at end of file
+}