Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'deps/npm/test/lib/utils/update-notifier.js')
-rw-r--r--deps/npm/test/lib/utils/update-notifier.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/deps/npm/test/lib/utils/update-notifier.js b/deps/npm/test/lib/utils/update-notifier.js
index 1735b31057b..ad4d407728f 100644
--- a/deps/npm/test/lib/utils/update-notifier.js
+++ b/deps/npm/test/lib/utils/update-notifier.js
@@ -145,15 +145,15 @@ t.test('situations in which we do not notify', t => {
})
t.test('only check weekly for GA releases', async t => {
- // the 10 is fuzz factor for test environment
- STAT_MTIME = Date.now() - (1000 * 60 * 60 * 24 * 7) + 10
+ // One week (plus five minutes to account for test environment fuzziness)
+ STAT_MTIME = Date.now() - (1000 * 60 * 60 * 24 * 7) + (1000 * 60 * 5)
t.equal(await updateNotifier(npm), null)
t.strictSame(MANIFEST_REQUEST, [], 'no requests for manifests')
})
t.test('only check daily for betas', async t => {
- // the 10 is fuzz factor for test environment
- STAT_MTIME = Date.now() - (1000 * 60 * 60 * 24) + 10
+ // One day (plus five minutes to account for test environment fuzziness)
+ STAT_MTIME = Date.now() - (1000 * 60 * 60 * 24) + (1000 * 60 * 5)
t.equal(await updateNotifier({ ...npm, version: HAVE_BETA }), null)
t.strictSame(MANIFEST_REQUEST, [], 'no requests for manifests')
})