Skip to content

Commit bbb3a31

Browse files
author
Mohsen Azimi
committed
convert to integration test
1 parent 6f6c12c commit bbb3a31

File tree

4 files changed

+11
-20
lines changed

4 files changed

+11
-20
lines changed

test/HarmonyExportImportedSpecifierDependency.unittest.js

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -13,24 +13,4 @@ describe("HarmonyExportImportedSpecifierDependency", () => {
1313
should(instance.getHashValue(null)).be.eql("");
1414
});
1515
});
16-
describe("getContent", () => {
17-
describe("dynamic-reexport mode", () => {
18-
it("should generate proper content", () => {
19-
const instance = new HarmonyExportImportedSpecifierDependency();
20-
const dep = {
21-
activeExports: ["module.exports = 1 //?"],
22-
originModule: {
23-
exportsArgument: "ClassName"
24-
},
25-
_discoverActiveExportsFromOtherStartExports() {
26-
return [];
27-
},
28-
getMode() {
29-
return "dynamic-reexport";
30-
}
31-
};
32-
should(instance.getContent(dep)).to.eql("???");
33-
});
34-
});
35-
});
3616
});
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
export var x = 1;
2+
export * from "./cjs";
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
module.exports = { x: 2, y: 3 };
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
"use strict";
2+
3+
import {x, y} from "./a";
4+
5+
it("namespace export as from commonjs should override named export", function() {
6+
x.should.be.eql(2);
7+
y.should.be.eql(3);
8+
});

0 commit comments

Comments
 (0)