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

Updated Cypress quickstarter dependencies #446

Merged
merged 3 commits into from
Aug 21, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
42 changes: 22 additions & 20 deletions docs/modules/quickstarters/pages/e2e-cypress.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,32 @@ This is a cypress e2e testing project quickstarter with basic setup for https://
├── files
│ ├── README.md
│ ├── build
│ │ ├── integration
│ │ │ └── main.spec.js
│ | ├── tests
| | | ├── acceptance
| │ │ | └── acceptance.spec.js
| | | ├── installation
| │ │ | └── installation.spec.js
| | | └── integration
| │ │ └── integration.spec.js
│ | ├── test-results
| | | ├── acceptance-junit.xml
| | | ├── installation-junit.xml
| | | └── integration-junit.xml
│ │ └── support
│ │ ├── commands.js
│ │ └── index.js
│ ├── cypress.json
│ ├── cypress-acceptance.json
│ ├── cypress-installation.json
│ ├── cypress-integration.json
│ ├── fixtures
│ │ └── example.json
│ ├── integration
│ │ └── main.spec.ts
│ ├── tests
| | ├── acceptance
│ │ | └── acceptance.spec.ts
| | ├── installation
│ │ | └── installation.spec.ts
| | └── integration
│ │ └── integration.spec.ts
│ ├── package.json
│ ├── plugins
│ │ └── index.js
Expand All @@ -48,21 +64,7 @@ This project is generated by https://cli.angular.io/[Angular CLI]

## Usage - how do you start after you provisioned this quickstarter

* Run command `npm install` in project directory to install npm packages
* Run `npm run e2e` to execute the end-to-end tests via cypress against the test instance of the front end
* Run `npm run watch` to develop the e2e test. The tests will automatically rebuild and run, if you change any of the source files.
The test will run against a local instance of the front end, e.g. `localhost:4200`. This destination is configurable in `cypress.json`. Provide credentials for a test user by defining them in a file called `secrets.json` inside the base directory. This file should have the following format:

----
{
"e2e": {
"testUserName": "User Name",
"testUserPassword": "xxxx"
}
}
----

Please note: `secrets.json` is mentioned in `.gitignore` to prevent it from being added to version control. Please keep it this way.
Check the README.md file at root level for further instructions after the quickstarter has been provisioned.

== How this quickstarter is built through jenkins

Expand Down
2 changes: 1 addition & 1 deletion e2e-cypress/files/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ Run `npm run e2e` to execute all end-to-end tests via [cypress](http://www.cypre
### Local development

Run `npm run watch` to develop the e2e test. The tests will automatically rebuild and run, if you change any of the source files.
The test will run against a local instance of the front end, e.g. `localhost:4200`. This destination is configurable in `cypress.json`. Provide credentials for a test user by defining them in a file called `secrets.json` inside the base directory. This file should have the following format:
The test will run against a local instance of the front end, e.g. `localhost:4200`. This destination is configurable in the different `cypress-<stage>.json` files. Provide credentials for a test user by defining them in a file called `secrets.json` inside the base directory. This file should have the following format:
{
"e2e": {
"testUserName": "User Name",
Expand Down
17 changes: 8 additions & 9 deletions e2e-cypress/files/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,15 @@
},
"private": true,
"dependencies": {
"rxjs": "^6.3.3"
"rxjs": "^6.6.2"
},
"devDependencies": {
"@types/node": "^8.9.4",
"cypress": "^3.6.1",
"npm-run-all": "^4.1.3",
"rxjs-tslint": "^0.1.5",
"ts-node": "^7.0.1",
"tslint": "~5.11.0",
"tslint-language-service": "^0.9.9",
"typescript": "~3.2.1"
"@types/node": "^14.6.0",
"cypress": "^5.0.0",
"npm-run-all": "^4.1.5",
"ts-node": "^8.10.2",
"tslint": "~6.1.3",
"typescript": "^3.9.7",
"typescript-tslint-plugin": "^0.5.5"
}
}
7 changes: 6 additions & 1 deletion e2e-cypress/files/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,11 @@
"es2017",
"dom"
],
"types": ["cypress"]
"types": ["cypress"],
"plugins": [
{
"name": "typescript-tslint-plugin"
}
]
}
}
10 changes: 1 addition & 9 deletions e2e-cypress/files/tslint.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
{
"rulesDirectory": [
"node_modules/rxjs-tslint"
],
"rules": {
"arrow-return-shorthand": true,
"callable-types": true,
Expand Down Expand Up @@ -74,7 +71,6 @@
"no-trailing-whitespace": true,
"no-unnecessary-initializer": true,
"no-unused-expression": true,
"no-use-before-declare": true,
herrkoch marked this conversation as resolved.
Show resolved Hide resolved
"no-var-keyword": true,
"object-literal-sort-keys": false,
"one-line": [
Expand Down Expand Up @@ -117,10 +113,6 @@
"check-operator",
"check-separator",
"check-type"
],
"rxjs-collapse-imports": true,
"rxjs-pipeable-operators-only": true,
"rxjs-no-static-observable-methods": true,
"rxjs-proper-imports": true
]
}
}