Skip to content
Myr

added charset test with res.render()

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 820b43c · Browse files · 1 file+15 added−1 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+15 added−1 removed

  • tests:+15 added−1 removed

1 file+15 added−1 removed

modified:test/response.test.js+15 added-1 removed
562 unmodified lines
563 { url: '/', method: 'HEAD' },564 { body: '', headers: { 'Content-Length': 11 }});565 },566 567 'test .charset': function(){567 'test .charset with res.send()': function(){568 var app = express.createServer();569570 app.get('/', function(req, res){571 res.charset = 'utf8';
2 unmodified lines
574575 assert.response(app,576 { url: '/' },577 { headers: { 'Content-Type': 'text/html; charset=utf8' }});578 },579580 'test .charset with res.render()': function(){581 var app = express.createServer();582 app.set('views', __dirname + '/fixtures');583584 app.get('/', function(req, res){585 res.charset = 'utf8';586 res.render('hello.jade');587 });588589 assert.response(app,590 { url: '/' },591 { headers: { 'Content-Type': 'text/html; charset=utf8' }});592 }593};