spec.plugins.method-override.js
This file
Path
spec/spec.plugins.method-override.js
27 lines · 736 bytes · JavaScript
Last changed by
Changed __method__ to _method [#110]visionmediabefore adoptionae4a9c8
History of this fileTake it
The walk stopped after 200 commits: lines older than f09358b point at it.
Fixed wiki urivisionmediabefore adoptionf09358b
lines 1–10why, one step back12describe 'Express'3 before_each4 reset()5 use(require('express/plugins/method-override').MethodOverride)6 end7 8 describe 'MethodOverride'9 describe 'on'10 describe 'request'Changed __method__ to _method [#110]visionmediabefore adoptionae4a9c8
line 11why, one step back11 it 'should consider _method as the HTTP method'Fixed wiki urivisionmediabefore adoptionf09358b
lines 12–14why, one step back12 put('/user', function(){13 return 'updated user'14 })Changed __method__ to _method [#110]visionmediabefore adoptionae4a9c8
line 15why, one step back15 post('/user', { uri: { params: { _method: 'put' }}}).body.should.eql 'updated user'Fixed wiki urivisionmediabefore adoptionf09358b
lines 16–17why, one step back16 end17 Changed __method__ to _method [#110]visionmediabefore adoptionae4a9c8
line 18why, one step back18 it 'should force _method to lowercase to conform to internal uses'Fixed wiki urivisionmediabefore adoptionf09358b
lines 19–21why, one step back19 put('/user', function(){20 return 'updated user'21 })Changed __method__ to _method [#110]visionmediabefore adoptionae4a9c8
line 22why, one step back22 post('/user', { uri: { params: { _method: 'PUT' }}}).body.should.eql 'updated user'Fixed wiki urivisionmediabefore adoptionf09358b
lines 23–27why, one step back23 end24 end25 end26 end27end