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

Automate the test specs generation #113

Merged
merged 7 commits into from
Nov 17, 2020
Merged

Automate the test specs generation #113

merged 7 commits into from
Nov 17, 2020

Conversation

crystalin
Copy link
Collaborator

Remove the specs for the test in profit of the template.
The npm run test command is now generating the specs from the template and running the tests after.

2 new commands have been added:
npm run generate-specs which generates the specs
npm run test-only which runs the test without generating the specs.

In addition, the test are now by default using the Release Binary. To use the debug binary:
BINARY_PATH=../node/standalone/target/debug/moonbase-standalone npm run test

Copy link
Contributor

@JoshOrndorff JoshOrndorff left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is a step better, but I think a much bigger step would be to stop generating a json test spec entirely. That json file is just one more thing to get accidentally out of sync as we have seen. Why not use the spec that is stored in the chain_spec.rs file?

tests/tests/util.ts Show resolved Hide resolved
@crystalin
Copy link
Collaborator Author

@JoshOrndorff
The reason for not using the default chain spec is because I thought we would have more complex tests later which would require different genesis.
I think it still makes sense, specially once we start adding security/performance testing based on different chain parameters.

@crystalin crystalin merged commit 3502996 into master Nov 17, 2020
@crystalin crystalin deleted the crystalin-auto-tests branch November 17, 2020 21:21
crystalin pushed a commit that referenced this pull request Jun 18, 2021
crystalin added a commit that referenced this pull request Jul 20, 2021
* Drafting parachain tests

* Improvements, needs polkadot-launch pr #113

* Adds parachain tests to the CI

* Type in CI build

* Fix missing requirement in para test CI

* Removes extra useless build
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants