Skip to content

Commit

Permalink
Merge pull request #3373 from NCI-Agency/fix-wdio-package-json-script
Browse files Browse the repository at this point in the history
Fix unused env variable at wdio script in package.json
  • Loading branch information
gjvoosten authored Dec 22, 2020
2 parents 93beab3 + 712ab6d commit a459470
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 11 deletions.
1 change: 1 addition & 0 deletions anet-dictionary.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# Do not forget to also edit testDictionaries/*.yml files if dictionary change can break stuff
SUPPORT_EMAIL_ADDR: [email protected]

engagementsIncludeTimeAndDuration: true
Expand Down
2 changes: 1 addition & 1 deletion client/config/wdio.config.ie.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ const config = require("./wdio.config.js").config

// override default wdio config for IE tests
config.baseUrl = process.env.SERVER_URL
config.specs = ["./tests/webdriver/specs/ie/*.spec.js"]
config.specs = ["./tests/webdriver/ie/**/*.spec.js"]
config.exclude = []

const capabilities = config.capabilities[0]
Expand Down
15 changes: 7 additions & 8 deletions client/config/wdio.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,22 +10,21 @@ const config = {

//
// ==================
// Specify Test Files
// Specify Test Suites
// ==================
// Define which test specs should run. The pattern is relative to the directory
// from which `wdio` was called. Notice that, if you are calling `wdio` from an
// NPM script (see https://docs.npmjs.com/cli/run-script) then the current working
// directory is where your package.json resides, so `wdio` will be called from there.
//

suites: {
base: ["./tests/webdriver/baseSpecs/*.spec.js"],
withCustomFields: ["./tests/webdriver/customFieldsSpecs/*.spec.js"],
noCustomFields: ["./tests/webdriver/noCustomFieldsSpecs/*.spec.js"]
// tests that <don't> depend on custom fields from dictionary
base: ["./tests/webdriver/baseSpecs/**/*.spec.js"],
// tests that depend on custom fields from dictionary
withCustomFields: ["./tests/webdriver/customFieldsSpecs/**/*.spec.js"],
// Specifically for testing when there is no custom field in dictionary
noCustomFields: ["./tests/webdriver/noCustomFieldsSpecs/**/*.spec.js"]
},
// IE tests are excluded by default. They are exclusively included in IE dedicated config.
// Please see `wdio.config.ie.js` for details.
exclude: ["./tests/webdriver/specs/ie/*.spec.js"],
//
// ============
// Capabilities
Expand Down
2 changes: 1 addition & 1 deletion client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@
"test": "echo 'Run \"test-all\" to execute all client-side tests, or pick a specific test target: \"test-jest\", \"test-wdio\", \"test-wdio-ie\", \"test-e2e\".' ; exit 1",
"test-all": "yarn run test-jest && yarn run test-wdio && yarn run test-wdio-ie && yarn run test-e2e",
"test-e2e": "export SERVER_URL=${SERVER_URL:-'http://localhost:8180'} ; NODE_ENV=test node $(npm bin)/ava --config ava.config.js",
"test-wdio": "export SERVER_URL=${SERVER_URL:-'http://localhost:8180'} SUITE=${TEST_WDIO_SUITE:-withCustomFields}; NODE_ENV=test wdio --baseUrl ${SERVER_URL} ./config/wdio.config.js --suite base --suite ${TEST_WDIO_SUITE}",
"test-wdio": "export SERVER_URL=${SERVER_URL:-'http://localhost:8180'} SUITE=${TEST_WDIO_SUITE:-withCustomFields}; NODE_ENV=test wdio --baseUrl ${SERVER_URL} ./config/wdio.config.js --suite base --suite ${SUITE}",
"test-jest": "export ANET_DICTIONARY=../${ANET_DICTIONARY_NAME:-anet-dictionary.yml} ; NODE_ENV=test jest --testPathPattern='tests/(actions|reducers|models|utils)'",
"test-wdio-ie": "export SERVER_URL=${SERVER_URL:-'http://localhost:8180'} ; NODE_ENV=test node ./tests/util/wdio.ie.js",
"test-all-noCF": "yarn run test-wdio-noCF",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { expect } from "chai"
import Home from "../../pages/home.page"
import Home from "../pages/home.page"

describe("Anet home page on IE 11", () => {
it("should have the correct title", () => {
Expand Down

0 comments on commit a459470

Please sign in to comment.