From f738b9266ae181a7c2862f3e9b6bfa0b5e52380a Mon Sep 17 00:00:00 2001 From: Phred Date: Thu, 20 Nov 2014 17:11:41 -0600 Subject: [PATCH] updated packages and Makefile so tests would execute --- Makefile | 4 ++-- package.json | 16 +++++++++------- test/main.litcoffee | 16 +++++++--------- 3 files changed, 18 insertions(+), 18 deletions(-) diff --git a/Makefile b/Makefile index 4761bde..27d8395 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ .PHONY: test watch test: - ./node_modules/.bin/mocha --reporter list --compilers litcoffee:coffee-script + ./node_modules/.bin/mocha --reporter list --compilers litcoffee:coffee-script/register watch: - ./node_modules/.bin/nodemon ./node_modules/.bin/mocha --reporter list --compilers litcoffee:coffee-script --growl --bail --debug + ./node_modules/.bin/nodemon ./node_modules/.bin/mocha --reporter list --compilers litcoffee:coffee-script/register --growl --bail --debug diff --git a/package.json b/package.json index 2e8c91a..cc0ea35 100644 --- a/package.json +++ b/package.json @@ -23,14 +23,16 @@ "url": "https://github.com/wballard/flinger/issues" }, "dependencies": { - "connect": ">2.0.0", - "uglify-js": "~2.3.6" + "connect": "^3.3.3", + "uglify-js": "^2.4.15" }, "devDependencies": { - "mocha": "~1.12.0", - "coffee-script": "~1.6.3", - "zombie": "~2.0.0-alpha19", - "chai": "~1.7.2", - "nodemon": "~0.7.8" + "chai": "^1.10.0", + "coffee-script": "^1.8.0", + "cookie-parser": "^1.3.3", + "mocha": "^2.0.1", + "nodemon": "^1.2.1", + "serve-static": "^1.7.1", + "zombie": "^2.2.1" } } diff --git a/test/main.litcoffee b/test/main.litcoffee index a9e213e..57a0a74 100644 --- a/test/main.litcoffee +++ b/test/main.litcoffee @@ -9,8 +9,8 @@ Test connection and action over a streaming socket. describe "Client library shim", -> before (done) -> app = connect() - .use(connect.cookieParser()) - .use(connect.static(path.join(__dirname, 'client'))) + .use(require('cookie-parser')()) + .use(require('serve-static')(path.join(__dirname, 'client'))) .use(flinger()) .listen(9999) done() @@ -18,12 +18,10 @@ Test connection and action over a streaming socket. done() it "serves a browser client self test page", (done) -> this.timeout(5000) - browser = new Browser() - browser.debug = true - browser.runScripts = true - browser.visit 'http://localhost:9999/index.html', -> - browser.success.should.be.ok - done() - , (err) -> + Browser.visit 'http://localhost:9999/index.html', + {debug: true, runScripts: true}, (err, browser) -> if err console.log 'ERRRRR', err + return done(err) + browser.success.should.be.ok + done()