| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
|
@bcoe build started: https://ci.nodejs.org/blue/organizations/jenkins/node-test-pull-request-lite-pipeline/detail/node-test-pull-request-lite-pipeline/2022/pipeline |
Sorry, something went wrong.
|
@mhdawson I note that cctest is commented out currently in the make file, is this a known issue? |
Sorry, something went wrong.
|
@mhdawson @schuay I've finally been able to test our work on v8, here are some findings:
Things are working well enough that I'd vote:
@nodejs/build 👆 |
Sorry, something went wrong.
|
The throw case should be handled just like a return as last statement. |
Sorry, something went wrong.
|
Lets get a CI job running which uses the new approach to validate and then plan the steps to land the PRs to enable in core. @bcoe let's try to catch up on Monday to work on the CI job, |
Sorry, something went wrong.
There was a problem hiding this comment.
@mhdawson 👍 I think this is pretty much ready to go, I've been playing a bit of whack a mole with a few edge-case tests, but the vast majority run effectively under test.
Sorry, something went wrong.
There was a problem hiding this comment.
EmitProcessEnvWarning has the side effect of setting emit_env_nonstring_warning_ = false; which I believe shouldn't be set unless a warning has actually been emitted?
Sorry, something went wrong.
There was a problem hiding this comment.
Why would this be necessary? Does c8 use the the process.env setter in the deprecated way?
Sorry, something went wrong.
There was a problem hiding this comment.
@joyeecheung I'll dig a bit further, I don't believe that coverage.js is setting process.env incorrectly (c8 doesn't come into play until the reporting step). It just seemed like setting the environment variable in internal/process/coverage.js was suppressing the warning message generated by the unit test.
Sorry, something went wrong.
|
@bcoe working on a job here to test it out: https://ci.nodejs.org/view/All/job/node-test-commit-linux-coverage-new |
Sorry, something went wrong.
|
@bcoe Nice! I think this is ready for merging? |
Sorry, something went wrong.
There was a problem hiding this comment.
@joyeecheung confirmed that this failure wasn't coverage related, setting an environment variable correctly would suppress future warnings; easy fix is simply calling env->EmitProcessEnvWarning() last.
Sorry, something went wrong.
There was a problem hiding this comment.
Is this change relevant to this PR (making a switch in coverage)?
Sorry, something went wrong.
There was a problem hiding this comment.
Turning on coverage surfaced this bug, and made this test not run if coverage was enabled. I figured it was an innocent enough change that it was worth patching; If you'd like me to break it out into another patch I can.
Sorry, something went wrong.
There was a problem hiding this comment.
BTW: After this PR will the test suite in make coverage pass (RE: #25543 (comment))
Sorry, something went wrong.
There was a problem hiding this comment.
@refack not quite, there are a couple addon tests that fail; I think related to the inspector session creating resources that break a few assertions.
I would be happy to help isolate these, and maybe we could use TEST_TO_SKIP_FOR_COVERAGE to remove them, then maybe we could get to the point where @mhdawson and I can abort on failure for coverage tests?
Would folks be okay with keeping this patch in, if @mhdawson and I work on making this pull request run coverage without ignoring errors?
Sorry, something went wrong.
|
Latest CI run (new job to test out) ran ok, and generated coverage results and artifacts. I do see that some of the end brackets are not covered (already mentioned by @bcoe ). A few other things I've noticed so far:
|
Sorry, something went wrong.
|
Also noticed it does not show coverage as missing in: /lib/internal/fs/utils.js.html It shows these 2 paths as being covered, where as the existing report does not. if (throwError) {
Error.stackTraceLimit = 0;
}
const err = new ERR_INVALID_ARG_VALUE(
propName,
path,
'must be a string or Uint8Array without null bytes'
);
if (throwError) {
Error.stackTraceLimit = tmpLimit;
Error.captureStackTrace(err, nullCheck);
throw err;
}
return err;
|
Sorry, something went wrong.
There was a problem hiding this comment.
@thefourtheye I think I've addressed your review.
@mhdawson I've rebased this with the back ported v8 changes, and am quite happy with how things are looking; you should be able to run your coverage tests against this pull now.
Coverage tests failing should no longer break coverage report outputting -- going forward, I can certainly get onboard with the argument that we should fail tests, maybe instead of reporting on failure, we should identify the specific tests that fail and add them to an ignore list?
Sorry, something went wrong.
There was a problem hiding this comment.
@mhdawson and I are having a discussion around this right now -- currently (and I believe historically) there are a small minority of tests that fail when under coverage, and we've simply opted to not fail when running under coverage and still run reports.
If we start failing the coverage test suite on failures, we'll need top explicitly exclude a few tests, and be more diligent about not introducing new tests that fail under coverage going forward.
Sorry, something went wrong.
There was a problem hiding this comment.
Turning on coverage surfaced this bug, and made this test not run if coverage was enabled. I figured it was an innocent enough change that it was worth patching; If you'd like me to break it out into another patch I can.
Sorry, something went wrong.
Sorry, something went wrong.
Could it be possible that a file with a lot of tests in it fail during the coverage? If so, we can work towards breaking them down to multiple smaller tests. |
Sorry, something went wrong.
There was a problem hiding this comment.
Left some naming and semantic comments
Sorry, something went wrong.
There was a problem hiding this comment.
BTW: After this PR will the test suite in make coverage pass (RE: #25543 (comment))
Sorry, something went wrong.
There was a problem hiding this comment.
Could the list of tests be refactored to a new var (TEST_TO_SKIP_FOR_COVERAGE)? and D.R.Y. L307?
Sorry, something went wrong.
There was a problem hiding this comment.
I wonder if we could use TEST_TO_SKIP_FOR_COVERAGE to isolate the tests that fail under coverage (@mhdawson?) and stop using - to suppress erros.
Sorry, something went wrong.
There was a problem hiding this comment.
I'm not sure we should recommend the use of CI_* variables to the public. AFAICT they are meant for internal use by our CI systems, and should be considered "private".
Sorry, something went wrong.
There was a problem hiding this comment.
Sorry, something went wrong.
There was a problem hiding this comment.
I wonder if we could use TEST_TO_SKIP_FOR_COVERAGE to isolate the tests that fail under coverage (@mhdawson?) and stop using - to suppress erros.
Sorry, something went wrong.
There was a problem hiding this comment.
@refack not quite, there are a couple addon tests that fail; I think related to the inspector session creating resources that break a few assertions.
I would be happy to help isolate these, and maybe we could use TEST_TO_SKIP_FOR_COVERAGE to remove them, then maybe we could get to the point where @mhdawson and I can abort on failure for coverage tests?
Would folks be okay with keeping this patch in, if @mhdawson and I work on making this pull request run coverage without ignoring errors?
Sorry, something went wrong.
|
We have chosen to allow failing tests when run with coverage. With unlimited resources, we would fix that. I'd be concerned with the ongoing maintenance (for those keeping coverage going) as well as showing things that are covered as not-covered that we'd get from excluding tests. My personal feeling is that allowing failing tests is a reasonable balance between work/benefit but of course I'm open to other thoughts. |
Sorry, something went wrong.
|
Coverage CI run with all the changes - https://ci.nodejs.org/view/All/job/node-test-commit-linux-coverage-new/9/ |
Sorry, something went wrong.
PR-URL: nodejs#25157 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com> Reviewed-By: Refael Ackermann <refack@gmail.com>
PR-URL: #25157 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com> Reviewed-By: Refael Ackermann <refack@gmail.com>
Update the comments for the `coverage` Makefile target. - Source files under `lib` are no longer instrumented since d1dee49 - Fix the name of the related CI job. PR-URL: #39365 Refs: #25157 Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Update the comments for the `coverage` Makefile target. - Source files under `lib` are no longer instrumented since d1dee49 - Fix the name of the related CI job. PR-URL: #39365 Refs: #25157 Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Update the comments for the `coverage` Makefile target. - Source files under `lib` are no longer instrumented since d1dee49 - Fix the name of the related CI job. PR-URL: #39365 Refs: #25157 Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Update the comments for the `coverage` Makefile target. - Source files under `lib` are no longer instrumented since d1dee49 - Fix the name of the related CI job. PR-URL: #39365 Refs: #25157 Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
| Back | FazBrowse Home | New Git URL |
Switches to using v8's built in coverage support.
Note: these results will get better once https://chromium-review.googlesource.com/c/v8/v8/+/1339119 is landed.
CC: @schuay, @hashseed we're almost over the finish line \o/
TODO:
Checklist