Note: There are a few cases of duplicates in user autocompletion which are being worked on.

XPI_NAME-built extensions not available to make check

NEW
Unassigned

Status

Testing
XPCShell Harness
11 years ago
9 years ago

People

(Reporter: Robert Sayre, Unassigned)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

11 years ago
 
(Reporter)

Comment 1

11 years ago
function run_test() {
  try {
    const cid = "@senecac.on.ca/firstxpcom;1";
    var obj = Components.classes[cid].createInstance();
    obj = obj.QueryInterface(Components.interfaces.IFirstXpcom);
  } catch (err) {
    do_throw(err);
    return;
}

  do_check_true(true);
}

$ make check

...
*** test pending
*** exiting
*** CHECK FAILED: TypeError: Components.classes[cid] has no properties
JS frame :: ../../../dist/bin/test-harness/xpcshell-simple/head.js :: do_throw :: line 98
JS frame :: ../../../dist/bin/test_firstxpcom/test_sample.js :: run_test :: line 52
JS frame :: ../../../dist/bin/test-harness/xpcshell-simple/tail.js :: <TOP_LEVEL> :: line 41
2147500036
*** FAIL ***
Created attachment 256131 [details]
Binary Extension that caused the make check error.

Here's my simple XPCOM example (mozilla/extensions/firstxpcom) from a tutorial I'm writing.
(Reporter)

Comment 3

11 years ago
I get the same thing. Normally, Firefox will start up ExtensionManager, register these things, quit, and then start again. Not sure how to make xpcshell do this.
xpcshell doesn't know anything about extensions, and can't really be taught. We could write a xulrunner-based xpcshell replacement that has the extension-management smarts.
(Reporter)

Comment 5

11 years ago
Ah. bug 359830 seems to have something like that already.
Component: Testing → TUnit
Product: Core → Testing
QA Contact: testing → tunit
Version: Trunk → unspecified
You need to log in before you can comment on or make changes to this bug.