Skip to content

Commit

Permalink
Update .travis.yml
Browse files Browse the repository at this point in the history
Remove unsupported node versions
  • Loading branch information
jhnns committed Nov 11, 2017
1 parent b6cc407 commit d6bc7ac
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 9 deletions.
5 changes: 2 additions & 3 deletions .travis.yml
@@ -1,10 +1,9 @@
language: node_js
node_js:
- "0.10"
- "0.12"
- "4"
- "5"
- "6"
- "8"
- "9"

script:
- npm test
Expand Down
2 changes: 1 addition & 1 deletion test/rewire.test.js
Expand Up @@ -16,7 +16,7 @@ describe("rewire", function () {
fs.renameSync(fakeNodeModules, path.resolve(__dirname, "../testLib/node_modules"));
}
});
require("../testLib/sharedTestCases.js");
require("../testLib/sharedTestCases.js")();
it("should also work with CoffeeScript", function () {
var coffeeModule;

Expand Down
6 changes: 3 additions & 3 deletions testLib/constModule.js
@@ -1,13 +1,13 @@
const someOtherModule = require("./someOtherModule");
const language = "nl";

module.exports.getLang = () => {
exports.getLang = () => {
return language;
}
};

exports.getOtherModuleName = () => {
return someOtherModule.name;
}
};

exports.filename = __filename;
exports.dirname = __dirname;
4 changes: 2 additions & 2 deletions testLib/sharedTestCases.js
Expand Up @@ -17,7 +17,7 @@ function checkForTypeError(err) {
expect(err.constructor).to.be(TypeError);
}

describe(typeof testEnv === "undefined"? "(node)": "(" + testEnv + ")", function () {
module.exports = function () {

it("should work like require()", function () {
rewire("./moduleA.js").getFilename();
Expand Down Expand Up @@ -390,4 +390,4 @@ describe(typeof testEnv === "undefined"? "(node)": "(" + testEnv + ")", function
expect(constModule.dirname).to.equal(require("./constModule").dirname);
});

});
};

0 comments on commit d6bc7ac

Please sign in to comment.