diff --git a/tools/tests/apps/modules/package.json b/tools/tests/apps/modules/package.json index 87e4246990..80760a1e6d 100644 --- a/tools/tests/apps/modules/package.json +++ b/tools/tests/apps/modules/package.json @@ -10,6 +10,8 @@ "path": "^0.12.7", "regenerator": "^0.8.42", "stream-browserify": "^2.0.1", + "stream-http": "^2.1.1", + "url": "^0.11.0", "util": "^0.10.3" }, "scripts": { diff --git a/tools/tests/apps/modules/tests.js b/tools/tests/apps/modules/tests.js index ffb93b17b1..3ea26630bf 100644 --- a/tools/tests/apps/modules/tests.js +++ b/tools/tests/apps/modules/tests.js @@ -195,6 +195,17 @@ describe("native node_modules", () => { assert.strictEqual(typeof Stream, "function"); assert.strictEqual(typeof Stream.Readable, "function"); }); + + Meteor.isClient && + it("can be installed with aliases", () => { + meteorInstall({ + node_modules: { + http: "stream-http" + } + }); + + assert.strictEqual(require("http"), require("stream-http")); + }); }); describe("local node_modules", () => {