Closed
Bug 816086
Opened 12 years ago
Closed 8 years ago
B2G XPCShell: Segfault after test has finished and before next one starts
Categories
(Testing :: XPCShell Harness, defect)
Tracking
(Not tracked)
RESOLVED
WONTFIX
People
(Reporter: ahal, Unassigned)
References
Details
Comment 1•12 years ago
|
||
This is dumping the contents of an ELF binary for some reason. (Probably xpcshell itself.)
Reporter | ||
Comment 2•12 years ago
|
||
This is true for all tests, not just ones that fail. This is what's causing bug 815641 (and probably also bug 773703).
stdout is getting set here: http://hg.mozilla.org/mozilla-central/file/6c23f41b0747/testing/xpcshell/runxpcshelltests.py#l815
Since it contains gibberish and getReturnCode() just always returns 0 on b2g we never meet any of the fail conditions here: http://hg.mozilla.org/mozilla-central/file/6c23f41b0747/testing/xpcshell/runxpcshelltests.py#l830 and consequently every test is marked as PASS.
Either we aren't getting the output properly, or tests aren't running at all (or both).
Summary: B2G xpcshell tests dump byte code to the log on failure → B2G xpcshell proc.stdout is dumping a binary instead of test logs
Reporter | ||
Comment 4•12 years ago
|
||
Phew, it was a silly mistake! The desktop version of xpcshell was getting copied over instead of the arm one. Fixing that exposes a new error though:
TEST-INFO | /home/ahal/git/B2G/objdir-gecko/dist/test-package-stage/xpcshell/tests/chrome/test/unit/test_abi.js | running test ...
xpcw: cd /data/local/tests/xpcshell/chrome/test/unit
xpcw: xpcshell -r /data/local/tests/xpcshell/c/httpd.manifest -m -n -s -e const _HTTPD_JS_PATH = "/data/local/tests/xpcshell/c/httpd.js"; -e const _HEAD_JS_PATH = "/data/local/tests/xpcshell/head.js"; -e const _TESTING_MODULES_DIR = "/data/local/tests/xpcshell/m"; -f /data/local/tests/xpcshell/head.js -e const _SERVER_ADDR = "localhost" -e const _HEAD_FILES = ["/data/local/tests/xpcshell/chrome/test/unit/head_crtestutils.js"]; -e const _TAIL_FILES = []; -e const _TEST_FILE = ["test_abi.js"]; -e _execute_test(); quit(0);
/data/local/tests/xpcshell/head.js:286: Error: Specified modules directory does not exist: /data/local/tests/xpcshell/m
[1] Segmentation fault /data/local/test...
TEST-PASS | /home/ahal/git/B2G/objdir-gecko/dist/test-package-stage/xpcshell/tests/chrome/test/unit/test_abi.js | test passed (time: 2503.102ms)
Summary: B2G xpcshell proc.stdout is dumping a binary instead of test logs → B2G XPCShell: Specified modules directory does not exist: /data/local/tests/xpcshell/m
Comment 5•12 years ago
|
||
That should be created here: https://hg.mozilla.org/mozilla-central/file/85471409cbfb/testing/xpcshell/remotexpcshelltests.py#l162
Reporter | ||
Comment 6•12 years ago
|
||
Which was solved by adding --testing-modules-dir tests/modules. The tests seem to be running fine, though many (most?) have a segfault after the test finishes and before the next one starts. This is probably why we get a return code of 1 all the time (see bug 773703). Maybe this isn't causing a problem, but still worth investigating.
e.g:
TEST-INFO | /home/ahal/git/B2G/objdir-gecko/dist/test-package-stage/xpcshell/tests/chrome/test/unit/test_bug399707.js | running test ...
xpcw: cd /data/local/tests/xpcshell/chrome/test/unit
xpcw: xpcshell -r /data/local/tests/xpcshell/c/httpd.manifest -m -n -s -e const _HTTPD_JS_PATH = "/data/local/tests/xpcshell/c/httpd.js"; -e const _HEAD_JS_PATH = "/data/local/tests/xpcshell/head.js"; -e const _TESTING_MODULES_DIR = "/data/local/tests/xpcshell/m"; -f /data/local/tests/xpcshell/head.js -e const _SERVER_ADDR = "localhost" -e const _HEAD_FILES = ["/data/local/tests/xpcshell/chrome/test/unit/head_crtestutils.js"]; -e const _TAIL_FILES = []; -e const _TEST_FILE = ["test_bug399707.js"]; -e _execute_test(); quit(0);
TEST-INFO | (xpcshell/head.js) | test 1 pending
TEST-PASS | test_bug399707.js | [test_succeeded_mapping : 61] file:///data/local/tests/xpcshell/chrome/test/unit/data/test/test.xul == file:///data/local/tests/xpcshell/chrome/test/unit/data/test/test.xul
TEST-PASS | test_bug399707.js | [test_succeeded_mapping : 61] file:///data/local/tests/xpcshell/chrome/test/unit/data/test/test.xul == file:///data/local/tests/xpcshell/chrome/test/unit/data/test/test.xul
TEST-PASS | test_bug399707.js | [test_succeeded_mapping : 61] file:///data/local/tests/xpcshell/chrome/test/unit/data/test/test.xul == file:///data/local/tests/xpcshell/chrome/test/unit/data/test/test.xul
TEST-INFO | (xpcshell/head.js) | test 1 finished
TEST-INFO | (xpcshell/head.js) | exiting test
TEST-PASS | (xpcshell/head.js) | 3 (+ 0) check(s) passed
TEST-INFO | (xpcshell/head.js) | 0 check(s) todo
[1] Segmentation fault /data/local/test...
TEST-PASS | /home/ahal/git/B2G/objdir-gecko/dist/test-package-stage/xpcshell/tests/chrome/test/unit/test_bug399707.js | test passed (time: 2106.885ms)
Reporter | ||
Updated•12 years ago
|
Assignee: nobody → ahalberstadt
Status: NEW → ASSIGNED
Reporter | ||
Updated•12 years ago
|
Summary: B2G XPCShell: Specified modules directory does not exist: /data/local/tests/xpcshell/m → B2G XPCShell: Segfault after test has finished and before next one starts
Reporter | ||
Comment 7•12 years ago
|
||
Geoff, someone mentioned this was a problem on fennec too. Have you seen segfaults like that before?
Flags: needinfo?(gbrown)
Comment 8•12 years ago
|
||
Yes, absolutely. See bug 768491...but the discussion is a little confused there.
Summary: On Tegras, xpcshell crashes with a SIGSEGV on exit -- after main() ends. This happens every time, regardless of arguments. In fact, if I comment out the entire contents of main(), it still crashes. I have not been able to get a sensible backtrace with gdb, and don't know where the problem is. On all other devices that I have tested (Galaxy S, Android 2.3; Galaxy Nexus, 4.0.4; Pandaboard, 4.0.3?), there is no such crash.
Flags: needinfo?(gbrown)
Reporter | ||
Comment 9•12 years ago
|
||
Thanks, I'll leave this open for now, but unassigning myself as I'm probably not the best person to be debugging this.
Status: ASSIGNED → NEW
Reporter | ||
Updated•12 years ago
|
Assignee: ahalberstadt → nobody
Reporter | ||
Comment 10•12 years ago
|
||
I'm not sure that this blocks getting the tests running on tbpl as the segfault appears to happen after the test finishes successfully.
Reporter | ||
Updated•8 years ago
|
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → WONTFIX
You need to log in
before you can comment on or make changes to this bug.
Description
•