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

Add code coverage #250

Closed
vweevers opened this issue Jul 6, 2018 · 6 comments
Closed

Add code coverage #250

vweevers opened this issue Jul 6, 2018 · 6 comments
Assignees

Comments

@vweevers
Copy link
Member

vweevers commented Jul 6, 2018

Ref Level/community#34.

@vweevers vweevers self-assigned this Jul 6, 2018
@vweevers
Copy link
Member Author

vweevers commented Jul 6, 2018

We need to increase the max body size in airtap:

PayloadTooLargeError: request entity too large
    at readStream (D:\Projecten\GitHub\Level\abstract-leveldown\node_modules\raw-body\index.js:155:17)
    at getRawBody (D:\Projecten\GitHub\Level\abstract-leveldown\node_modules\raw-body\index.js:108:12)
    at read (D:\Projecten\GitHub\Level\abstract-leveldown\node_modules\body-parser\lib\read.js:77:3)
    at jsonParser (D:\Projecten\GitHub\Level\abstract-leveldown\node_modules\body-parser\lib\types\json.js:135:5)
    at Layer.handle [as handle_request] (D:\Projecten\GitHub\Level\abstract-leveldown\node_modules\express\lib\router\layer.js:95:5)
    at trim_prefix (D:\Projecten\GitHub\Level\abstract-leveldown\node_modules\express\lib\router\index.js:317:13)
    at D:\Projecten\GitHub\Level\abstract-leveldown\node_modules\express\lib\router\index.js:284:7
    at Function.process_params (D:\Projecten\GitHub\Level\abstract-leveldown\node_modules\express\lib\router\index.js:335:12)
    at next (D:\Projecten\GitHub\Level\abstract-leveldown\node_modules\express\lib\router\index.js:275:10)
    at compression (D:\Projecten\GitHub\Level\abstract-leveldown\node_modules\compression\index.js:220:5)

@vweevers
Copy link
Member Author

vweevers commented Jul 6, 2018

Should we exclude abstract/* from coverage? Only implementations can achieve 100% coverage.

image

Also, when we add code coverage to implementations, we should check that abstract is not excluded (due to it being in node_modules). edit: coverage of test code doesn't matter.

@vweevers
Copy link
Member Author

vweevers commented Jul 6, 2018

Blocked by release of airtap/airtap#201.

@ralphtheninja
Copy link
Member

Should we exclude abstract/* from coverage? Only implementations can achieve 100% coverage.

Makes sense.

@vweevers
Copy link
Member Author

vweevers commented Jul 6, 2018

Excluding works differently in nyc (node tests) and browserify-instanbul (browser tests). In addition, because browserify-instanbul is a transform controlled by airtap, airtap has to set the ignore option. Hm.

@vweevers
Copy link
Member Author

vweevers commented Jul 6, 2018

Well, heh, one option is to rename abstract/ to test/, so that it matches the default ignore options 😄

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

No branches or pull requests

2 participants