@axe-core/cli 4.6.2-alpha.379 → 4.6.2-alpha.380

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (50) hide show
  1. package/dist/cli.js +464 -0
  2. package/dist/index.d.ts +71 -0
  3. package/dist/index.js +229 -0
  4. package/dist/index.mjs +197 -0
  5. package/esmTest.mjs +6 -0
  6. package/package.json +18 -8
  7. package/tsconfig.json +10 -3
  8. package/dist/package.json +0 -91
  9. package/dist/src/bin/cli.d.ts +0 -2
  10. package/dist/src/bin/cli.js +0 -39
  11. package/dist/src/bin/cli.js.map +0 -1
  12. package/dist/src/bin/cli.test.d.ts +0 -1
  13. package/dist/src/bin/cli.test.js +0 -241
  14. package/dist/src/bin/cli.test.js.map +0 -1
  15. package/dist/src/bin/index.d.ts +0 -5
  16. package/dist/src/bin/index.js +0 -120
  17. package/dist/src/bin/index.js.map +0 -1
  18. package/dist/src/lib/axe-test-urls.d.ts +0 -4
  19. package/dist/src/lib/axe-test-urls.js +0 -89
  20. package/dist/src/lib/axe-test-urls.js.map +0 -1
  21. package/dist/src/lib/axe-test-urls.test.d.ts +0 -1
  22. package/dist/src/lib/axe-test-urls.test.js +0 -73
  23. package/dist/src/lib/axe-test-urls.test.js.map +0 -1
  24. package/dist/src/lib/events.d.ts +0 -10
  25. package/dist/src/lib/events.js +0 -57
  26. package/dist/src/lib/events.js.map +0 -1
  27. package/dist/src/lib/events.test.d.ts +0 -1
  28. package/dist/src/lib/events.test.js +0 -31
  29. package/dist/src/lib/events.test.js.map +0 -1
  30. package/dist/src/lib/index.d.ts +0 -4
  31. package/dist/src/lib/index.js +0 -36
  32. package/dist/src/lib/index.js.map +0 -1
  33. package/dist/src/lib/utils.d.ts +0 -15
  34. package/dist/src/lib/utils.js +0 -120
  35. package/dist/src/lib/utils.js.map +0 -1
  36. package/dist/src/lib/utils.test.d.ts +0 -1
  37. package/dist/src/lib/utils.test.js +0 -140
  38. package/dist/src/lib/utils.test.js.map +0 -1
  39. package/dist/src/lib/webdriver.d.ts +0 -4
  40. package/dist/src/lib/webdriver.js +0 -46
  41. package/dist/src/lib/webdriver.js.map +0 -1
  42. package/dist/src/lib/webdriver.test.d.ts +0 -1
  43. package/dist/src/lib/webdriver.test.js +0 -102
  44. package/dist/src/lib/webdriver.test.js.map +0 -1
  45. package/dist/src/testutils/index.d.ts +0 -19
  46. package/dist/src/testutils/index.js +0 -51
  47. package/dist/src/testutils/index.js.map +0 -1
  48. package/dist/src/types.d.ts +0 -36
  49. package/dist/src/types.js +0 -18
  50. package/dist/src/types.js.map +0 -1
