Skip to content

Commit

Permalink
revert improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
dcm committed Jul 8, 2020
1 parent 33f8054 commit acd2e00
Show file tree
Hide file tree
Showing 168 changed files with 6,602 additions and 6,491 deletions.
4 changes: 0 additions & 4 deletions testplan/web_ui/testing/.env

This file was deleted.

5 changes: 0 additions & 5 deletions testplan/web_ui/testing/.env.production

This file was deleted.

2 changes: 0 additions & 2 deletions testplan/web_ui/testing/.env.test

This file was deleted.

5 changes: 3 additions & 2 deletions testplan/web_ui/testing/.eslintignore
@@ -1,3 +1,4 @@
__tests__
__snapshots__
/build/
/node_modules/*
sampleReports.js
fakeReport.js
81 changes: 21 additions & 60 deletions testplan/web_ui/testing/.eslintrc.json
@@ -1,42 +1,21 @@
{
"env": {
"browser": true,
"es6": true,
"commonjs": true
"browser": 2,
"es6": 2,
"node": 2,
"commonjs": 2
},
"extends": [
"react-app"
],
"overrides": [
{
"files": [
"*.test.js",
"*.test.jsx",
"*.test.ts",
"*.test.tsx",
"./src/setupTests.js",
"./jest-puppeteer.config.js"
],
"env": {
"jest": true,
"node": true
},
"globals": {
"page": true,
"browser": true,
"context": true,
"jestPuppeteer": true
}
}
],
"parserOptions": {
"ecmaFeatures": {
"experimentalObjectRestSpread": true,
"jsx": true,
"arrowFunctions": true,
"classes": true,
"modules": true,
"defaultParams": true
"experimentalObjectRestSpread": 2,
"jsx": 2,
"arrowFunctions": 2,
"classes": 2,
"modules": 2,
"defaultParams": 2
},
"sourceType": "module"
},
Expand All @@ -45,45 +24,27 @@
"react"
],
"rules": {
"max-len": [
"error",
{
"code": 80,
"comments": 120
}
],
"max-len": ["error", { "code": 80, "comments": 120 }],
"linebreak-style": [
"error",
"unix"
],
"semi": [
"error",
"always"
],
"semi": ["error", "always"],
"no-const-assign": 2,
"no-dupe-class-members": 2,
"no-duplicate-case": 2,
"no-extra-parens": [
2,
"functions"
],
"no-extra-parens": [2, "functions"],
"no-self-compare": 2,
"accessor-pairs": 2,
"comma-spacing": [
2,
{
"before": false,
"after": true
}
],
"comma-spacing": [2, {
"before": false,
"after": true
}],
"constructor-super": 2,
"new-cap": [
2,
{
"newIsCap": true,
"capIsNew": false
}
],
"new-cap": [2, {
"newIsCap": true,
"capIsNew": false
}],
"new-parens": 2,
"no-array-constructor": 2,
"no-class-assign": 2,
Expand Down
5 changes: 2 additions & 3 deletions testplan/web_ui/testing/.gitignore
@@ -1,6 +1,5 @@
node_modules/
.env.local
.env.production.local
.env.development.local
.env.*.local
yarn-error.log
/build/
build/
14 changes: 0 additions & 14 deletions testplan/web_ui/testing/DEVELOPMENT.md

This file was deleted.

5 changes: 0 additions & 5 deletions testplan/web_ui/testing/README.md

This file was deleted.

40 changes: 0 additions & 40 deletions testplan/web_ui/testing/jest-puppeteer.config.js

This file was deleted.

60 changes: 6 additions & 54 deletions testplan/web_ui/testing/package.json
Expand Up @@ -11,16 +11,16 @@
"@fortawesome/fontawesome-svg-core": "1.2.2",
"@fortawesome/free-solid-svg-icons": "5.2.0",
"@fortawesome/react-fontawesome": "0.1.3",
"@reduxjs/toolkit": "^1.3.4",
"@reduxjs/toolkit": "~1.3.4",
"ag-grid-community": "^21.2.1",
"ag-grid-react": "^21.2.1",
"aphrodite": "2.2.3",
"axios": "0.19.0",
"bootstrap": "4.3.1",
"eslint-plugin-react": "^7.14.3",
"history": "^4.10.1",
"lodash": "^4.17.15",
"prop-types": "^15.7.2",
"history": "^~4.10.1",
"lodash": "~4.17.15",
"qs": "^6.9.1",
"react": "~16.12.0",
"react-copy-html-to-clipboard": "6.0.4",
"react-custom-scrollbars": "4.2.1",
Expand All @@ -32,6 +32,7 @@
"react-scripts": "^3.4.0",
"react-spinners": "^0.6.0",
"react-syntax-highlighter": "^11.0.2",
"react-test-renderer": "16.6.0",
"react-vis": "^1.11.7",
"reactstrap": "6.3.0",
"redux": "^4.0.5"
Expand All @@ -43,18 +44,10 @@
"enzyme": "3.7.0",
"enzyme-adapter-react-16": "1.6.0",
"enzyme-to-json": "^3.3.5",
"expect-puppeteer": "^4.4.0",
"jest": "^24.9.0",
"jest-dev-server": "^4.4.0",
"jest-environment-node": "^25.3.0",
"jest-environment-puppeteer": "^4.4.0",
"jest-puppeteer": "^4.4.0",
"moxios": "0.4.0",
"puppeteer": "^2.0.0",
"serve": "^11.0.0"
"npm-force-resolutions": "0.0.3"
},
"scripts": {
"serve": "serve -d -s -l 5000 build",
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
Expand All @@ -76,49 +69,8 @@
]
},
"jest": {
"globalSetup": "jest-environment-puppeteer/setup",
"globalTeardown": "jest-environment-puppeteer/teardown",
"snapshotSerializers": [
"enzyme-to-json/serializer"
]
},
"optionalDependencies": {
"@babel/cli": "^7.4.4",
"@babel/node": "^7.5.0",
"@babel/register": "^7.9.0",
"@types/bootstrap": "^3.3.37",
"@types/cheerio": "^0.22.11",
"@types/enzyme": "^3.1.16",
"@types/enzyme-adapter-react-16": "^1.0.3",
"@types/enzyme-to-json": "^1.5.1",
"@types/expect-puppeteer": "^3.3.1",
"@types/history": "^4.7.5",
"@types/jest": "^24.9.0",
"@types/jest-environment-puppeteer": "^4.3.1",
"@types/jquery": "^3.3.32",
"@types/lodash": "^4.14.149",
"@types/node": "^13.11.0",
"@types/prop-types": "^15.7.3",
"@types/puppeteer": "^2.0.1",
"@types/react": "^16.9.32",
"@types/react-dom": "^16.9.5",
"@types/react-redux": "^7.1.0",
"@types/react-router": "^5.1.4",
"@types/react-router-dom": "^5.1.3",
"@types/react-syntax-highlighter": "^11.0.2",
"@types/react-test-renderer": "^16.0.2",
"@types/reactstrap": "^8.0.1",
"@types/sizzle": "^2.3.2",
"@types/testing-library__dom": "^6.12.0",
"@types/testing-library__react": "^9.1.2",
"@types/webpack-dev-server": "^3.9.0",
"@types/webpack-env": "^1.14.0",
"@typescript-eslint/eslint-plugin": "^2.27.0",
"@typescript-eslint/parser": "^2.27.0",
"eslint": "^6.8.0",
"qs": "^6.9.1",
"react-devtools": "^3.6.1",
"redux-mock-store": "^1.5.3",
"typescript": "^3.8.3"
}
}
1 change: 1 addition & 0 deletions testplan/web_ui/testing/public/index.html
Expand Up @@ -4,6 +4,7 @@
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<meta name="theme-color" content="#000000">
<link rel="manifest" href="%PUBLIC_URL%/manifest.json">
<link rel="shortcut icon" href="%PUBLIC_URL%/testplan-logo.png">
<link href="https://stackpath.bootstrapcdn.com/font-awesome/4.1.0/css/font-awesome.min.css"
rel="stylesheet"
Expand Down
Expand Up @@ -3,7 +3,7 @@ import PropTypes from 'prop-types';
import {css, StyleSheet} from 'aphrodite';
import {CardHeader, Tooltip} from 'reactstrap';
import {library} from '@fortawesome/fontawesome-svg-core';
import {FontAwesomeIcon} from '@fortawesome/react-fontawesome/index.es';
import {FontAwesomeIcon} from '@fortawesome/react-fontawesome';
import {faLayerGroup} from '@fortawesome/free-solid-svg-icons';

library.add(faLayerGroup);
Expand Down
2 changes: 1 addition & 1 deletion testplan/web_ui/testing/src/AssertionPane/AssertionPane.js
Expand Up @@ -2,7 +2,7 @@ import React, {Component} from 'react';
import PropTypes from 'prop-types';
import {css, StyleSheet} from 'aphrodite';
import {library} from '@fortawesome/fontawesome-svg-core';
import {FontAwesomeIcon} from '@fortawesome/react-fontawesome/index.es';
import {FontAwesomeIcon} from '@fortawesome/react-fontawesome';
import {
faMinusCircle,
faPlusCircle,
Expand Down
@@ -1,7 +1,7 @@
import React, {Component} from 'react';
import PropTypes from 'prop-types';
import {Button, ButtonGroup} from 'reactstrap';
import {FontAwesomeIcon} from '@fortawesome/react-fontawesome/index.es';
import {FontAwesomeIcon} from '@fortawesome/react-fontawesome';
import {library} from '@fortawesome/fontawesome-svg-core';
import {
faSortAmountUp,
Expand Down Expand Up @@ -159,4 +159,4 @@ DictButtonGroup.propTypes = {
};


export default DictButtonGroup;
export default DictButtonGroup;
@@ -1,3 +1,4 @@
import _uniq from 'lodash/uniq';
import {any, sorted, domToString} from './../../../Common/utils';
import {DICT_GRID_STYLE} from './../../../Common/defaults';

Expand Down Expand Up @@ -51,8 +52,8 @@ function sortFlattenedJSON(
}
}

const set = new Set(origFlattenedJSON.map(line => line[0]));
const allItemsAreSameLevel = set.size === 1;
const set = _uniq(origFlattenedJSON.map(line => line[0]));
const allItemsAreSameLevel = set.length === 1;

// if all remaining items of the list are on the same depth level,
// they can be sorted and returned
Expand Down

0 comments on commit acd2e00

Please sign in to comment.