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
Reorganize test setup #1132
Reorganize test setup #1132
Conversation
Conflicts: packages/api/test/e2e/api-derive/promise.spec.ts packages/api/test/e2e/api-metadata/transfer.spec.ts packages/api/test/e2e/api/promise-consts.spec.ts packages/api/test/e2e/api/promise-contract.spec.ts packages/api/test/e2e/api/promise-queries.spec.ts packages/api/test/e2e/api/promise-tx.spec.ts packages/api/test/e2e/api/rx-queries.spec.ts packages/api/test/e2e/api/rx-tx.spec.ts packages/api/test/e2e/rpc-core/alexander.spec.ts packages/api/test/e2e/rpc-core/basics.spec.ts packages/api/test/e2e/rpc-core/chain.spec.ts packages/api/test/e2e/rpc-core/state.spec.ts packages/api/test/e2e/rpc-core/subscribe.spec.ts
Conflicts: packages/api/test/e2e/api/promise-alex-archive.spec.ts packages/api/test/e2e/api/promise-alex.spec.ts packages/api/test/e2e/api/promise-contract.spec.ts packages/api/test/e2e/api/promise-queries.spec.ts packages/api/test/e2e/api/promise-tx.spec.ts packages/api/test/e2e/api/rx-queries.spec.ts packages/api/test/e2e/api/rx-tx.spec.ts
…from throwing an error
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should all tests pass?
- test:e2e (on local node): 6 failed
- test:e2e-remote: 13 failed
- test:e2e-docker: 23 failed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks mostly sane, just 2 comments around splitting and contract locations.
Would be cool to take this into account too: https://github.com/polkadot-js/api/blob/master/packages/api/test/e2e/promise-tx.spec.ts#L122 |
No, they shouldn't. Files that should work are: |
My current approach is:
I'd take care of the promise-tx.spec file in one of my next PR's |
I generally won't care about the local tests passing btw because that's unpredictable. I could never know which version / node a person is running on their machine. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
* Moved all e2e tests to 'api' folder * Moved metadata test * fix imports * Add jest options for testing the different endpoint types separately * Add check for empty test suites and return empt test to prevent jest from throwing an error * Fix import paths * Fix const tests for polkadot chains * Update to latest Substrate 2.0 image * Move contract files for e2e testing to e2e tesing folder * reorder & fix promise query tests for all test nodes * final fixes for promise query * eslint fixes * removed trailing space * fix linting errors * Address codeclimate "Function getWsEndpoints has a Cognitive Complexity of 7 (exceeds 5 allowed)." * Fix contract ABI import paths * linter endpoint types * replace alice with alice_stash * split off promise-queries file * Remove apiType, smaller cleanups, added local to only: [] tests suites * relative paths changed to `@polkadot` import * moved contract wasm & abi's back to `api-contract`
* Moved all e2e tests to 'api' folder * Moved metadata test * fix imports * Add jest options for testing the different endpoint types separately * Add check for empty test suites and return empt test to prevent jest from throwing an error * Fix import paths * Fix const tests for polkadot chains * Update to latest Substrate 2.0 image * Move contract files for e2e testing to e2e tesing folder * reorder & fix promise query tests for all test nodes * final fixes for promise query * eslint fixes * removed trailing space * fix linting errors * Address codeclimate "Function getWsEndpoints has a Cognitive Complexity of 7 (exceeds 5 allowed)." * Fix contract ABI import paths * linter endpoint types * replace alice with alice_stash * split off promise-queries file * Remove apiType, smaller cleanups, added local to only: [] tests suites * relative paths changed to `@polkadot` import * moved contract wasm & abi's back to `api-contract`
This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Addresses the following points of #908:
I'm working through this part bit by by now for all supported versions
Also in this PR:
I split off the e2e test flags to be able to run the tests from the 3 different sources independently.
yarn test:e2e
: Will run the e2e tests with the local node on9944
yarn test:e2e-docker
: Will run the e2e tests with the 5 Docker imagesyarn test:e2e-remote
: Will run the e2e tests with the 2 remote endpointsThe goal is that in the end everyone developing on the API can spot failing tests on all supported substrate and polkadot versions easily.