summaryrefslogtreecommitdiffstats
path: root/js/xpconnect/tests/chrome/file_expandosharing.jsm
blob: f680ae20a99384d0e7e638bd865e2b99dc640dce (plain)
1
2
3
4
5
6
7
8
9
10
11
12
var EXPORTED_SYMBOLS = ["checkFromJSM"];

function checkFromJSM(target, is_op) {
  is_op(target.numProp, 42, "Number expando works");
  is_op(target.strProp, "foo", "String expando works");
  // If is_op is todo_is, target.objProp will be undefined.
  try {
    is_op(target.objProp.bar, "baz", "Object expando works");
  } catch (e) {
    is_op(0, 1, "No object expando");
  }
}