Skip to content

Commit

Permalink
feat(server): wait for frameworks to load via q.all() before starting…
Browse files Browse the repository at this point in the history
… server

The API is to simply return a promise from a factory function, or use a promise as a value. The server
will wait for the collection of frameworks to resolve before carrying on starting the server.

This is useful for when setup requires some asynchronous startup.

Currently, any Promise api which is interoperable with q may be used.

In addition to this feature, this CL also adds a set of callbacks to the server, via an object for the
3rd parameter. This is useful for test purposes, and enables the test case to run faster, by not waiting
for the server to shut down via the second parameter.

Closes karma-runner#851
  • Loading branch information
caitp committed May 1, 2014
1 parent 573ea09 commit 62e5039
Show file tree
Hide file tree
Showing 3 changed files with 245 additions and 186 deletions.
1 change: 1 addition & 0 deletions Gruntfile.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ JSHINT_BROWSER =
JSHINT_NODE =
node: true,
strict: false
latedef: "nofunc"

module.exports = (grunt) ->

Expand Down
Loading

0 comments on commit 62e5039

Please sign in to comment.