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

Run coveralls on travis #270

Merged
merged 5 commits into from
Feb 7, 2018
Merged

Run coveralls on travis #270

merged 5 commits into from
Feb 7, 2018

Conversation

axic
Copy link
Member

@axic axic commented Feb 3, 2018

Fixes #269.

@axic axic force-pushed the coveralls branch 2 times, most recently from a74e019 to 2ecfa5c Compare February 4, 2018 00:42
@axic
Copy link
Member Author

axic commented Feb 4, 2018

State tests cover 93% of opFns.js: https://coveralls.io/builds/15361640/source?filename=lib%2FopFns.js

@axic
Copy link
Member Author

axic commented Feb 4, 2018

Fun facts:

  • apparently there's no div, mod or mulmod by zero :)
  • but there is sdiv and smod by zero
  • no sstore overwriting a non-zero value with a non-zero value
  • no test with failed create (where the deployment code threw an exception)
  • apparently increasing memory is not tested?!
  • all precompiles have 100% coverage except modexp (very large inputs are not tested)
  • but our coverage test for ecmul/ecadd/ecpairing is unreliable as it uses an external blob (rustbn.js)
  • exp only tests 0, 1, 2, 8, 16, 20, 32nd exponent
  • data copying (either calldatacopy, codecopy or extcodecopy) doesn't cover unaligned buffers (only ones divisible by the word size of 32)

All the other missing lines are just cases of covering internal exceptions (creating a trie node failed, etc.)

cc @jwasinger @winsvega @pirapira

@axic
Copy link
Member Author

axic commented Feb 4, 2018

It is also possible to run multiple tests and combine the coverage files (which we should do).

@winsvega
Copy link

winsvega commented Feb 4, 2018

no sstore overwriting a non-zero value with a non-zero value
this definitely happens in some OOG recursive calls

@holgerd77
Copy link
Member

Very cool PR, also remember to add the badge to the README.

@axic
Copy link
Member Author

axic commented Feb 7, 2018

@holgerd77 should be ok to merge now

Copy link
Member

@holgerd77 holgerd77 left a comment

Choose a reason for hiding this comment

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

Great stuff, really looking forward to this.

@holgerd77 holgerd77 merged commit 8de73f9 into master Feb 7, 2018
@holgerd77 holgerd77 deleted the coveralls branch February 7, 2018 13:01
@holgerd77
Copy link
Member

Short note, realized while working on the ethereumjs-devp2p coverage integration: the istanbul package is marked as deprecated and replaced by nyc istanbul CL client.

@pirapira
Copy link

@axic do you have the new list of missing test cases? I heard you found some expmod tests for large inputs.

@axic
Copy link
Member Author

axic commented Feb 22, 2018

Using the "new" (15 days old) tests repo is handled in #272.

Currently it fails on a modexp test case with a large input (gas calculation fails because the bignum exceeds 53bits). We haven't yet fixed the code to see the new coverage figures.

cc @jwasinger @cdetrio

holgerd77 added a commit that referenced this pull request Mar 11, 2021
Fix the types of the BN and RLP re-exports
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Enable coveralls for test coverage tracking
6 participants