diff options
Diffstat (limited to 'node_modules/date-now')
-rw-r--r-- | node_modules/date-now/.npmignore | 14 | ||||
-rw-r--r-- | node_modules/date-now/.testem.json | 14 | ||||
-rw-r--r-- | node_modules/date-now/.travis.yml | 4 | ||||
-rw-r--r-- | node_modules/date-now/LICENCE | 19 | ||||
-rw-r--r-- | node_modules/date-now/README.md | 45 | ||||
-rw-r--r-- | node_modules/date-now/index.js | 5 | ||||
-rw-r--r-- | node_modules/date-now/package.json | 63 | ||||
-rw-r--r-- | node_modules/date-now/seed.js | 16 | ||||
-rw-r--r-- | node_modules/date-now/test/index.js | 28 | ||||
-rw-r--r-- | node_modules/date-now/test/static/index.html | 10 |
10 files changed, 0 insertions, 218 deletions
diff --git a/node_modules/date-now/.npmignore b/node_modules/date-now/.npmignore deleted file mode 100644 index aa3fd4b85..000000000 --- a/node_modules/date-now/.npmignore +++ /dev/null @@ -1,14 +0,0 @@ -.DS_Store -.monitor -.*.swp -.nodemonignore -releases -*.log -*.err -fleet.json -public/browserify -bin/*.json -.bin -build -compile -.lock-wscript diff --git a/node_modules/date-now/.testem.json b/node_modules/date-now/.testem.json deleted file mode 100644 index 633c2ba84..000000000 --- a/node_modules/date-now/.testem.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "launchers": { - "node": { - "command": "npm test" - } - }, - "src_files": [ - "./**/*.js" - ], - "before_tests": "npm run build", - "on_exit": "rm test/static/bundle.js", - "test_page": "test/static/index.html", - "launch_in_dev": ["node", "phantomjs"] -} diff --git a/node_modules/date-now/.travis.yml b/node_modules/date-now/.travis.yml deleted file mode 100644 index ed178f635..000000000 --- a/node_modules/date-now/.travis.yml +++ /dev/null @@ -1,4 +0,0 @@ -language: node_js -node_js: - - 0.8 - - 0.9 diff --git a/node_modules/date-now/LICENCE b/node_modules/date-now/LICENCE deleted file mode 100644 index 822d880b9..000000000 --- a/node_modules/date-now/LICENCE +++ /dev/null @@ -1,19 +0,0 @@ -Copyright (c) 2012 Colingo. - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. diff --git a/node_modules/date-now/README.md b/node_modules/date-now/README.md deleted file mode 100644 index 22d267536..000000000 --- a/node_modules/date-now/README.md +++ /dev/null @@ -1,45 +0,0 @@ -# date-now - -[![build status][1]][2] - -[![browser support][3]][4] - -A requirable version of Date.now() - -Use-case is to be able to mock out Date.now() using require interception. - -## Example - -```js -var now = require("date-now") - -var ts = now() -var ts2 = Date.now() -assert.equal(ts, ts2) -``` - -## example of seed - -``` -var now = require("date-now/seed")(timeStampFromServer) - -// ts is in "sync" with the seed value from the server -// useful if your users have their local time being a few minutes -// out of your server time. -var ts = now() -``` - -## Installation - -`npm install date-now` - -## Contributors - - - Raynos - -## MIT Licenced - - [1]: https://secure.travis-ci.org/Colingo/date-now.png - [2]: http://travis-ci.org/Colingo/date-now - [3]: http://ci.testling.com/Colingo/date-now.png - [4]: http://ci.testling.com/Colingo/date-now diff --git a/node_modules/date-now/index.js b/node_modules/date-now/index.js deleted file mode 100644 index d5f143a84..000000000 --- a/node_modules/date-now/index.js +++ /dev/null @@ -1,5 +0,0 @@ -module.exports = now - -function now() { - return new Date().getTime() -} diff --git a/node_modules/date-now/package.json b/node_modules/date-now/package.json deleted file mode 100644 index 832f0eedc..000000000 --- a/node_modules/date-now/package.json +++ /dev/null @@ -1,63 +0,0 @@ -{ - "name": "date-now", - "version": "0.1.4", - "description": "A requirable version of Date.now()", - "keywords": [], - "author": "Raynos <raynos2@gmail.com>", - "repository": "git://github.com/Colingo/date-now.git", - "main": "index", - "homepage": "https://github.com/Colingo/date-now", - "contributors": [ - { - "name": "Artem Shoobovych" - } - ], - "bugs": { - "url": "https://github.com/Colingo/date-now/issues", - "email": "raynos2@gmail.com" - }, - "dependencies": {}, - "devDependencies": { - "tape": "~0.2.2", - "browserify": "https://github.com/raynos/node-browserify/tarball/master", - "testem": "~0.2.52" - }, - "licenses": [ - { - "type": "MIT", - "url": "http://github.com/Colingo/date-now/raw/master/LICENSE" - } - ], - "scripts": { - "test": "node ./test", - "build": "browserify test/index.js -o test/static/bundle.js", - "testem": "testem" - }, - "testling": { - "files": "test/*.js", - "browsers": { - "ie": [ - "8", - "9", - "10" - ], - "firefox": [ - "16", - "17", - "nightly" - ], - "chrome": [ - "22", - "23", - "canary" - ], - "opera": [ - "12", - "next" - ], - "safari": [ - "5.1" - ] - } - } -} diff --git a/node_modules/date-now/seed.js b/node_modules/date-now/seed.js deleted file mode 100644 index b9727c5a3..000000000 --- a/node_modules/date-now/seed.js +++ /dev/null @@ -1,16 +0,0 @@ -var now = require("./index") - -module.exports = seeded - -/* Returns a Date.now() like function that's in sync with - the seed value -*/ -function seeded(seed) { - var current = now() - - return time - - function time() { - return seed + (now() - current) - } -} diff --git a/node_modules/date-now/test/index.js b/node_modules/date-now/test/index.js deleted file mode 100644 index 270584cab..000000000 --- a/node_modules/date-now/test/index.js +++ /dev/null @@ -1,28 +0,0 @@ -var test = require("tape") -var setTimeout = require("timers").setTimeout - -var now = require("../index") -var seeded = require("../seed") - -test("date", function (assert) { - var ts = now() - var ts2 = Date.now() - assert.equal(ts, ts2) - assert.end() -}) - -test("seeded", function (assert) { - var time = seeded(40) - var ts = time() - - within(assert, time(), 40, 5) - setTimeout(function () { - within(assert, time(), 90, 10) - assert.end() - }, 50) -}) - -function within(assert, a, b, offset) { - assert.ok(a + offset > b) - assert.ok(a - offset < b) -} diff --git a/node_modules/date-now/test/static/index.html b/node_modules/date-now/test/static/index.html deleted file mode 100644 index 3d5384da8..000000000 --- a/node_modules/date-now/test/static/index.html +++ /dev/null @@ -1,10 +0,0 @@ -<!doctype html> -<html> -<head> - <title>TAPE Example</title> - <script src="/testem.js"></script> - <script src="bundle.js"></script> -</head> -<body> -</body> -</html> |