-
Notifications
You must be signed in to change notification settings - Fork 2
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
Match test node type to test build type #442
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
|
||
let proc = TestNodeProcess::<EntropyConfig>::build(path.as_str(), chain_type) | ||
let proc = TestNodeProcess::<EntropyConfig>::build(path, chain_type) |
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.
In the future we can probably have the TestNodeProcess
and builder take a Path
instead, but I didn't want to mess with that here
tbh I don't love this as I warn people not to build the chain in debug type, I have seen a lot of errors as blockchains are time dependent and you can get weird failures when you aren't optimizing the build |
For development it's totally reasonable to build in debug mode though. And this doesn't remove the ability for people to run in release mode, it just makes that more explicit and less error prone. |
Is this working for people? My end, the So in practice this change means i have to always build Since i am mostly working on |
@ameba23 all the Having a hard requirement on needing release builds for tests to pass seems like a failure of our testing process. Everything should always be able to pass in debug mode. |
Pretty much all of them fail whilst trying to get the rpc here:
eg:
They do occasionally pass though. |
While working on #437 I ran into an issue where my tests were failing because they
expected my node to have been built in release mode. This is because the tests helpers
were previously hardcoded to expect a release binary and nothing else.
This PR changes that behaviour so that the test helpers will now expect a binary
depending on the build type of the tests. I.e, if you're building your tests in debug
mode it expect a debug node, and if you built them in release mode it expects a release
node.
It also adds a couple more checks in case you don't have the right node type built.