Skip to content

Commit 91c3a1a

Browse files
committed
additional test case for umd2
1 parent 0380796 commit 91c3a1a

2 files changed

Lines changed: 20 additions & 0 deletions

File tree

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
it("should not fail on optional externals", function() {
2+
require("external2");
3+
try {
4+
require("external");
5+
} catch(e) {
6+
e.should.be.instanceof(Error);
7+
e.code.should.be.eql("MODULE_NOT_FOUND");
8+
return;
9+
}
10+
throw new Error("It doesn't fail");
11+
});
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
module.exports = {
2+
output: {
3+
libraryTarget: "umd2"
4+
},
5+
externals: {
6+
external: "external",
7+
external2: "fs"
8+
}
9+
};

0 commit comments

Comments
 (0)