-
Notifications
You must be signed in to change notification settings - Fork 29.8k
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
Make tests usable with debug release #3280
Conversation
test/common.js
Outdated
if (process.config.variables.arm_version === '6') { | ||
newTimeout*= 7; // ARMv6 | ||
} else { | ||
newTimeout*= 2; // ARMv7 and up. |
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.
Style: space before operator.
1e9f600
to
b9d405d
Compare
@bnoordhuis Updated. |
test/common.js
Outdated
|
||
if (process.env.TEST_TIMEOUT_MULTIPLIER !== undefined) { | ||
newTimeout = ms * process.env.TEST_TIMEOUT_MULTIPLIER; | ||
} |
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.
The TEST_TIMEOUT_MULTIPLIER logic can go now, I think?
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.
I added that for example asan debug builds when the default debug timeout isn't enough.
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.
Can you mention that in the commit log? Aside: some tests may not propagate it to child processes they start.
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.
Added in commit log.
@nodejs/build - how much effort is it to set up a version of node-test-pull-request that does everything the same except it's configured with |
We could add a parameter to the Jenkins jobs. I think we would also have to change the makefile so that the parameter can be passed to the run-ci rule. Just curious: in which scenarios do you foresee needing this? It would be nice to test in debug mode but I am afraid that the increase in run times would make it not very practical for every day use. |
Stress-testing (our interaction with) V8. Debug builds do a large number of extra checks.
I think this is all that is needed: diff --git a/Makefile b/Makefile
index 1d8b89b..2740618 100644
--- a/Makefile
+++ b/Makefile
@@ -6,7 +6,7 @@ DESTDIR ?=
SIGN ?=
PREFIX ?= /usr/local
FLAKY_TESTS ?= run
-TEST_CI_ARGS ?=
+TEST_CI_ARGS ?= --mode=release
STAGINGSERVER ?= node-www
OSTYPE := $(shell uname -s | tr '[A-Z]' '[a-z]')
@@ -143,7 +143,7 @@ test-all-valgrind: test-build
$(PYTHON) tools/test.py --mode=debug,release --valgrind
test-ci: | build-addons
- $(PYTHON) tools/test.py -p tap --logfile test.tap --mode=release --flaky-tests=$(FLAKY_TESTS) \
+ $(PYTHON) tools/test.py -p tap --logfile test.tap --flaky-tests=$(FLAKY_TESTS) \
$(TEST_CI_ARGS) addons message parallel sequential
test-release: test-build |
Doesn't |
The makefile change also needs to be done in a way that has a graceful fallback for branches where it's not available, or it needs to be ported to all branches before we can pass the argument in Jenkins. To be more clear, we are talking about having Jenkins call |
Yes, but that doesn't need changes to the Makefile. Either We could reuse BUILDTYPE for the --mode switch as well. That's arguably the most elegant. |
I just realized that one drawback of |
b9d405d
to
d2c0f3d
Compare
To reduce run times but keep the debug checks we could the use build variable |
@skomski Caveat emptor from 69581b2:
|
Added for example for asan debug builds when the default debug timeout isn't enough.
d2c0f3d
to
619497a
Compare
@bnoordhuis @orangemocha ... ping |
I had prototyped the BUILDTYPE switch in a separate CI job, but it was lost during one of the Jenkins security crises. It's an easy change to make. Does this need anything else from CI? /cc @jbergstroem, who also worked on supporting debug runs in CI. |
7da4fd4
to
c7066fb
Compare
I'd like the BUILDTYPE option in CI as well, but debug is slow and require more ram so we need to limit it to fewer buildbots. |
c133999
to
83c7a88
Compare
@skomski ... is this something you'd still like to pursue? |
Closing due to lack of forward progress on this. Can reopen and revisit if necessary |
mode=debug multiply platformTimeout by 5
Add debug VmFlags to GetCommand (
--verify-heap --debug-code --enable-slow-asserts
)Fixed tests that rely on zero arguments or hard coded timeouts
Possible to override platformTimeout with TEST_TIMEOUT_MULTIPLIER for longer timeouts for example with an asan debug release
Makes it possible to run
tools/test.py -J --mode=debug sequential message parallel
.