1 | defaultargs = require '../lib/defaultargs'
|
2 |
|
3 | describe 'defaultargs', ->
|
4 | describe '#defaultargs()', ->
|
5 | it 'should not write over give args', ->
|
6 | defaultargs({port: 1234}).port.should.equal(1234)
|
7 | it 'should write non give args', ->
|
8 | defaultargs().port.should.equal(3000)
|
9 | it 'should modify dependant args', ->
|
10 | defaultargs({data: '/tmp/asdf/'}).db.should.equal('/tmp/asdf/pages')
|