Skip to content

Commit

Permalink
adds test file for headers
Browse files Browse the repository at this point in the history
  • Loading branch information
sintaxi committed Oct 10, 2013
1 parent 25e781f commit a4e934f
Show file tree
Hide file tree
Showing 4 changed files with 33 additions and 1 deletion.
9 changes: 9 additions & 0 deletions test/404.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<html>
<head>
<title>404</title>
</head>
<body>
<h1>404</h1>
<p>page not found</p>
</body>
</html>
File renamed without changes.
23 changes: 23 additions & 0 deletions test/headers.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
var should = require("should")
var superagent = require('superagent')
var path = require('path')
var harp = require('../')



describe("headers", function(){
var projectPath = path.join(__dirname, "apps/headers")
var port = 8901

before(function(done){
harp.server(projectPath, { port: port }, done)
})

it("should return correct mime type for css files", function(done){
superagent.agent().get("http://localhost:" + port + "/invalid-jade.html").end(function(err, rsp){
rsp.should.have.status(500)
done()
})
})

})
2 changes: 1 addition & 1 deletion test/invalid.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ var harp = require('../')



describe("invalid", function(){
describe("headers", function(){
var projectPath = path.join(__dirname, "apps/err-invalid-source-files")
var port = 8801

Expand Down

0 comments on commit a4e934f

Please sign in to comment.