spec.static.js
This file
Path
spec/spec.static.js
22 lines · 526 bytes · JavaScript
Last changed by
Merge branch 'master' of git://github.com/visionmedia/expressciaranjbefore adoption3f9cbbb
History of this fileTake it
12345678910111213141516171819202122
describe 'Express' describe 'StaticFile' before StaticFile = require('express/static').File end describe '#init' it 'should accept and assign #path' (new StaticFile('/foo/bar')).path.should.eql '/foo/bar' end it 'should throw an InvalidPathError when .. is found' // TODO: use throw_error when fixed... try { new StaticFile('/../foobar') } catch (e) { e.should.be_an_instance_of InvalidPathError } end end endend