Closed Bug 486570 Opened 15 years ago Closed 6 years ago

Shouldn't need to copy so many files for xpcshell tests in the test package

Categories

(Testing :: XPCShell Harness, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: catlee, Unassigned)

References

Details

Attachments

(1 obsolete file)

runxpcshelltests.py should be able to find the files and copy them into the appropriate locations before running tests.

Or better yet, the tests shouldn't require to have xpcshell, components and plugins copied into firefox' directory.
(In reply to comment #0)
> runxpcshelltests.py should be able to find the files and copy them into the
> appropriate locations before running tests.

I'm not wild about doing this, especially since in the current case (running from the objdir), it's not necessary at all.

> Or better yet, the tests shouldn't require to have xpcshell, components and
> plugins copied into firefox' directory.

This is bug 483202.
Depends on: 483202
Version: unspecified → Trunk
If you use runxpcshelltests.py --xre-dir=... then you should no longer need to copy files around, since bug 483202 landed.
This should just be a buildbot config change now (remove the copying steps).
Component: TUnit → Release Engineering
Product: Testing → mozilla.org
QA Contact: tunit → release
Version: Trunk → other
I'll see about doing this.
Assignee: nobody → bhearsum
This doesn't fix the root problem but there's a higher chance of us having recent builds later in the week than there is on a Monday morning.
Attachment #412685 - Flags: review?(nrthomas)
Comment on attachment 412685 [details] [diff] [review]
do nightly builds on tuesday rather than monday

sorry, wrong bug.
Attachment #412685 - Attachment is obsolete: true
Attachment #412685 - Flags: review?(nrthomas)
I got this working on Linux with:
python -u xpcshell/runxpcshelltests.py --symbols-path=symbols --manifest=xpcshell/tests/all-test-dirs.list --xre-path=firefox bin/xpcshell

I tried a similar thing with Mac:
python -u xpcshell/runxpcshelltests.py --symbols-path=symbols --manifest=xpcshell/tests/all-test-dirs.list --xre-path=./Minefield.app/Contents/MacOS bin/xpcshell
 in dir /builds/slave/mozilla-central-macosx-unittest-everythingelse/build (timeout 1200 secs)

but I got errors:
TEST-UNEXPECTED-FAIL | /builds/slave/mozilla-central-macosx-unittest-everythingelse/build/xpcshell/tests/test_intl_locale/unit/test_bug371611.js | test failed (with xpcshell return code: -5), see following log:
  >>>>>>>
  dyld: Library not loaded: @executable_path/libxpcom.dylib
  Referenced from: /builds/slave/mozilla-central-macosx-unittest-everythingelse/build/bin/xpcshell
  Reason: image not found

  <<<<<<<


I've tried a few different values for --xre-path including: Minefield.app/Contents/MacOS, bin, Minefield.app, and even running with Minefield.app/Contents/MacOS as the cwd, but I still got the same errors.

win32 still running
Actually, upon further investigation, Linux hasn't quite passed. I've got some sort looking (to me) failures:
TEST-UNEXPECTED-FAIL | (xpcshell/head.js) | TypeError: Cc['@mozilla.org/browser/browserglue;1'] is undefined

  <<<<<<<
TEST-UNEXPECTED-FAIL | /builds/moz2_slave/mozilla-central-linux-opt-unittest-everythingelse/build/xpcshell/tests/test_browser_places/unit/test_browserGlue_prefs.js | test failed (with xpcshell return code: 3), see following log:
  >>>>>>>
  /builds/moz2_slave/mozilla-central-linux-opt-unittest-everythingelse/build/xpcshell/tests/test_browser_places/unit/test_browserGlue_prefs.js:45: TypeError: Cc['@mozilla.org/browser/browserglue;1'] is undefined

  <<<<<<<
TEST-UNEXPECTED-FAIL | /builds/moz2_slave/mozilla-central-linux-opt-unittest-everythingelse/build/xpcshell/tests/test_browser_places/unit/test_browserGlue_restore.js | test failed (with xpcshell return code: 0), see following log:
  >>>>>>>
  TEST-INFO | (xpcshell/head.js) | test 1 pending
JS frame :: -e :: <TOP_LEVEL> :: line 1
TEST-INFO | (xpcshell/head.js) | exiting test

  <<<<<<<
TEST-PASS | /builds/moz2_slave/mozilla-central-linux-opt-unittest-everythingelse/build/xpcshell/tests/test_browser_places/unit/test_398914.js | test passed
TEST-UNEXPECTED-FAIL | /builds/moz2_slave/mozilla-central-linux-opt-unittest-everythingelse/build/xpcshell/tests/test_browser_places/unit/test_421483.js | test failed (with xpcshell return code: 3), see following log:
  >>>>>>>
  TEST-UNEXPECTED-FAIL | /builds/moz2_slave/mozilla-central-linux-opt-unittest-everythingelse/build/xpcshell/tests/test_browser_places/unit/test_421483.js | Could not get BrowserGlue service
 - See following stack:
JS frame :: /builds/moz2_slave/mozilla-central-linux-opt-unittest-everythingelse/build/xpcshell/head.js :: do_throw :: line 201
JS frame :: /builds/moz2_slave/mozilla-central-linux-opt-unittest-everythingelse/build/xpcshell/tests/test_browser_places/unit/test_421483.js :: <TOP_LEVEL> :: line 60
TEST-INFO | (xpcshell/head.js) | exiting test
uncaught exception: 2147500036

  <<<<<<<
TEST-UNEXPECTED-FAIL | /builds/moz2_slave/mozilla-central-linux-opt-unittest-everythingelse/build/xpcshell/tests/test_browser_places/unit/test_457441-import-export-corrupt-bookmarks-html.js | test failed (with xpcshell return code: 0), see following log:
  >>>>>>>
  TEST-INFO | (xpcshell/head.js) | test 1 pending
TEST-UNEXPECTED-FAIL | /builds/moz2_slave/mozilla-central-linux-opt-unittest-everythingelse/build/xpcshell/tests/test_browser_places/unit/test_457441-import-export-corrupt-bookmarks-html.js | 0 == 4 - See following stack:
JS frame :: /builds/moz2_slave/mozilla-central-linux-opt-unittest-everythingelse/build/xpcshell/head.js :: do_throw :: line 201
JS frame :: /builds/moz2_slave/mozilla-central-linux-opt-unittest-everythingelse/build/xpcshell/head.js :: do_check_eq :: line 231
JS frame :: /builds/moz2_slave/mozilla-central-linux-opt-unittest-everythingelse/build/xpcshell/tests/test_browser_places/unit/test_457441-import-export-corrupt-bookmarks-html.js :: database_check :: line 128
JS frame :: /builds/moz2_slave/mozilla-central-linux-opt-unittest-everythingelse/build/xpcshell/tests/test_browser_places/unit/test_457441-import-export-corrupt-bookmarks-html.js :: run_test :: line 81
JS frame :: /builds/moz2_slave/mozilla-central-linux-opt-unittest-everythingelse/build/xpcshell/head.js :: _execute_test :: line 129
JS frame :: -e :: <TOP_LEVEL> :: line 1
TEST-INFO | (xpcshell/head.js) | exiting test

  <<<<<<<
TEST-PASS | /builds/moz2_slave/mozilla-central-linux-opt-unittest-everythingelse/build/xpcshell/tests/test_browser_places/unit/test_bookmarksRestoreNotification.js | test passed
TEST-UNEXPECTED-FAIL | /builds/moz2_slave/mozilla-central-linux-opt-unittest-everythingelse/build/xpcshell/tests/test_browser_places/unit/test_bookmarks_html.js | test failed (with xpcshell return code: 0), see following log:
  >>>>>>>
  TEST-INFO | (xpcshell/head.js) | test 1 pending



This has become a much bigger timesink than I thought it would be, so I'm going to have to push this out, as it's working fine as is.
Assignee: bhearsum → nobody
Component: Release Engineering → Release Engineering: Future
Ok, thanks for trying. I'll do some testing when I get time and make sure things work before sending it back to you.
Blocks: 527458
Component: Release Engineering: Future → TUnit
Product: mozilla.org → Testing
QA Contact: release → tunit
Version: other → Trunk
Blocks: 564987, 533891
In the mozharness world, this is where this happens:
http://hg.mozilla.org/build/mozharness/annotate/8d677593e1f6/scripts/desktop_unittest.py#l295

I think somewhere along the way we fixed xpcshell so this would work for real, but I'd have to test things to make sure.
Mass closing bugs with no activity in 2+ years. If this bug is important to you, please re-open.
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: