Created
March 24, 2015 15:53
-
-
Save jkresner/35aa5b8381e6dfbe4a95 to your computer and use it in GitHub Desktop.
es6 Bootstrap with traceur
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
var setup = require('./server/util/_setup') | |
var config = setup.initConfig(process.env.env || 'dev') | |
setup.initGlobals(config) | |
require('./index').run() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// express app goes here |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require('./setup/flavor') | |
{initGlobals,initConfig} = require('./../../server/util/_setup') | |
initGlobals(initConfig('test')) | |
describe 'Server: ', -> | |
@timeout(4000) | |
before (done) -> | |
@timeout(10000) | |
global.logging = false | |
global.app = require('../../index').run() | |
global.stubs = SETUP.initStubs() | |
testHttpHelpers.init(app) | |
setTimeout(( -> SETUP.init(done) ), 100) | |
beforeEach -> | |
LOGOUT() | |
describe 'Session: ', require('./sessionSpec') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var traceur = require('traceur') | |
require('traceur-source-maps').install(traceur) | |
traceur.require.makeDefault(function (filePath) { | |
return !~filePath.indexOf('node_modules')// && !~filePath.indexOf('test') != 0 | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Where's _setup?
How does setup return a single object?
And a tuple?