Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft Release 1.6.1, Sync Test to Stage #707

Merged
merged 23 commits into from
Jul 13, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
a8667a9
refactor(config): ent-2745 consolidate nav, routing configs (#656)
cdcabrera May 4, 2021
475eed1
refactor(routerHelpers): ent-2745 consolidate nav, route lookup (#656)
cdcabrera May 6, 2021
4fe3d8c
refactor(productViewMissing): ent-2745 use route helper (#656)
cdcabrera May 10, 2021
8ed0445
refactor(router): ent-2745 convert class component (#656)
cdcabrera May 17, 2021
ca38f5c
fix(testing): outside src import, unit test locale (#680)
cdcabrera May 18, 2021
6e4d538
fix(testing): mock window location, components with hooks (#680)
cdcabrera May 20, 2021
26d94f9
chore(deps-dev): bump apidoc-mock from 3.0.4 to 4.0.0 (#681)
dependabot[bot] May 20, 2021
d43932a
refactor(router): ent-2745 function, hook convert (#684)
cdcabrera May 21, 2021
7c3b4bc
fix(routes,router): ent-2745 dynamic lazy load views (#679)
cdcabrera May 21, 2021
3592e13
fix(build): npm updates (#685)
cdcabrera May 24, 2021
bc1b64c
fix(select,toolbarFields): ent-3879 apply test attributes (#687)
cdcabrera May 24, 2021
173e42f
chore(deps): bump victory-create-container from 35.8.0 to 35.8.1 (#686)
dependabot[bot] May 24, 2021
d43d8f0
revert(testing): outside src import, unit test locale (#691)
cdcabrera May 27, 2021
8832b0e
fix(redirect): ent-3916 route config, dynamic loading (#691)
cdcabrera May 27, 2021
8f7c7a9
fix(authentication): remove test block (#691)
cdcabrera May 27, 2021
ecc20fc
fix(productView): ent-3888 use meta to display total core hours (#692)
cdcabrera May 27, 2021
5d0f86b
fix(redirect): ent-3833 restructure, force a path (#695)
cdcabrera Jun 1, 2021
e2043e7
fix(productViewMissing): ent-3913 apply platform appNavClick (#695)
cdcabrera Jun 2, 2021
1e3f36c
chore(deps-dev): bump eslint-plugin-jsdoc from 35.0.0 to 35.1.3 (#696)
dependabot[bot] Jun 7, 2021
ba210b5
fix(i18n): allow multi-context (#699)
cdcabrera Jun 7, 2021
a43fc7e
chore(deps-dev): bump eslint-plugin-import from 2.23.3 to 2.23.4 (#700)
dependabot[bot] Jun 7, 2021
ef7a9e4
chore(deps-dev): bump eslint-plugin-react from 7.23.2 to 7.24.0 (#701)
dependabot[bot] Jun 9, 2021
fc95651
chore(build): npm updates (#704)
cdcabrera Jun 10, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
"react"
],
"settings": {
"import/external-module-folders": ["public"],
"jsdoc": {
"preferredTypes": {
"delete": "delete",
Expand All @@ -37,6 +38,11 @@
"plugin:jest/recommended",
"plugin:jsdoc/recommended"
],
"globals": {
"mockHook": "readonly",
"mountHookComponent": "readonly",
"mockWindowLocation": "readonly"
},
"rules": {
"arrow-parens": [
"error",
Expand Down Expand Up @@ -81,6 +87,14 @@
"jsdoc/require-param-description": 0,
"jsdoc/require-property-description": 0,
"jsdoc/require-returns-description": 0,
"jsdoc/tag-lines": [
"warn",
"always",
{
"count": 0,
"noEndLines": true
}
],
"max-len": [
"error",
{
Expand Down
8 changes: 4 additions & 4 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,13 +71,13 @@ Curiosity makes use of the branches `master`, `stage`, `qa`, and `ci`.
- `stage` branch is a protected representation of production environments
- Adding commits, or a PR, into `stage` should generate a `prod-beta` branch within the deploy repository [curiosity-frontend-build](https://github.com/RedHatInsights/curiosity-frontend-build)
- The `prod-beta` branch is manually deployed through coordination with the operations team.
- `qa` branch is a representation of `qa-stable`, and `ci-stable`.
- `qa` branch is a representation of `ci-stable`, `qa-stable` and `stage-stable`.
- Adding commits, or a PR, into `ci-stable` should generate `ci-*` and `qa-*` branches within the deploy repository [curiosity-frontend-build](https://github.com/RedHatInsights/curiosity-frontend-build)
- The `ci-*` and `qa-*` branches are automatically deployed within an averaged time for both `https://ci.*.redhat.com` and `https://qa.*.redhat.com`
- The `ci-*` and `qa-*` branches are automatically deployed within an averaged time for `https://ci.*.redhat.com`, `https://qa.*.redhat.com` and `https://*.stage.redhat.com`
- In the future, once the API is fully deployed to QA, this will be a representation of `qa-beta` and `qa-stable`
- `ci` branch is a representation of `ci-beta`, and `qa-beta`.
- `ci` branch is a representation of `ci-beta`, `qa-beta` and `stage-beta`.
- Adding commits, or a PR, into `ci-beta` should generate `ci-*` and `qa-*` branches within the deploy repository [curiosity-frontend-build](https://github.com/RedHatInsights/curiosity-frontend-build)
- The `ci-*` and `qa-*` branches are automatically deployed within an averaged time for both `https://ci.*.redhat.com` and `https://qa.*.redhat.com`
- The `ci-*` and `qa-*` branches are automatically deployed within an averaged time for `https://ci.*.redhat.com`, `https://qa.*.redhat.com` and `https://*.stage.redhat.com`
- In the future, once the API is fully deployed to QA, this will be a representation of `ci-beta` and `ci-stable`

#### Branching and Pull Request Workflow
Expand Down
39 changes: 20 additions & 19 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
"!src/index.js",
"!src/setupTests.js",
"!src/components/app.js",
"!src/components/**/index.js",
"!src/common/index.js",
"!src/redux/index.js",
"!src/redux/store.js",
Expand Down Expand Up @@ -113,31 +114,30 @@
"test:local": "react-scripts test --env=jsdom --roots=./src"
},
"dependencies": {
"@patternfly/patternfly": "4.102.2",
"@patternfly/react-charts": "6.14.17",
"@patternfly/react-core": "4.115.2",
"@patternfly/react-icons": "4.10.2",
"@patternfly/react-styles": "4.10.2",
"@patternfly/react-table": "4.26.7",
"@patternfly/react-tokens": "4.11.3",
"@redhat-cloud-services/frontend-components": "3.1.11",
"@redhat-cloud-services/frontend-components-notifications": "3.1.0",
"@redhat-cloud-services/frontend-components-utilities": "3.1.2",
"@patternfly/patternfly": "4.108.2",
"@patternfly/react-charts": "6.14.29",
"@patternfly/react-core": "4.128.2",
"@patternfly/react-icons": "4.10.11",
"@patternfly/react-styles": "4.10.11",
"@patternfly/react-table": "4.27.24",
"@patternfly/react-tokens": "4.11.12",
"@redhat-cloud-services/frontend-components": "3.2.5",
"@redhat-cloud-services/frontend-components-notifications": "3.2.2",
"@redhat-cloud-services/frontend-components-utilities": "3.2.2",
"axios": "^0.21.1",
"classnames": "^2.3.1",
"i18next": "^20.2.2",
"i18next": "^20.3.1",
"i18next-xhr-backend": "^3.2.2",
"js-cookie": "^2.2.1",
"locale-code": "^2.0.2",
"lodash": "^4.17.21",
"lru-cache": "^6.0.0",
"moment": "^2.29.1",
"node-sass": "^4.14.1",
"numbro": "^2.3.2",
"prop-types": "^15.7.2",
"react": "^17.0.2",
"react-dom": "^17.0.2",
"react-i18next": "^11.8.15",
"react-i18next": "^11.10.0",
"react-redux": "^7.2.4",
"react-router": "^5.2.0",
"react-router-dom": "^5.2.0",
Expand All @@ -148,23 +148,24 @@
"redux-promise-middleware": "^6.1.2",
"redux-thunk": "^2.3.0",
"reselect": "^4.0.0",
"victory-create-container": "^35.5.1"
"sass": "^1.34.1",
"victory-create-container": "^35.8.5"
},
"devDependencies": {
"@wojtekmaj/enzyme-adapter-react-17": "^0.6.1",
"apidoc-mock": "^3.0.4",
"cspell": "^5.4.0",
"apidoc-mock": "^4.0.0",
"cspell": "^5.6.1",
"enzyme": "^3.11.0",
"enzyme-to-json": "^3.6.2",
"eslint-config-airbnb": "^18.2.1",
"eslint-config-prettier": "^8.3.0",
"eslint-plugin-import": "^2.22.1",
"eslint-plugin-import": "^2.23.4",
"eslint-plugin-jest": "^24.3.6",
"eslint-plugin-jsdoc": "^33.3.0",
"eslint-plugin-jsdoc": "^35.1.3",
"eslint-plugin-json": "^3.0.0",
"eslint-plugin-jsx-a11y": "^6.4.1",
"eslint-plugin-prettier": "^3.4.0",
"eslint-plugin-react": "^7.23.2",
"eslint-plugin-react": "^7.24.0",
"eslint-plugin-react-hooks": "^4.2.0",
"express": "^4.17.1",
"glob": "^7.1.7",
Expand Down
2 changes: 1 addition & 1 deletion src/components/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { NotificationsPortal } from '@redhat-cloud-services/frontend-components-
import { connectRouter, reduxActions } from '../redux';
import { helpers } from '../common/helpers';
import { I18n } from './i18n/i18n';
import { Router } from './router/router';
import { Router } from './router';
import Authentication from './authentication/authentication';

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -286,7 +286,126 @@ exports[`Authentication Component should return a message on 401 error: 401 erro
</MessageView>
`;

exports[`Authentication Component should return a redirect on 418 error: 418 error 1`] = `"418 redirect"`;
exports[`Authentication Component should return a redirect on 418 error: 418 error 1`] = `
<Redirect
baseName="/"
isForced={false}
route="/optin"
routes={
Array [
Object {
"activateOnError": false,
"component": "productView/productViewRhel",
"disabled": false,
"exact": true,
"id": "rhel",
"path": "/rhel",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewRhel",
"disabled": false,
"exact": true,
"id": "rhel-arm",
"path": "/rhel-arm",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewRhel",
"disabled": false,
"exact": true,
"id": "rhel-ibmpower",
"path": "/rhel-ibmpower",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewRhel",
"disabled": false,
"exact": true,
"id": "rhel-ibmz",
"path": "/rhel-ibmz",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewRhel",
"disabled": false,
"exact": true,
"id": "rhel-x86",
"path": "/rhel-x86",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewOpenShiftContainer",
"disabled": false,
"exact": true,
"id": "openshift-container",
"path": "/openshift-container",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewOpenShiftDedicated",
"disabled": false,
"exact": true,
"id": "openshift-dedicated",
"path": "/openshift-dedicated",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewSatellite",
"disabled": false,
"exact": true,
"id": "satellite",
"path": "/satellite",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewSatellite",
"disabled": false,
"exact": true,
"id": "satellite-capsule",
"path": "/satellite-capsule",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewSatellite",
"disabled": false,
"exact": true,
"id": "satellite-server",
"path": "/satellite-server",
"redirect": null,
},
Object {
"activateOnError": true,
"component": "optinView/optinView",
"disabled": false,
"exact": true,
"id": "optin",
"path": "/optin",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewMissing",
"disabled": false,
"exact": true,
"id": "missing",
"path": "/",
"redirect": "/",
},
]
}
url={null}
/>
`;

exports[`Authentication Component should return a redirect on a specific 403 error and error code: 403 error 1`] = `
<MessageView
Expand All @@ -307,4 +426,123 @@ exports[`Authentication Component should return a redirect on a specific 403 err
</MessageView>
`;

exports[`Authentication Component should return a redirect on a specific 403 error and error code: 403 redirect error 1`] = `"403 redirect"`;
exports[`Authentication Component should return a redirect on a specific 403 error and error code: 403 redirect error 1`] = `
<Redirect
baseName="/"
isForced={false}
route="/optin"
routes={
Array [
Object {
"activateOnError": false,
"component": "productView/productViewRhel",
"disabled": false,
"exact": true,
"id": "rhel",
"path": "/rhel",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewRhel",
"disabled": false,
"exact": true,
"id": "rhel-arm",
"path": "/rhel-arm",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewRhel",
"disabled": false,
"exact": true,
"id": "rhel-ibmpower",
"path": "/rhel-ibmpower",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewRhel",
"disabled": false,
"exact": true,
"id": "rhel-ibmz",
"path": "/rhel-ibmz",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewRhel",
"disabled": false,
"exact": true,
"id": "rhel-x86",
"path": "/rhel-x86",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewOpenShiftContainer",
"disabled": false,
"exact": true,
"id": "openshift-container",
"path": "/openshift-container",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewOpenShiftDedicated",
"disabled": false,
"exact": true,
"id": "openshift-dedicated",
"path": "/openshift-dedicated",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewSatellite",
"disabled": false,
"exact": true,
"id": "satellite",
"path": "/satellite",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewSatellite",
"disabled": false,
"exact": true,
"id": "satellite-capsule",
"path": "/satellite-capsule",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewSatellite",
"disabled": false,
"exact": true,
"id": "satellite-server",
"path": "/satellite-server",
"redirect": null,
},
Object {
"activateOnError": true,
"component": "optinView/optinView",
"disabled": false,
"exact": true,
"id": "optin",
"path": "/optin",
"redirect": null,
},
Object {
"activateOnError": false,
"component": "productView/productViewMissing",
"disabled": false,
"exact": true,
"id": "missing",
"path": "/",
"redirect": "/",
},
]
}
url={null}
/>
`;
Loading