gemini-express
Advanced tools
Comparing version 0.9.2 to 0.13.0
var Server = require('./server'); | ||
var Q = require('q'); | ||
var _ = require('lodash'); | ||
@@ -11,3 +12,7 @@ module.exports = function(gemini, opts) { | ||
server.start(opts, function(rootUrl) { | ||
gemini.config.rootUrl = rootUrl; | ||
_.forEach(gemini.config._browsers, function(browser) { | ||
browser.rootUrl = rootUrl; | ||
}); | ||
deferred.resolve(); | ||
@@ -14,0 +19,0 @@ }); |
{ | ||
"name": "gemini-express", | ||
"version": "0.9.2", | ||
"version": "0.13.0", | ||
"description": "Plugin for starting up Express when running tests with Gemini", | ||
@@ -12,2 +12,3 @@ "repository": "https://github.com/Saulis/gemini-express/", | ||
"gemini", | ||
"gemini-plugin", | ||
"express", | ||
@@ -23,2 +24,3 @@ "testing" | ||
"http-close": "0.0.2", | ||
"lodash": "^3.10.1", | ||
"q": "^1.2.0" | ||
@@ -25,0 +27,0 @@ }, |
@@ -6,4 +6,4 @@ # gemini-express | ||
## Notes | ||
Requires a version of gemini that supports plugin loading. See https://github.com/bem/gemini/pull/127 | ||
## Requirements | ||
Works with [gemini](https://github.com/gemini-testing/gemini) [v0.13.4](https://github.com/gemini-testing/gemini/releases/tag/v0.13.4) or later. | ||
@@ -19,8 +19,9 @@ ## Installation | ||
```yml | ||
system: | ||
plugins: | ||
express: | ||
root: /home/root | ||
port: 12345 | ||
``` | ||
plugins: | ||
express: | ||
root: /home/root | ||
port: 12345 | ||
``` | ||
@@ -27,0 +28,0 @@ |
@@ -77,3 +77,3 @@ var expect = require('chai').expect; | ||
it('should set rootUrl', function() { | ||
it('should inject rootUrl to browsers', function() { | ||
server.start = function(opts, cb) { | ||
@@ -83,6 +83,8 @@ cb('http://foo.bar'); | ||
gemini.config._browsers = {chrome: {}, firefox: {}}; | ||
init({}); | ||
startRunner(); | ||
expect(gemini.config.rootUrl).to.equal('http://foo.bar'); | ||
expect(gemini.config._browsers.chrome.rootUrl).to.equal('http://foo.bar'); | ||
expect(gemini.config._browsers.firefox.rootUrl).to.equal('http://foo.bar'); | ||
}); | ||
@@ -89,0 +91,0 @@ |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
104903
21
255
30
6
+ Addedlodash@^3.10.1
+ Addedlodash@3.10.1(transitive)