-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
methods for setting/getting parity operating mode #1355
Conversation
Awesome! I just triggered a rebuild for the failing tests. And speaking of tests... do you mind adding test cases for the new methods to |
I just actually looked at the CI failures, and it's due to a dependency upgrade so don't worry about those. We'll get a fix in on another branch soon. |
Nice, thanks! I'll add some tests by next week, can't make it this weekend. |
@kclowes, is there any documentation about best practices for adding test cases? |
@MatthiasLohr There is not that I'm aware of, but it would be nice if there was! I'll add a new issue to add some documentation, but it would be helpful if you wanted/had time to write something up! As far as integration testing goes, we typically just test the 'happy path', and trust that the clients have more full testing on their error paths. All the tests live in the |
@kclowes, sure my tests should be added to |
Yeah... that's a good point. The trace module tests should probably get pulled out. If you're up for it, let's keep all the tests in the same file, but add a new Or, the other path I can see is adding a |
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.
Thank you @MatthiasLohr!
What was wrong?
Nothing. But there's always space for improvements. Since I needed functionality for getting and setting parity operating modes, I propose to add methods for that (see https://wiki.parity.io/JSONRPC-parity_set-module#parity_setmode and https://wiki.parity.io/JSONRPC-parity-module#parity_mode).
How was it fixed?
Before I searched for a cute animal picture I added two methods for easy mode control. Please check diff, it adds only 12 lines.
Cute Animal Picture