Node.js initialisiert
This commit is contained in:
index.jspackage-lock.jsonpackage.json
node_modules
.bin
accepts
after
array-flatten
arraybuffer.slice
async-limiter
.travis.ymlLICENSE
coverage
coverage.json
index.jspackage.jsonreadme.mdlcov-report
lcov.infobacko2
base64-arraybuffer
base64id
better-assert
blob
callsite
component-bind
component-emitter
component-inherit
content-disposition
content-type
cookie-signature
cookie
debug
.coveralls.yml.eslintrc.npmignore.travis.ymlCHANGELOG.mdLICENSEMakefileREADME.mdbower.jsoncomponent.jsonkarma.conf.jsnode.jspackage.json
src
depd
destroy
ee-first
encodeurl
engine.io-client
LICENSEREADME.mdengine.io.jspackage.json
lib
node_modules
debug
.coveralls.yml.eslintrc.npmignore.travis.ymlCHANGELOG.mdLICENSEMakefileREADME.mdkarma.conf.jsnode.jspackage.json
src
ms
engine.io-parser
engine.io
LICENSEREADME.mdpackage.json
lib
node_modules
debug
.coveralls.yml.eslintrc.npmignore.travis.ymlCHANGELOG.mdLICENSEMakefileREADME.mdkarma.conf.jsnode.jspackage.json
src
ms
escape-html
etag
express
History.mdLICENSEReadme.mdindex.js
lib
package.jsonfinalhandler
HISTORY.mdLICENSEREADME.mdindex.jspackage.json
node_modules
debug
.coveralls.yml.eslintrc.npmignore.travis.ymlCHANGELOG.mdLICENSEMakefileREADME.mdcomponent.jsonkarma.conf.jsnode.jspackage.json
src
ms
forwarded
fresh
has-binary2
has-cors
http-errors
indexof
inherits
ipaddr.js
isarray
media-typer
merge-descriptors
methods
mime-db
mime-types
mime
ms
negotiator
object-component
on-finished
parseqs
parseuri
parseurl
path-to-regexp
proxy-addr
qs
range-parser
safe-buffer
send
serve-static
setprototypeof
socket.io-adapter
socket.io-client
LICENSEREADME.mdpackage.json
dist
socket.io.dev.jssocket.io.dev.js.mapsocket.io.jssocket.io.js.mapsocket.io.slim.dev.jssocket.io.slim.dev.js.mapsocket.io.slim.jssocket.io.slim.js.map
lib
node_modules
debug
.coveralls.yml.eslintrc.npmignore.travis.ymlCHANGELOG.mdLICENSEMakefileREADME.mdkarma.conf.jsnode.jspackage.json
src
ms
socket.io-parser
LICENSEReadme.mdbinary.jsindex.jsis-buffer.jspackage.json
node_modules
debug
.coveralls.yml.eslintrc.npmignore.travis.ymlCHANGELOG.mdLICENSEMakefileREADME.mdkarma.conf.jsnode.jspackage.json
src
ms
socket.io
LICENSEReadme.mdpackage.json
lib
node_modules
debug
.coveralls.yml.eslintrc.npmignore.travis.ymlCHANGELOG.mdLICENSEMakefileREADME.mdkarma.conf.jsnode.jspackage.json
src
ms
statuses
to-array
type-is
ultron
unpipe
utils-merge
vary
ws
LICENSEREADME.mdindex.js
lib
.DS_StoreBufferUtil.jsConstants.jsErrorCodes.jsEventTarget.jsExtensions.jsPerMessageDeflate.jsReceiver.jsSender.jsValidation.jsWebSocket.jsWebSocketServer.js
package.jsonxmlhttprequest-ssl
yeast
public
48
node_modules/object-component/test/object.js
generated
vendored
Normal file
48
node_modules/object-component/test/object.js
generated
vendored
Normal file
@@ -0,0 +1,48 @@
|
||||
|
||||
/**
|
||||
* Module dependencies.
|
||||
*/
|
||||
|
||||
var object = require('..');
|
||||
|
||||
describe('.keys(obj)', function(){
|
||||
it('should return the keys of an object', function(){
|
||||
var obj = { name: 'tobi', age: 1 };
|
||||
object.keys(obj).should.eql(['name', 'age']);
|
||||
})
|
||||
})
|
||||
|
||||
describe('.values(obj)', function(){
|
||||
it('should return the values of an object', function(){
|
||||
var obj = { name: 'tobi', age: 1 };
|
||||
object.values(obj).should.eql(['tobi', 1]);
|
||||
})
|
||||
})
|
||||
|
||||
describe('.length(obj)', function(){
|
||||
it('should return key count', function(){
|
||||
var obj = { name: 'tobi', age: 1 };
|
||||
object.length(obj).should.equal(2);
|
||||
})
|
||||
})
|
||||
|
||||
describe('.merge(a, b)', function(){
|
||||
it('should merge two objects', function(){
|
||||
var a = { foo: 'bar' };
|
||||
var b = { bar: 'baz' };
|
||||
object.merge(a, b).should.eql({ foo: 'bar', bar: 'baz' });
|
||||
})
|
||||
|
||||
it('should give precedence to b', function(){
|
||||
var a = { foo: 'bar' };
|
||||
var b = { foo: 'baz' };
|
||||
object.merge(a, b).should.eql({ foo: 'baz' });
|
||||
})
|
||||
})
|
||||
|
||||
describe('.isEmpty()', function(){
|
||||
it('should check if the object is empty', function(){
|
||||
object.isEmpty({}).should.be.true;
|
||||
object.isEmpty({ foo: 'bar' }).should.be.false;
|
||||
})
|
||||
})
|
Reference in New Issue
Block a user