aboutsummaryrefslogtreecommitdiffhomepage
path: root/js/commonjs/strict_test.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/commonjs/strict_test.js')
-rw-r--r--js/commonjs/strict_test.js19
1 files changed, 16 insertions, 3 deletions
diff --git a/js/commonjs/strict_test.js b/js/commonjs/strict_test.js
index 12df8f85..46458c10 100644
--- a/js/commonjs/strict_test.js
+++ b/js/commonjs/strict_test.js
@@ -40,15 +40,28 @@ var global = Function('return this')();
googleProtobuf.object.extend(global, asserts);
var test9_pb = require('./test9_pb');
+var test10_pb = require('./test10_pb');
describe('Strict test suite', function() {
it('testImportedMessage', function() {
- var simple1 = new test9_pb.Simple9()
- var simple2 = new test9_pb.Simple9()
+ var simple1 = new test9_pb.jspb.exttest.strict.nine.Simple9()
+ var simple2 = new test9_pb.jspb.exttest.strict.nine.Simple9()
assertObjectEquals(simple1.toObject(), simple2.toObject());
});
it('testGlobalScopePollution', function() {
- assertObjectEquals(global.proto.jspb.test.Simple9, undefined);
+ assertObjectEquals(global.jspb.exttest, undefined);
+ });
+
+ describe('with imports', function() {
+ it('testImportedMessage', function() {
+ var simple1 = new test10_pb.jspb.exttest.strict.ten.Simple10()
+ var simple2 = new test10_pb.jspb.exttest.strict.ten.Simple10()
+ assertObjectEquals(simple1.toObject(), simple2.toObject());
+ });
+
+ it('testGlobalScopePollution', function() {
+ assertObjectEquals(global.jspb.exttest, undefined);
+ });
});
});