From 652587757844794d26ae06a716a2cfa4f6b7b26d Mon Sep 17 00:00:00 2001 From: Timothy Gu Date: Wed, 3 Jan 2018 10:28:28 +0800 Subject: [PATCH] Fix lint --- .travis.yml | 2 ++ package.json | 3 ++- test/primitives/global-monotonic-clock.js | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index cf643ec..bbdf88f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -4,6 +4,8 @@ node_js: - "8" - stable +cache: yarn + script: - yarn test - yarn lint diff --git a/package.json b/package.json index 8744038..b8a68bb 100644 --- a/package.json +++ b/package.json @@ -16,7 +16,8 @@ "jest": "^22.0.4" }, "scripts": { - "test": "jest" + "test": "jest", + "lint": "eslint ." }, "files": [ "lib", diff --git a/test/primitives/global-monotonic-clock.js b/test/primitives/global-monotonic-clock.js index 99703e6..7a8edcd 100644 --- a/test/primitives/global-monotonic-clock.js +++ b/test/primitives/global-monotonic-clock.js @@ -8,7 +8,7 @@ const DELTA = 20; // ±20 ms const NUM_DIGITS = -Math.log10(DELTA * 2); function testGlobalMonotonicClock(FACTOR = 1) { - let clockDriftDesc = FACTOR !== 1 ? " and is not affected by clock drift" : ""; + const clockDriftDesc = FACTOR !== 1 ? " and is not affected by clock drift" : ""; test("global monotonic clock corresponds with setTimeout" + clockDriftDesc, () => { const startDateNow = Date.now(); const startGlobalMonotonicClock = getGlobalMonotonicClockMS();