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