-
Notifications
You must be signed in to change notification settings - Fork 369
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
Fix tests passing when test commands fail #1733
Fix tests passing when test commands fail #1733
Conversation
37cbab5 accidentally changed tests to accept failing commands by default. This can cause tests to pass even though the program crashed, when a previous run created the correct output file. Signed-off-by: Brecht Van Lommel <brecht@blender.org>
Signed-off-by: Brecht Van Lommel <brecht@blender.org>
I made it pass tests even when there are memory leaks. Better would be to fix these (if possible), but I don't really have the time for that. There is not a lot to go on.
|
I don't mind sweeping a leak of 164 bytes under the rug for now, but does this change mask any other failures in the sanitizer run, which we would definitely want to catch? |
Signed-off-by: Brecht Van Lommel <brecht@blender.org>
It was masking all memory leaks. I made it more specific now, though it's still pretty broad. |
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.
LGTM
Apologies on the "failureok = 1" mistake -- that was me, probably something I had temporarily done while testing, and then forgot to restore.
A few months back, PR #1733 seems to have switched the order that testrender destroys the shading system versus the renderer (services). This made some subtle bugs that were only symptomatic for GPU renders, but it's because of the destructor order, where the shadingsystem's dtr still references the renderer, which cannot be destroyed yet. The clue is that the SS's constructor takes the RS pointer as an argument. The RS, then, must have been constructed before the SS, and therefore we should expect it to be a requirement for the RS to outlast the lifetime of the SS. (Complex objects should be destroyed in the opposite order that they were constructed, if they contain references to each other.) One code change is needed to avoid the sanitizer errors that the incorrect change was originally meant to address: clear shaders when SimpleRayTracer clears. Signed-off-by: Larry Gritz <lg@larrygritz.com> --------- Signed-off-by: Larry Gritz <lg@larrygritz.com>
Description
37cbab5 accidentally changed tests to accept failing commands by default.
This can cause tests to pass even though the program crashed, when a previous run created the correct output file.
This reveals existing asan and lsan errors. The asan error was fixed. The memory leaks remain ignored, as the exact cause is unclear.
Tests
N/A
Checklist: