Permalink
Browse files

docs(examples): rewrite examples with supportCode

  • Loading branch information...
Adezandee committed Dec 6, 2017
1 parent 59f768d commit ec26c7b1280a725683ae02a371fecd7e6d9e8068
Showing with 32 additions and 22 deletions.
  1. +1 −1 examples/README.md
  2. +6 −4 examples/browserstack.js
  3. +6 −4 examples/local-chrome.js
  4. +7 −5 examples/local-firefox.js
  5. +6 −4 examples/phantomjs.js
  6. +6 −4 examples/saucelabs.js
View
@@ -28,7 +28,7 @@ phantomjs -w --ignore-ssl-errors=yes
You can pass in custom HTTP Header through phantomjs if needed. Here is an example for a Basic Authentication header:
``` javascript
var parameters = {
const parameters = {
driver: {
desiredCapabilities: {
'browserName': 'phantomjs',
View
@@ -1,4 +1,5 @@
import Mink from '../src/mink.js';
const { defineSupportCode } = require('cucumber');
const Mink = require('cucumber-mink');
// BrowserStack
const parameters = {
@@ -20,6 +21,7 @@ const parameters = {
},
};
export default function () {
Mink.init(this, parameters);
}
defineSupportCode((cucumber) => {
Mink.configure(parameters);
Mink.init(cucumber);
});
View
@@ -1,4 +1,5 @@
import Mink from '../src/mink.js';
const { defineSupportCode } = require('cucumber');
const Mink = require('cucumber-mink');
// Local Chrome
const parameters = {
@@ -11,6 +12,7 @@ const parameters = {
},
};
export default function () {
Mink.init(this, parameters);
}
defineSupportCode((cucumber) => {
Mink.configure(parameters);
Mink.init(cucumber);
});
View
@@ -1,6 +1,7 @@
import Mink from '../src/mink.js';
const { defineSupportCode } = require('cucumber');
const Mink = require('cucumber-mink');
// Local Chrome
// Local Firefox
const parameters = {
driver: {
logLevel: 'silent',
@@ -11,6 +12,7 @@ const parameters = {
},
};
export default function () {
Mink.init(this, parameters);
}
defineSupportCode((cucumber) => {
Mink.configure(parameters);
Mink.init(cucumber);
});
View
@@ -1,4 +1,5 @@
import Mink from '../src/mink.js';
const { defineSupportCode } = require('cucumber');
const Mink = require('cucumber-mink');
// Phantomjs - GhostDriver
const parameters = {
@@ -12,6 +13,7 @@ const parameters = {
},
};
export default function () {
Mink.init(this, parameters);
}
defineSupportCode((cucumber) => {
Mink.configure(parameters);
Mink.init(cucumber);
});
View
@@ -1,4 +1,5 @@
import Mink from '../src/mink.js';
const { defineSupportCode } = require('cucumber');
const Mink = require('cucumber-mink');
// SauceLabs
const parameters = {
@@ -18,6 +19,7 @@ const parameters = {
},
};
export default function () {
Mink.init(this, parameters);
}
defineSupportCode((cucumber) => {
Mink.configure(parameters);
Mink.init(cucumber);
});

0 comments on commit ec26c7b

Please sign in to comment.