Skip to content

Commit

Permalink
fix cloud tests (#2613)
Browse files Browse the repository at this point in the history
* Supply correct config for Sauce Labs tests

* Inelegant (but working) Sauce Labs testing of browsers
  • Loading branch information
fatso83 authored Sep 11, 2024
1 parent 912c568 commit 17e5ec0
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 16 deletions.
15 changes: 0 additions & 15 deletions .min-wd

This file was deleted.

5 changes: 5 additions & 0 deletions mochify.webdriver.cjs
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
"use strict";
const assert = require("node:assert");

assert(process.env.BROWSER_NAME);
assert(process.env.SAUCE_USERNAME);
assert(process.env.SAUCE_ACCESS_KEY);

module.exports = {
driver: "webdriver",
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
"test-dev": "npm run test-node -- -n watch -n watch-path=test --node-option watch-path=lib -R min",
"test-headless": "mochify --driver puppeteer",
"test-coverage": "nyc nyc --exclude-after-remap false mochify --driver puppeteer --bundle 'node coverage.cjs'",
"test-cloud": "npm run test-headless -- --wd",
"test-cloud": "./scripts/test-cloud.sh",
"test-webworker": "mochify --driver puppeteer --serve . test/webworker/webworker-support-assessment.js",
"test-esm-support": "mocha test/es2015/module-support-assessment-test.mjs",
"test-esm-browser-build": "node test/es2015/check-esm-bundle-is-runnable.js",
Expand Down
5 changes: 5 additions & 0 deletions scripts/test-cloud.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/bin/sh

BROWSER_NAME=MicrosoftEdge mochify -C mochify.webdriver.cjs \
&& BROWSER_NAME=chrome mochify -C mochify.webdriver.cjs \
&& BROWSER_NAME=firefox mochify -C mochify.webdriver.cjs

0 comments on commit 17e5ec0

Please sign in to comment.