Skip to content
Myr

Added test for res.sendfile() with non-GET. Closes #723

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Tj Holowaychuk · committed by Tj Holowaychuk · parent 6ae32fd · Browse files · 2 files+17 added−0 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

2 files+17 added−0 removed

  • tests:+17 added−0 removed

2 files+17 added−0 removed

added:test/fixtures/name.txt+1 added
1tobi
modified:test/res.sendfile.js+16 added
190 unmodified lines
191 calls.should.equal(1);192 done();193 });194 })195196 describe('with non-GET', function(){197 it('should still serve', function(done){198 var app = express()199 , calls = 0;200201 app.use(function(req, res){202 res.sendfile(__dirname + '/fixtures/name.txt');203 });204205206 request(app)207 .get('/')208 .expect('tobi', done);209 })210 })211 })212 })213})