Skip to content

Commit e9dc8c7

Browse files
committed
day 26 - clean up tests & update CRA
1 parent eee9096 commit e9dc8c7

16 files changed

+9297
-5973
lines changed

day-26/nightwatch.json

+25-22
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,45 @@
11
{
2-
"src_folders" : ["tests"],
3-
"output_folder" : "reports",
2+
"src_folders": ["tests"],
3+
"output_folder": "reports",
44

5-
"selenium" : {
6-
"start_process" : false,
7-
"server_path" : "",
8-
"log_path" : "",
9-
"host" : "127.0.0.1",
10-
"port" : 4444,
11-
"cli_args" : {
12-
"webdriver.chrome.driver" : "",
13-
"webdriver.ie.driver" : ""
5+
"selenium": {
6+
"start_process": false,
7+
"server_path": "",
8+
"log_path": "",
9+
"host": "127.0.0.1",
10+
"port": 4444,
11+
"cli_args": {
12+
"webdriver.chrome.driver": "",
13+
"webdriver.ie.driver": ""
1414
}
1515
},
1616

17-
"test_settings" : {
18-
"default" : {
19-
"launch_url" : "http://localhost:3000",
20-
"selenium_port" : 4444,
21-
"selenium_host" : "localhost",
17+
"test_settings": {
18+
"default": {
19+
"launch_url": "http://localhost:3000",
20+
"selenium_port": 4444,
21+
"selenium_host": "localhost",
2222
"silent": true,
23-
"screenshots" : {
24-
"enabled" : false,
25-
"path" : ""
23+
"screenshots": {
24+
"enabled": false,
25+
"path": ""
2626
},
2727
"desiredCapabilities": {
2828
"browserName": "chrome",
2929
"javascriptEnabled": true,
30-
"acceptSslCerts": true
30+
"acceptSslCerts": true,
31+
"chromeOptions": {
32+
"w3c": false
33+
}
3134
}
3235
},
3336

34-
"chrome" : {
37+
"chrome": {
3538
"desiredCapabilities": {
3639
"browserName": "chrome",
3740
"javascriptEnabled": true,
3841
"acceptSslCerts": true
3942
}
4043
}
4144
}
42-
}
45+
}

day-26/package.json

+29-46
Original file line numberDiff line numberDiff line change
@@ -1,56 +1,39 @@
11
{
2-
"name": "30Days",
2+
"name": "day-26",
33
"version": "0.1.0",
44
"private": true,
5-
"devDependencies": {
6-
"@fullstackio/cqmd": "^5.0.6",
7-
"babel-jest": "^19.0.0",
8-
"babel-polyfill": "^6.23.0",
9-
"babel-preset-stage-0": "^6.22.0",
10-
"enzyme": "^2.8.0",
11-
"git-rev": "^0.2.1",
12-
"gray-matter": "^2.1.1",
13-
"highlight.js": "^9.10.0",
14-
"hljs": "^6.2.3",
15-
"jest-cli": "^19.0.2",
16-
"map-stream": "^0.0.7",
17-
"marked": "^0.3.6",
18-
"nodemon": "^1.11.0",
19-
"npm-run-all": "^4.0.2",
20-
"nunjucks": "^3.0.0",
21-
"react-addons-test-utils": "^15.4.2",
22-
"react-scripts": "0.9.5",
23-
"react-test-renderer": "^15.4.2",
24-
"redux-mock-store": "^1.2.2",
25-
"simple-git": "^1.69.0",
26-
"sinon": "^2.1.0",
27-
"vinyl-fs": "^2.4.4"
28-
},
295
"dependencies": {
30-
"autoprefixer": "^6.7.7",
6+
"@testing-library/jest-dom": "^4.2.4",
7+
"@testing-library/react": "^9.3.2",
8+
"@testing-library/user-event": "^7.1.2",
319
"font-awesome": "^4.7.0",
32-
"moment": "^2.18.1",
33-
"nightwatch": "^0.9.14",
34-
"postcss-cli": "^3.0.0",
35-
"postcss-import": "^9.1.0",
36-
"precss": "^1.4.0",
37-
"react": "^15.4.2",
38-
"react-dom": "^15.4.2",
39-
"react-frame-component": "^1.0.2",
40-
"react-redux": "^5.0.3",
41-
"react-router-dom": "^4.0.0",
42-
"redux": "^3.6.0"
10+
"nightwatch": "^1.3.2",
11+
"react": "^16.12.0",
12+
"react-dom": "^16.12.0",
13+
"react-redux": "^7.1.3",
14+
"react-router-dom": "^5.1.2",
15+
"react-scripts": "3.3.0",
16+
"redux": "^4.0.4"
4317
},
4418
"scripts": {
45-
"start": "npm-run-all -c --parallel start:*",
46-
"build": "npm-run-all build:*",
47-
"start:styles": "npm run build:styles -- --watch",
48-
"build:styles": "./node_modules/.bin/postcss --config postcss.config.js src/styles/index.css -o src/index.css",
49-
"start:react": "react-scripts start",
50-
"build:react": "react-scripts build",
51-
"start:render": "nodemon -w doc.md --exec 'npm run build:render'",
52-
"build:render": "node ./scripts/cqmd.js",
53-
"test": "react-scripts test --env=jsdom",
19+
"start": "react-scripts start",
20+
"build": "react-scripts build",
21+
"test": "react-scripts test",
5422
"eject": "react-scripts eject"
23+
},
24+
"eslintConfig": {
25+
"extends": "react-app"
26+
},
27+
"browserslist": {
28+
"production": [
29+
">0.2%",
30+
"not dead",
31+
"not op_mini all"
32+
],
33+
"development": [
34+
"last 1 chrome version",
35+
"last 1 firefox version",
36+
"last 1 safari version"
37+
]
5538
}
5639
}

day-26/postcss.config.js

-9
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
<?xml version="1.0" encoding="UTF-8" ?>
2+
<testsuites errors="0"
3+
failures="0"
4+
tests="4">
5+
6+
<testsuite name="auth-flow"
7+
errors="0" failures="0" hostname="" id="" package="auth-flow" skipped="0"
8+
tests="4" time="1.657" timestamp="">
9+
10+
<testcase name="get to login page" classname="auth-flow" time="0.8780" assertions="2">
11+
12+
13+
14+
15+
</testcase>
16+
17+
<testcase name="logging in" classname="auth-flow" time="0.4940" assertions="3">
18+
19+
20+
21+
22+
23+
24+
</testcase>
25+
26+
<testcase name="logging out" classname="auth-flow" time="0.2210" assertions="3">
27+
28+
29+
30+
31+
32+
33+
</testcase>
34+
35+
<testcase name="close" classname="auth-flow" time="0.06400" assertions="0">
36+
</testcase>
37+
38+
39+
40+
41+
42+
</testsuite>
43+
</testsuites>

day-26/src/components/Timeline/ActivityItem.js

-30
This file was deleted.

day-26/src/components/Timeline/Header.js

-54
This file was deleted.

0 commit comments

Comments
 (0)