Skip to content
Myr

Added test for collection option with an object

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 687e435 · Browse files · 1 file+12 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

1 file+12 added−0 removed

  • tests:+12 added−0 removed

1 file+12 added−0 removed

modified:test/view.test.js+12 added
350 unmodified lines
351 352 assert.response(app,353 { url: '/user' },354 { body: '<p>tj</p>' });355356 // as: with object collection357 app.get('/user/object', function(req, res){358 res.send(res.partial('user.jade', {359 as: 'person',360 collection: { 0: { name: 'tj' }, length: 1 }361 }));362 });363 364 assert.response(app,365 { url: '/user' },366 { body: '<p>tj</p>' });367 368 // as: this collection option369 app.get('/person', function(req, res){370 res.send(res.partial('person.jade', {371 as: this,
181 unmodified lines