@@ -1,51 +0,0 @@
1
- "use strict";
2
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
- return new (P || (P = Promise))(function (resolve, reject) {
5
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
- step((generator = generator.apply(thisArg, _arguments || [])).next());
9
- });
10
- };
11
- var __importDefault = (this && this.__importDefault) || function (mod) {
12
- return (mod && mod.__esModule) ? mod : { "default": mod };
13
- };
14
- Object.defineProperty(exports, "__esModule", { value: true });
15
- exports.runCLIWithOptions = void 0;
16
- const execa_1 = __importDefault(require("execa"));
17
- const path_1 = __importDefault(require("path"));
18
- const fs_1 = __importDefault(require("fs"));
19
- const TS_NODE = require.resolve('ts-node/dist/bin.js');
20
- const CLI = path_1.default.resolve(__dirname, '..', 'bin', 'cli.ts');
21
- const PROJECT_FILE = path_1.default.join(__dirname, '..', 'tsconfig.json');
22
- /**
23
- * Run the CLI with the given `args`.
24
- *
25
- * Will not reject if the CLI exits with a non-zero exit code. It is expected that you check the `.exitCode` value yourself.
26
- *
27
- * @param args CLI arguments to pass
28
- */
29
- const runCLI = (...args) => (0, exports.runCLIWithOptions)(args, { reject: false });
30
- exports.default = runCLI;
31
- /**
32
- * Run the CLI with the given `args` and `options`.
33
- *
34
- * Set `DEBUG_CLI_TESTS` for additional debugging support (logging).
35
- *
36
- * @param args CLI arguments to pass
37
- * @param options Options for `execa`
38
- */
39
- const runCLIWithOptions = (args, options) => __awaiter(void 0, void 0, void 0, function* () {
40
- if ('DEBUG_CLI_TESTS' in process.env) {
41
- console.log('cli', args.join(' '));
42
- }
43
- const result = yield (0, execa_1.default)(TS_NODE, [CLI, ...args], options);
44
- if ('DEBUG_CLI_TESTS' in process.env) {
45
- fs_1.default.writeFileSync('./stdout.txt', result.stdout);
46
- fs_1.default.writeFileSync('./stderr.txt', result.stderr);
47
- }
48
- return result;
49
- });
50
- exports.runCLIWithOptions = runCLIWithOptions;
51
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/testutils/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,kDAA0B;AAC1B,gDAAwB;AACxB,4CAAoB;AAEpB,MAAM,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,qBAAqB,CAAC,CAAC;AACvD,MAAM,GAAG,GAAG,cAAI,CAAC,OAAO,CAAC,SAAS,EAAE,IAAI,EAAE,KAAK,EAAE,QAAQ,CAAC,CAAC;AAC3D,MAAM,YAAY,GAAG,cAAI,CAAC,IAAI,CAAC,SAAS,EAAE,IAAI,EAAE,eAAe,CAAC,CAAC;AAEjE;;;;;;GAMG;AAEH,MAAM,MAAM,GAAG,CAAC,GAAG,IAAc,EAA4C,EAAE,CAC7E,IAAA,yBAAiB,EAAC,IAAI,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC,CAAC;AAE7C,kBAAe,MAAM,CAAC;AAEtB;;;;;;;GAOG;AAEI,MAAM,iBAAiB,GAAG,CAC/B,IAAc,EACd,OAAsB,EACoB,EAAE;IAC5C,IAAI,iBAAiB,IAAI,OAAO,CAAC,GAAG,EAAE;QACpC,OAAO,CAAC,GAAG,CAAC,KAAK,EAAE,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC;KACpC;IAED,MAAM,MAAM,GAAG,MAAM,IAAA,eAAK,EAAC,OAAO,EAAE,CAAC,GAAG,EAAE,GAAG,IAAI,CAAC,EAAE,OAAO,CAAC,CAAC;IAE7D,IAAI,iBAAiB,IAAI,OAAO,CAAC,GAAG,EAAE;QACpC,YAAE,CAAC,aAAa,CAAC,cAAc,EAAE,MAAM,CAAC,MAAM,CAAC,CAAC;QAChD,YAAE,CAAC,aAAa,CAAC,cAAc,EAAE,MAAM,CAAC,MAAM,CAAC,CAAC;KACjD;IAED,OAAO,MAAM,CAAC;AAChB,CAAC,CAAA,CAAC;AAhBW,QAAA,iBAAiB,qBAgB5B"}
@@ -1,36 +0,0 @@
1
- import type { AxeResults } from 'axe-core';
2
- import type { WebDriver, Builder } from 'selenium-webdriver';
3
- export * from './lib';
4
- export interface EventParams {
5
- silentMode: boolean;
6
- timer: boolean;
7
- cliReporter: (...args: any[]) => void;
8
- verbose: boolean;
9
- exit: boolean;
10
- }
11
- export interface EventResponse {
12
- startTimer: (message: string) => void;
13
- endTimer: (message: string) => void;
14
- waitingMessage: (loadDelayTime: number) => void;
15
- onTestStart: (url: string) => void;
16
- onTestComplete: (results: AxeResults) => void;
17
- }
18
- export interface WebdriverConfigParams {
19
- browser: string;
20
- timeout: number;
21
- chromedriverPath?: string;
22
- path?: string;
23
- chromeOptions?: string[];
24
- builder?: Builder;
25
- }
26
- export interface ConfigParams {
27
- driver: WebDriver;
28
- timer?: boolean;
29
- loadDelay?: number;
30
- axeSource?: string;
31
- include?: string | string[];
32
- exclude?: string | string[];
33
- tags?: string | string[];
34
- rules?: string | string[];
35
- disable?: string | string[];
36
- }
package/dist/src/types.js DELETED
@@ -1,18 +0,0 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
- };
16
- Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./lib"), exports);
18
- //# sourceMappingURL=types.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/types.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAGA,wCAAsB"}