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

Rebuild test-runtime if substrate binary is updated #362

Merged
merged 3 commits into from
Dec 10, 2021

Conversation

jsdw
Copy link
Collaborator

@jsdw jsdw commented Dec 10, 2021

Prior to this, one could update the substrate binary on their PATH, and the test-runtime would not rebuild in response to this, leading to a potentially out of date runtime being used (the fix was to tweak test-runtime/build.rs to force a rebuild).

This resolves the path to the substrate binary and tells cargo to keep an eye on that, too.

Tested by touching the substrate binary in use, which then caused a rebuild (and otherwise it would not rebuild).

Closes #358

Copy link
Contributor

@ascjones ascjones left a comment

Choose a reason for hiding this comment

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

LGTM.

This reminds me, I think we need to look at the subxt macro to make sure it rebuilds when the contents of the static metadata file has changed. It probably won't rebuild atm.

@ascjones ascjones merged commit b777420 into master Dec 10, 2021
@ascjones ascjones deleted the jsdw-test-runtime-rerun branch December 10, 2021 11:54
0623forbidden pushed a commit to DEIPworld/substrate-subxt that referenced this pull request Feb 15, 2022
* Re-run test-runtime build script if the substrate binary changes

* cargo fmt

* Can => Cannot
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.

test-runtime does not re-run when the substrate binary on your PATH changes.
3 participants