testcafe 2.6.2 → 3.4.0

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 (112) hide show
  1. package/lib/api/exportable-lib/index.js +5 -1
  2. package/lib/api/request-hooks/request-logger.js +6 -3
  3. package/lib/api/structure/fixture.js +6 -1
  4. package/lib/api/structure/interfaces.js +1 -1
  5. package/lib/api/structure/test-file.js +2 -2
  6. package/lib/api/structure/testing-unit.js +2 -1
  7. package/lib/api/test-controller/assertion.js +1 -1
  8. package/lib/api/test-controller/index.js +9 -19
  9. package/lib/api/test-page-url.js +2 -2
  10. package/lib/assertions/executor.js +1 -1
  11. package/lib/browser/connection/gateway/index.js +1 -4
  12. package/lib/browser/connection/index.js +6 -1
  13. package/lib/browser/provider/built-in/dedicated/firefox/marionette-client/index.js +4 -1
  14. package/lib/cli/argument-parser/index.js +3 -8
  15. package/lib/cli/remotes-wizard.js +3 -1
  16. package/lib/client/automation/index.js +153 -192
  17. package/lib/client/automation/index.min.js +1 -1
  18. package/lib/client/automation/playback/press/shortcut-type.js +24 -0
  19. package/lib/client/browser/idle-page/index.html.mustache +1 -1
  20. package/lib/client/browser/idle-page/index.js +5 -1
  21. package/lib/client/core/index.js +101 -330
  22. package/lib/client/core/index.min.js +1 -1
  23. package/lib/client/core/utils/array.js +3 -18
  24. package/lib/client/core/utils/dom.js +12 -32
  25. package/lib/client/driver/index.js +65 -77
  26. package/lib/client/driver/index.min.js +1 -1
  27. package/lib/client/driver/status.js +1 -2
  28. package/lib/client/test-run/index.js.mustache +1 -6
  29. package/lib/client/ui/index.js +77 -50
  30. package/lib/client/ui/index.min.js +1 -1
  31. package/lib/client/ui/styles.css +81 -3
  32. package/lib/client-functions/client-function-builder.js +7 -28
  33. package/lib/client-functions/selectors/add-api.js +3 -61
  34. package/lib/client-functions/selectors/selector-builder.js +3 -6
  35. package/lib/client-functions/selectors/selector-text-filter.js +1 -3
  36. package/lib/compiler/test-file/formats/dev-tools/compiler.js +8 -2
  37. package/lib/compiler/test-file/formats/typescript/compiler.js +2 -1
  38. package/lib/configuration/configuration-base.js +10 -8
  39. package/lib/configuration/default-values.js +3 -3
  40. package/lib/configuration/option-names.js +2 -3
  41. package/lib/configuration/run-option-names.js +2 -2
  42. package/lib/configuration/testcafe-configuration.js +4 -12
  43. package/lib/configuration/types.js +1 -1
  44. package/lib/custom-client-scripts/client-script.js +4 -1
  45. package/lib/custom-client-scripts/routing.js +3 -4
  46. package/lib/errors/get-callsite.js +3 -3
  47. package/lib/errors/runtime/index.js +64 -5
  48. package/lib/errors/runtime/templates.js +24 -15
  49. package/lib/errors/test-run/render-error-template/utils.js +2 -2
  50. package/lib/errors/test-run/templates.js +2 -2
  51. package/lib/errors/test-run/utils.js +2 -2
  52. package/lib/errors/types.js +5 -2
  53. package/lib/index.js +6 -4
  54. package/lib/native-automation/client/deps/hammerhead.js +25 -0
  55. package/lib/native-automation/client/event-descriptor.js +14 -1
  56. package/lib/native-automation/client/input.js +17 -5
  57. package/lib/native-automation/client/key-press/utils.js +13 -2
  58. package/lib/native-automation/cookie-provider.js +15 -4
  59. package/lib/native-automation/index.js +3 -2
  60. package/lib/native-automation/request-hooks/event-factory/request-paused-event-based.js +9 -5
  61. package/lib/native-automation/request-hooks/event-provider.js +14 -4
  62. package/lib/native-automation/request-pipeline/index.js +77 -48
  63. package/lib/native-automation/request-pipeline/safe-api.js +15 -10
  64. package/lib/native-automation/request-pipeline/test-run-bridge.js +13 -1
  65. package/lib/native-automation/resource-injector.js +3 -1
  66. package/lib/native-automation/types.js +1 -1
  67. package/lib/native-automation/utils/headers.js +2 -10
  68. package/lib/notifications/warning-message.js +3 -4
  69. package/lib/reporter/index.js +30 -21
  70. package/lib/reporter/module-prefix.js +6 -0
  71. package/lib/reporter/plugin-host.js +3 -12
  72. package/lib/role/index.js +1 -4
  73. package/lib/role/role.js +9 -1
  74. package/lib/runner/bootstrapper.js +45 -16
  75. package/lib/runner/browser-job.js +33 -5
  76. package/lib/runner/fixture-hook-controller.js +4 -3
  77. package/lib/runner/index.js +4 -19
  78. package/lib/runner/task/index.js +2 -4
  79. package/lib/runner/test-run-controller.js +24 -9
  80. package/lib/screenshots/capturer.js +8 -19
  81. package/lib/screenshots/index.js +4 -23
  82. package/lib/test-run/bookmark.js +1 -1
  83. package/lib/test-run/commands/observation.js +2 -10
  84. package/lib/test-run/commands/service.js +2 -9
  85. package/lib/test-run/commands/type.js +1 -2
  86. package/lib/test-run/index.js +10 -20
  87. package/lib/test-run/request/create-request-options.js +1 -1
  88. package/lib/test-run/request/interfaces.js +1 -1
  89. package/lib/test-run/request/send.js +2 -2
  90. package/lib/testcafe.js +3 -2
  91. package/lib/utils/debug-loggers.js +9 -2
  92. package/lib/utils/escape-unsafe-chars.js +13 -0
  93. package/lib/utils/get-browser.js +3 -2
  94. package/lib/utils/get-options/index.js +2 -4
  95. package/lib/utils/get-renderes.js +2 -2
  96. package/lib/utils/get-test-and-fixture-info.js +20 -0
  97. package/lib/utils/get-testcafe-version.js +3 -3
  98. package/lib/utils/lowercase-object-keys.js +12 -0
  99. package/lib/utils/match-collection.js +3 -3
  100. package/lib/utils/prerender-callsite.js +1 -1
  101. package/lib/utils/render-callsite-sync.js +2 -2
  102. package/lib/utils/reporter.js +8 -4
  103. package/lib/video-recorder/recorder.js +2 -2
  104. package/package.json +25 -27
  105. package/ts-defs/index.d.ts +49 -12
  106. package/ts-defs/selectors.d.ts +42 -8
  107. package/ts-defs/testcafe-scripts.d.ts +52 -8
  108. package/CHANGELOG.md +0 -4879
  109. package/lib/client/driver/command-executors/client-functions/selector-executor/check-element-delay.js +0 -5
  110. package/lib/client-functions/selector-api-execution-mode.js +0 -22
  111. package/lib/custom-client-scripts/get-url.js +0 -8
  112. package/lib/utils/is-repl.js +0 -12
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.default = {
4
+ ctrlA: 'ctrl+a',
5
+ backspace: 'backspace',
6
+ delete: 'delete',
7
+ left: 'left',
8
+ right: 'right',
9
+ up: 'up',
10
+ down: 'down',
11
+ shiftLeft: 'shift+left',
12
+ shiftRight: 'shift+right',
13
+ shiftUp: 'shift+up',
14
+ shiftDown: 'shift+down',
15
+ shiftHome: 'shift+home',
16
+ shiftEnd: 'shift+end',
17
+ home: 'home',
18
+ end: 'end',
19
+ enter: 'enter',
20
+ tab: 'tab',
21
+ shiftTab: 'shift+tab',
22
+ esc: 'esc',
23
+ };
24
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic2hvcnRjdXQtdHlwZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3NyYy9jbGllbnQvYXV0b21hdGlvbi9wbGF5YmFjay9wcmVzcy9zaG9ydGN1dC10eXBlLmpzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBQUEsa0JBQWU7SUFDWCxLQUFLLEVBQU8sUUFBUTtJQUNwQixTQUFTLEVBQUcsV0FBVztJQUN2QixNQUFNLEVBQU0sUUFBUTtJQUNwQixJQUFJLEVBQVEsTUFBTTtJQUNsQixLQUFLLEVBQU8sT0FBTztJQUNuQixFQUFFLEVBQVUsSUFBSTtJQUNoQixJQUFJLEVBQVEsTUFBTTtJQUNsQixTQUFTLEVBQUcsWUFBWTtJQUN4QixVQUFVLEVBQUUsYUFBYTtJQUN6QixPQUFPLEVBQUssVUFBVTtJQUN0QixTQUFTLEVBQUcsWUFBWTtJQUN4QixTQUFTLEVBQUcsWUFBWTtJQUN4QixRQUFRLEVBQUksV0FBVztJQUN2QixJQUFJLEVBQVEsTUFBTTtJQUNsQixHQUFHLEVBQVMsS0FBSztJQUNqQixLQUFLLEVBQU8sT0FBTztJQUNuQixHQUFHLEVBQVMsS0FBSztJQUNqQixRQUFRLEVBQUksV0FBVztJQUN2QixHQUFHLEVBQVMsS0FBSztDQUNwQixDQUFDIiwic291cmNlc0NvbnRlbnQiOlsiZXhwb3J0IGRlZmF1bHQge1xuICAgIGN0cmxBOiAgICAgICdjdHJsK2EnLFxuICAgIGJhY2tzcGFjZTogICdiYWNrc3BhY2UnLFxuICAgIGRlbGV0ZTogICAgICdkZWxldGUnLFxuICAgIGxlZnQ6ICAgICAgICdsZWZ0JyxcbiAgICByaWdodDogICAgICAncmlnaHQnLFxuICAgIHVwOiAgICAgICAgICd1cCcsXG4gICAgZG93bjogICAgICAgJ2Rvd24nLFxuICAgIHNoaWZ0TGVmdDogICdzaGlmdCtsZWZ0JyxcbiAgICBzaGlmdFJpZ2h0OiAnc2hpZnQrcmlnaHQnLFxuICAgIHNoaWZ0VXA6ICAgICdzaGlmdCt1cCcsXG4gICAgc2hpZnREb3duOiAgJ3NoaWZ0K2Rvd24nLFxuICAgIHNoaWZ0SG9tZTogICdzaGlmdCtob21lJyxcbiAgICBzaGlmdEVuZDogICAnc2hpZnQrZW5kJyxcbiAgICBob21lOiAgICAgICAnaG9tZScsXG4gICAgZW5kOiAgICAgICAgJ2VuZCcsXG4gICAgZW50ZXI6ICAgICAgJ2VudGVyJyxcbiAgICB0YWI6ICAgICAgICAndGFiJyxcbiAgICBzaGlmdFRhYjogICAnc2hpZnQrdGFiJyxcbiAgICBlc2M6ICAgICAgICAnZXNjJyxcbn07XG4iXX0=
@@ -2,7 +2,7 @@
2
2
  <html lang="en">
3
3
  <head>
4
4
  <meta charset="UTF-8">
5
- <meta http-equiv="X-UA-Compatible" content="IE=edge"/>
5
+ <meta http-equiv="X-UA-Compatible"/>
6
6
  <title></title>
7
7
  <script type="application/x-javascript" src="/browser/assets/index.js"></script>
8
8
  <link rel="stylesheet" href="/browser/assets/styles.css"/>
@@ -344,7 +344,11 @@
344
344
  throw op[1];
345
345
  return { value: op[0] ? op[1] : void 0, done: true };
346
346
  }
347
- }
347
+ }
348
+ var _SuppressedError = typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
349
+ var e = new Error(message);
350
+ return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
351
+ };
348
352
 
349
353
  // --------------------------------------------------------
350
354
  // WARNING: this file is used by both the client and the server.