Skip to content

Commit

Permalink
Change node static server root to ../
Browse files Browse the repository at this point in the history
  • Loading branch information
lifesinger committed Jun 24, 2013
1 parent f8141ce commit b05482b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
6 changes: 1 addition & 5 deletions Makefile
Expand Up @@ -3,10 +3,6 @@ build:
@grunt
@$(MAKE) size

build_all:
@grunt all
@$(MAKE) size

test: test_node test_local test_http

test_node:
Expand All @@ -16,7 +12,7 @@ test_local:
@phantomjs tools/phantom.js tests/runner.html?console

test_http:
@node tools/server.js tests/runner.html?console
@node tools/server.js seajs/tests/runner.html?console

totoro:
@totoro --adapter=tests/totoro-adapter.js
Expand Down
4 changes: 2 additions & 2 deletions tools/server.js
Expand Up @@ -8,11 +8,11 @@ var Static = require('node-static')

function createServer(filepath, port) {
port = parseInt(port || 9012)
var file = new Static.Server(fs.realpathSync('.'))
var fileServer = new Static.Server(fs.realpathSync('../'))

var server = http.createServer(function(request, response) {
request.addListener('end',function() {
file.serve(request, response)
fileServer.serve(request, response)
}).resume()
})

Expand Down

0 comments on commit b05482b

Please sign in to comment.