     context.results = @buildResults.apply this, arguments
   env
 
-runEnvExpectingNormalTermination = (env, context, async) ->
+exports.runEnvExpectingNormalTermination = (env, context, async) ->
   oldEnv = spectacular.env
   env.run()
   .then (status) ->


createEnv = (block, context) ->
  env = spectacular.env.clone()
  env.options.noColors = true
  spyOn(env.runner, 'loadSpecs').andCallFake -> do block

    oldEnv.load()
    async.reject reason

exports.runEnvExpectingInterruption = (env, context, async) ->
  oldEnv = spectacular.env
  env.run()
  .then (status) =>
