codeceptjs 3.6.4 → 3.6.5-beta.1

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 (88) hide show
  1. package/bin/codecept.js +84 -63
  2. package/lib/assert/empty.js +19 -19
  3. package/lib/assert/equal.js +32 -30
  4. package/lib/assert/error.js +14 -14
  5. package/lib/assert/include.js +42 -42
  6. package/lib/assert/throws.js +13 -11
  7. package/lib/assert/truth.js +17 -18
  8. package/lib/command/configMigrate.js +57 -52
  9. package/lib/command/definitions.js +88 -88
  10. package/lib/command/dryRun.js +65 -63
  11. package/lib/command/generate.js +191 -181
  12. package/lib/command/info.js +39 -37
  13. package/lib/command/init.js +289 -286
  14. package/lib/command/interactive.js +32 -32
  15. package/lib/command/list.js +26 -26
  16. package/lib/command/run-multiple.js +113 -93
  17. package/lib/command/run-rerun.js +22 -22
  18. package/lib/command/run-workers.js +63 -63
  19. package/lib/command/run.js +24 -26
  20. package/lib/command/utils.js +64 -63
  21. package/lib/data/context.js +60 -60
  22. package/lib/data/dataScenarioConfig.js +47 -47
  23. package/lib/data/dataTableArgument.js +29 -29
  24. package/lib/data/table.js +26 -20
  25. package/lib/helper/AI.js +67 -65
  26. package/lib/helper/ApiDataFactory.js +72 -69
  27. package/lib/helper/Appium.js +409 -379
  28. package/lib/helper/ExpectHelper.js +214 -248
  29. package/lib/helper/FileSystem.js +77 -78
  30. package/lib/helper/GraphQL.js +44 -43
  31. package/lib/helper/GraphQLDataFactory.js +49 -50
  32. package/lib/helper/JSONResponse.js +64 -62
  33. package/lib/helper/Mochawesome.js +28 -28
  34. package/lib/helper/MockServer.js +12 -12
  35. package/lib/helper/Nightmare.js +664 -572
  36. package/lib/helper/Playwright.js +1320 -1211
  37. package/lib/helper/Protractor.js +663 -629
  38. package/lib/helper/Puppeteer.js +1232 -1124
  39. package/lib/helper/REST.js +87 -72
  40. package/lib/helper/TestCafe.js +490 -491
  41. package/lib/helper/WebDriver.js +1294 -1156
  42. package/lib/interfaces/bdd.js +38 -51
  43. package/lib/interfaces/featureConfig.js +19 -19
  44. package/lib/interfaces/gherkin.js +122 -111
  45. package/lib/interfaces/scenarioConfig.js +29 -29
  46. package/lib/listener/artifacts.js +9 -9
  47. package/lib/listener/config.js +24 -23
  48. package/lib/listener/exit.js +12 -12
  49. package/lib/listener/helpers.js +42 -42
  50. package/lib/listener/mocha.js +11 -11
  51. package/lib/listener/retry.js +32 -30
  52. package/lib/listener/steps.js +50 -51
  53. package/lib/listener/timeout.js +53 -53
  54. package/lib/plugin/allure.js +14 -14
  55. package/lib/plugin/autoDelay.js +29 -36
  56. package/lib/plugin/autoLogin.js +70 -66
  57. package/lib/plugin/commentStep.js +18 -18
  58. package/lib/plugin/coverage.js +92 -77
  59. package/lib/plugin/customLocator.js +20 -19
  60. package/lib/plugin/debugErrors.js +24 -24
  61. package/lib/plugin/eachElement.js +37 -37
  62. package/lib/plugin/fakerTransform.js +6 -6
  63. package/lib/plugin/heal.js +66 -63
  64. package/lib/plugin/pauseOnFail.js +10 -10
  65. package/lib/plugin/retryFailedStep.js +31 -38
  66. package/lib/plugin/retryTo.js +28 -28
  67. package/lib/plugin/screenshotOnFail.js +107 -86
  68. package/lib/plugin/selenoid.js +131 -117
  69. package/lib/plugin/standardActingHelpers.js +2 -8
  70. package/lib/plugin/stepByStepReport.js +102 -92
  71. package/lib/plugin/stepTimeout.js +23 -22
  72. package/lib/plugin/subtitles.js +34 -34
  73. package/lib/plugin/tryTo.js +39 -29
  74. package/lib/plugin/wdio.js +77 -72
  75. package/lib/template/heal.js +11 -14
  76. package/package.json +4 -2
  77. package/translations/de-DE.js +1 -1
  78. package/translations/fr-FR.js +1 -1
  79. package/translations/index.js +9 -9
  80. package/translations/it-IT.js +1 -1
  81. package/translations/ja-JP.js +1 -1
  82. package/translations/pl-PL.js +1 -1
  83. package/translations/pt-BR.js +1 -1
  84. package/translations/ru-RU.js +1 -1
  85. package/translations/zh-CN.js +1 -1
  86. package/translations/zh-TW.js +1 -1
  87. package/typings/promiseBasedTypes.d.ts +238 -0
  88. package/typings/types.d.ts +32 -0
@@ -1180,6 +1180,9 @@ declare namespace CodeceptJS {
1180
1180
  *
1181
1181
  * ## Methods
1182
1182
  */
1183
+ // @ts-ignore
1184
+ // @ts-ignore
1185
+ // @ts-ignore
1183
1186
  class ExpectHelper {
1184
1187
  expectEqual(actualValue: any, expectedValue: any, customErrorMsg?: any): Promise<any>;
1185
1188
  expectNotEqual(actualValue: any, expectedValue: any, customErrorMsg?: any): Promise<any>;
@@ -1291,6 +1294,9 @@ declare namespace CodeceptJS {
1291
1294
  *
1292
1295
  * ## Methods
1293
1296
  */
1297
+ // @ts-ignore
1298
+ // @ts-ignore
1299
+ // @ts-ignore
1294
1300
  class ExpectHelper {
1295
1301
  expectEqual(actualValue: any, expectedValue: any, customErrorMsg?: any): Promise<any>;
1296
1302
  expectNotEqual(actualValue: any, expectedValue: any, customErrorMsg?: any): Promise<any>;
@@ -1962,6 +1968,9 @@ declare namespace CodeceptJS {
1962
1968
  * @property [host = "0.0.0.0"] - Mock server host
1963
1969
  * @property [httpsOpts] - key & cert values are the paths to .key and .crt files
1964
1970
  */
1971
+ // @ts-ignore
1972
+ // @ts-ignore
1973
+ // @ts-ignore
1965
1974
  type MockServerConfig = {
1966
1975
  port?: number;
1967
1976
  host?: string;
@@ -2086,6 +2095,9 @@ declare namespace CodeceptJS {
2086
2095
  *
2087
2096
  * ## Methods
2088
2097
  */
2098
+ // @ts-ignore
2099
+ // @ts-ignore
2100
+ // @ts-ignore
2089
2101
  class MockServer {
2090
2102
  /**
2091
2103
  * Start the mock server
@@ -3115,6 +3127,91 @@ declare namespace CodeceptJS {
3115
3127
  */
3116
3128
  askGptGeneralPrompt(prompt: string): Promise<string>;
3117
3129
  }
3130
+ /**
3131
+ * ## Configuration
3132
+ *
3133
+ * This helper should be configured in codecept.conf.(js|ts)
3134
+ * @property [url] - base url of website to be tested
3135
+ * @property [browser = 'chromium'] - a browser to test on, either: `chromium`, `firefox`, `webkit`, `electron`. Default: chromium.
3136
+ * @property [show = true] - show browser window.
3137
+ * @property [restart = false] - restart strategy between tests. Possible values:
3138
+ * * 'context' or **false** - restarts [browser context](https://playwright.dev/docs/api/class-browsercontext) but keeps running browser. Recommended by Playwright team to keep tests isolated.
3139
+ * * 'browser' or **true** - closes browser and opens it again between tests.
3140
+ * * 'session' or 'keep' - keeps browser context and session, but cleans up cookies and localStorage between tests. The fastest option when running tests in windowed mode. Works with `keepCookies` and `keepBrowserState` options. This behavior was default before CodeceptJS 3.1
3141
+ * @property [timeout = 1000] - - [timeout](https://playwright.dev/docs/api/class-page#page-set-default-timeout) in ms of all Playwright actions .
3142
+ * @property [disableScreenshots = false] - don't save screenshot on failure.
3143
+ * @property [emulate] - browser in device emulation mode.
3144
+ * @property [video = false] - enables video recording for failed tests; videos are saved into `output/videos` folder
3145
+ * @property [keepVideoForPassedTests = false] - save videos for passed tests; videos are saved into `output/videos` folder
3146
+ * @property [trace = false] - record [tracing information](https://playwright.dev/docs/trace-viewer) with screenshots and snapshots.
3147
+ * @property [keepTraceForPassedTests = false] - save trace for passed tests.
3148
+ * @property [fullPageScreenshots = false] - make full page screenshots on failure.
3149
+ * @property [uniqueScreenshotNames = false] - option to prevent screenshot override if you have scenarios with the same name in different suites.
3150
+ * @property [keepBrowserState = false] - keep browser state between tests when `restart` is set to 'session'.
3151
+ * @property [keepCookies = false] - keep cookies between tests when `restart` is set to 'session'.
3152
+ * @property [waitForAction] - how long to wait after click, doubleClick or PressKey actions in ms. Default: 100.
3153
+ * @property [waitForNavigation] - When to consider navigation succeeded. Possible options: `load`, `domcontentloaded`, `commit`. Choose one of those options is possible. See [Playwright API](https://playwright.dev/docs/api/class-page#page-wait-for-url).
3154
+ * @property [pressKeyDelay = 10] - Delay between key presses in ms. Used when calling Playwrights page.type(...) in fillField/appendField
3155
+ * @property [getPageTimeout] - config option to set maximum navigation time in milliseconds.
3156
+ * @property [waitForTimeout] - default wait* timeout in ms. Default: 1000.
3157
+ * @property [basicAuth] - the basic authentication to pass to base url. Example: {username: 'username', password: 'password'}
3158
+ * @property [windowSize] - default window size. Set a dimension like `640x480`.
3159
+ * @property [colorScheme] - default color scheme. Possible values: `dark` | `light` | `no-preference`.
3160
+ * @property [userAgent] - user-agent string.
3161
+ * @property [locale] - locale string. Example: 'en-GB', 'de-DE', 'fr-FR', ...
3162
+ * @property [manualStart] - do not start browser before a test, start it manually inside a helper with `this.helpers["Playwright"]._startBrowser()`.
3163
+ * @property [chromium] - pass additional chromium options
3164
+ * @property [firefox] - pass additional firefox options
3165
+ * @property [electron] - (pass additional electron options
3166
+ * @property [channel] - (While Playwright can operate against the stock Google Chrome and Microsoft Edge browsers available on the machine. In particular, current Playwright version will support Stable and Beta channels of these browsers. See [Google Chrome & Microsoft Edge](https://playwright.dev/docs/browsers/#google-chrome--microsoft-edge).
3167
+ * @property [ignoreLog] - An array with console message types that are not logged to debug log. Default value is `['warning', 'log']`. E.g. you can set `[]` to log all messages. See all possible [values](https://playwright.dev/docs/api/class-consolemessage#console-message-type).
3168
+ * @property [ignoreHTTPSErrors] - Allows access to untrustworthy pages, e.g. to a page with an expired certificate. Default value is `false`
3169
+ * @property [bypassCSP] - bypass Content Security Policy or CSP
3170
+ * @property [highlightElement] - highlight the interacting elements. Default: false. Note: only activate under verbose mode (--verbose).
3171
+ * @property [recordHar] - record HAR and will be saved to `output/har`. See more of [HAR options](https://playwright.dev/docs/api/class-browser#browser-new-context-option-record-har).
3172
+ * @property [testIdAttribute = data-testid] - locate elements based on the testIdAttribute. See more of [locate by test id](https://playwright.dev/docs/locators#locate-by-test-id).
3173
+ */
3174
+ // @ts-ignore
3175
+ // @ts-ignore
3176
+ // @ts-ignore
3177
+ type PlaywrightConfig = {
3178
+ url?: string;
3179
+ browser?: 'chromium' | 'firefox' | 'webkit' | 'electron';
3180
+ show?: boolean;
3181
+ restart?: string | boolean;
3182
+ timeout?: number;
3183
+ disableScreenshots?: boolean;
3184
+ emulate?: any;
3185
+ video?: boolean;
3186
+ keepVideoForPassedTests?: boolean;
3187
+ trace?: boolean;
3188
+ keepTraceForPassedTests?: boolean;
3189
+ fullPageScreenshots?: boolean;
3190
+ uniqueScreenshotNames?: boolean;
3191
+ keepBrowserState?: boolean;
3192
+ keepCookies?: boolean;
3193
+ waitForAction?: number;
3194
+ waitForNavigation?: 'load' | 'domcontentloaded' | 'commit';
3195
+ pressKeyDelay?: number;
3196
+ getPageTimeout?: number;
3197
+ waitForTimeout?: number;
3198
+ basicAuth?: any;
3199
+ windowSize?: string;
3200
+ colorScheme?: 'dark' | 'light' | 'no-preference';
3201
+ userAgent?: string;
3202
+ locale?: string;
3203
+ manualStart?: boolean;
3204
+ chromium?: any;
3205
+ firefox?: any;
3206
+ electron?: any;
3207
+ channel?: any;
3208
+ ignoreLog?: string[];
3209
+ ignoreHTTPSErrors?: boolean;
3210
+ bypassCSP?: boolean;
3211
+ highlightElement?: boolean;
3212
+ recordHar?: any;
3213
+ testIdAttribute?: string;
3214
+ };
3118
3215
  /**
3119
3216
  * Uses [Playwright](https://github.com/microsoft/playwright) library to run tests inside:
3120
3217
  *
@@ -4670,6 +4767,13 @@ declare namespace CodeceptJS {
4670
4767
  * @param [sec = 1] - (optional) time in seconds to wait, 1 by default.
4671
4768
  */
4672
4769
  waitForEnabled(locator: CodeceptJS.LocatorOrString, sec?: number): Promise<any>;
4770
+ /**
4771
+ * Waits for element to become disabled (by default waits for 1sec).
4772
+ * Element can be located by CSS or XPath.
4773
+ * @param locator - element located by CSS|XPath|strict locator.
4774
+ * @param [sec = 1] - (optional) time in seconds to wait, 1 by default.
4775
+ */
4776
+ waitForDisabled(locator: CodeceptJS.LocatorOrString, sec?: number): Promise<any>;
4673
4777
  /**
4674
4778
  * Waits for the specified value to be in value attribute.
4675
4779
  *
@@ -6419,6 +6523,60 @@ declare namespace CodeceptJS {
6419
6523
  */
6420
6524
  setCookie(cookie: Cookie | Cookie[]): Promise<any>;
6421
6525
  }
6526
+ /**
6527
+ * ## Configuration
6528
+ *
6529
+ * This helper should be configured in codecept.conf.js
6530
+ * @property url - base url of website to be tested
6531
+ * @property [basicAuth] - (optional) the basic authentication to pass to base url. Example: {username: 'username', password: 'password'}
6532
+ * @property [show] - show Google Chrome window for debug.
6533
+ * @property [restart = true] - restart browser between tests.
6534
+ * @property [disableScreenshots = false] - don't save screenshot on failure.
6535
+ * @property [fullPageScreenshots = false] - make full page screenshots on failure.
6536
+ * @property [uniqueScreenshotNames = false] - option to prevent screenshot override if you have scenarios with the same name in different suites.
6537
+ * @property [trace = false] - record [tracing information](https://pptr.dev/api/puppeteer.tracing) with screenshots.
6538
+ * @property [keepTraceForPassedTests = false] - save trace for passed tests.
6539
+ * @property [keepBrowserState = false] - keep browser state between tests when `restart` is set to false.
6540
+ * @property [keepCookies = false] - keep cookies between tests when `restart` is set to false.
6541
+ * @property [waitForAction = 100] - how long to wait after click, doubleClick or PressKey actions in ms. Default: 100.
6542
+ * @property [waitForNavigation = load] - when to consider navigation succeeded. Possible options: `load`, `domcontentloaded`, `networkidle0`, `networkidle2`. See [Puppeteer API](https://github.com/GoogleChrome/puppeteer/blob/master/docs/api.md#pagewaitfornavigationoptions). Array values are accepted as well.
6543
+ * @property [pressKeyDelay = 10] - delay between key presses in ms. Used when calling Puppeteers page.type(...) in fillField/appendField
6544
+ * @property [getPageTimeout = 30000] - config option to set maximum navigation time in milliseconds. If the timeout is set to 0, then timeout will be disabled.
6545
+ * @property [waitForTimeout = 1000] - default wait* timeout in ms.
6546
+ * @property [windowSize] - default window size. Set a dimension in format WIDTHxHEIGHT like `640x480`.
6547
+ * @property [userAgent] - user-agent string.
6548
+ * @property [manualStart = false] - do not start browser before a test, start it manually inside a helper with `this.helpers["Puppeteer"]._startBrowser()`.
6549
+ * @property [browser = chrome] - can be changed to `firefox` when using [puppeteer-firefox](https://codecept.io/helpers/Puppeteer-firefox).
6550
+ * @property [chrome] - pass additional [Puppeteer run options](https://github.com/GoogleChrome/puppeteer/blob/master/docs/api.md#puppeteerlaunchoptions).
6551
+ * @property [highlightElement] - highlight the interacting elements. Default: false. Note: only activate under verbose mode (--verbose).
6552
+ */
6553
+ // @ts-ignore
6554
+ // @ts-ignore
6555
+ // @ts-ignore
6556
+ type PuppeteerConfig = {
6557
+ url: string;
6558
+ basicAuth?: any;
6559
+ show?: boolean;
6560
+ restart?: boolean;
6561
+ disableScreenshots?: boolean;
6562
+ fullPageScreenshots?: boolean;
6563
+ uniqueScreenshotNames?: boolean;
6564
+ trace?: boolean;
6565
+ keepTraceForPassedTests?: boolean;
6566
+ keepBrowserState?: boolean;
6567
+ keepCookies?: boolean;
6568
+ waitForAction?: number;
6569
+ waitForNavigation?: string;
6570
+ pressKeyDelay?: number;
6571
+ getPageTimeout?: number;
6572
+ waitForTimeout?: number;
6573
+ windowSize?: string;
6574
+ userAgent?: string;
6575
+ manualStart?: boolean;
6576
+ browser?: string;
6577
+ chrome?: any;
6578
+ highlightElement?: boolean;
6579
+ };
6422
6580
  /**
6423
6581
  * Uses [Google Chrome's Puppeteer](https://github.com/GoogleChrome/puppeteer) library to run tests inside headless Chrome.
6424
6582
  * Browser control is executed via DevTools Protocol (instead of Selenium).
@@ -8189,6 +8347,32 @@ declare namespace CodeceptJS {
8189
8347
  */
8190
8348
  flushWebSocketMessages(): Promise<any>;
8191
8349
  }
8350
+ /**
8351
+ * ## Configuration
8352
+ * @property [endpoint] - API base URL
8353
+ * @property [prettyPrintJson = false] - pretty print json for response/request on console logs.
8354
+ * @property [printCurl = false] - print cURL request on console logs. False by default.
8355
+ * @property [timeout = 1000] - timeout for requests in milliseconds. 10000ms by default.
8356
+ * @property [defaultHeaders] - a list of default headers.
8357
+ * @property [httpAgent] - create an agent with SSL certificate
8358
+ * @property [onRequest] - an async function which can update request object.
8359
+ * @property [onResponse] - an async function which can update response object.
8360
+ * @property [maxUploadFileSize] - set the max content file size in MB when performing api calls.
8361
+ */
8362
+ // @ts-ignore
8363
+ // @ts-ignore
8364
+ // @ts-ignore
8365
+ type RESTConfig = {
8366
+ endpoint?: string;
8367
+ prettyPrintJson?: boolean;
8368
+ printCurl?: boolean;
8369
+ timeout?: number;
8370
+ defaultHeaders?: any;
8371
+ httpAgent?: any;
8372
+ onRequest?: (...params: any[]) => any;
8373
+ onResponse?: (...params: any[]) => any;
8374
+ maxUploadFileSize?: number;
8375
+ };
8192
8376
  /**
8193
8377
  * REST helper allows to send additional requests to the REST API during acceptance tests.
8194
8378
  * [Axios](https://github.com/axios/axios) library is used to perform requests.
@@ -9269,6 +9453,60 @@ declare namespace CodeceptJS {
9269
9453
  */
9270
9454
  waitForText(text: string, sec?: number, context?: CodeceptJS.LocatorOrString): Promise<any>;
9271
9455
  }
9456
+ /**
9457
+ * ## Configuration
9458
+ *
9459
+ * This helper should be configured in codecept.conf.js
9460
+ * @property url - base url of website to be tested.
9461
+ * @property browser - Browser in which to perform testing.
9462
+ * @property [basicAuth] - (optional) the basic authentication to pass to base url. Example: {username: 'username', password: 'password'}
9463
+ * @property [host = localhost] - WebDriver host to connect.
9464
+ * @property [port = 4444] - WebDriver port to connect.
9465
+ * @property [protocol = http] - protocol for WebDriver server.
9466
+ * @property [path = /wd/hub] - path to WebDriver server.
9467
+ * @property [restart = true] - restart browser between tests.
9468
+ * @property [smartWait = false] - **enables [SmartWait](http://codecept.io/acceptance/#smartwait)**; wait for additional milliseconds for element to appear. Enable for 5 secs: "smartWait": 5000.
9469
+ * @property [disableScreenshots = false] - don't save screenshots on failure.
9470
+ * @property [fullPageScreenshots = false] - (optional - make full page screenshots on failure.
9471
+ * @property [uniqueScreenshotNames = false] - option to prevent screenshot override if you have scenarios with the same name in different suites.
9472
+ * @property [keepBrowserState = false] - keep browser state between tests when `restart` is set to false.
9473
+ * @property [keepCookies = false] - keep cookies between tests when `restart` set to false.
9474
+ * @property [windowSize = window] - default window size. Set to `maximize` or a dimension in the format `640x480`.
9475
+ * @property [waitForTimeout = 1000] - sets default wait time in *ms* for all `wait*` functions.
9476
+ * @property [desiredCapabilities] - Selenium's [desired capabilities](https://github.com/SeleniumHQ/selenium/wiki/DesiredCapabilities).
9477
+ * @property [manualStart = false] - do not start browser before a test, start it manually inside a helper with `this.helpers["WebDriver"]._startBrowser()`.
9478
+ * @property [timeouts] - [WebDriver timeouts](http://webdriver.io/docs/timeouts.html) defined as hash.
9479
+ * @property [highlightElement] - highlight the interacting elements. Default: false. Note: only activate under verbose mode (--verbose).
9480
+ * @property [logLevel = silent] - level of logging verbosity. Default: silent. Options: trace | debug | info | warn | error | silent. More info: https://webdriver.io/docs/configuration/#loglevel
9481
+ * @property [devtoolsProtocol = false] - enable devtools protocol. Default: false. More info: https://webdriver.io/docs/automationProtocols/#devtools-protocol.
9482
+ */
9483
+ // @ts-ignore
9484
+ // @ts-ignore
9485
+ // @ts-ignore
9486
+ type WebDriverConfig = {
9487
+ url: string;
9488
+ browser: string;
9489
+ basicAuth?: string;
9490
+ host?: string;
9491
+ port?: number;
9492
+ protocol?: string;
9493
+ path?: string;
9494
+ restart?: boolean;
9495
+ smartWait?: boolean | number;
9496
+ disableScreenshots?: boolean;
9497
+ fullPageScreenshots?: boolean;
9498
+ uniqueScreenshotNames?: boolean;
9499
+ keepBrowserState?: boolean;
9500
+ keepCookies?: boolean;
9501
+ windowSize?: string;
9502
+ waitForTimeout?: number;
9503
+ desiredCapabilities?: any;
9504
+ manualStart?: boolean;
9505
+ timeouts?: any;
9506
+ highlightElement?: boolean;
9507
+ logLevel?: string;
9508
+ devtoolsProtocol?: boolean;
9509
+ };
9272
9510
  /**
9273
9511
  * WebDriver helper which wraps [webdriverio](http://webdriver.io/) library to
9274
9512
  * manipulate browser using Selenium WebDriver or PhantomJS.
@@ -1204,6 +1204,9 @@ declare namespace CodeceptJS {
1204
1204
  *
1205
1205
  * ## Methods
1206
1206
  */
1207
+ // @ts-ignore
1208
+ // @ts-ignore
1209
+ // @ts-ignore
1207
1210
  class ExpectHelper {
1208
1211
  expectEqual(actualValue: any, expectedValue: any, customErrorMsg?: any): void;
1209
1212
  expectNotEqual(actualValue: any, expectedValue: any, customErrorMsg?: any): void;
@@ -1315,6 +1318,9 @@ declare namespace CodeceptJS {
1315
1318
  *
1316
1319
  * ## Methods
1317
1320
  */
1321
+ // @ts-ignore
1322
+ // @ts-ignore
1323
+ // @ts-ignore
1318
1324
  class ExpectHelper {
1319
1325
  expectEqual(actualValue: any, expectedValue: any, customErrorMsg?: any): void;
1320
1326
  expectNotEqual(actualValue: any, expectedValue: any, customErrorMsg?: any): void;
@@ -1989,6 +1995,9 @@ declare namespace CodeceptJS {
1989
1995
  * @property [host = "0.0.0.0"] - Mock server host
1990
1996
  * @property [httpsOpts] - key & cert values are the paths to .key and .crt files
1991
1997
  */
1998
+ // @ts-ignore
1999
+ // @ts-ignore
2000
+ // @ts-ignore
1992
2001
  type MockServerConfig = {
1993
2002
  port?: number;
1994
2003
  host?: string;
@@ -2113,6 +2122,9 @@ declare namespace CodeceptJS {
2113
2122
  *
2114
2123
  * ## Methods
2115
2124
  */
2125
+ // @ts-ignore
2126
+ // @ts-ignore
2127
+ // @ts-ignore
2116
2128
  class MockServer {
2117
2129
  /**
2118
2130
  * Start the mock server
@@ -3252,6 +3264,9 @@ declare namespace CodeceptJS {
3252
3264
  * @property [recordHar] - record HAR and will be saved to `output/har`. See more of [HAR options](https://playwright.dev/docs/api/class-browser#browser-new-context-option-record-har).
3253
3265
  * @property [testIdAttribute = data-testid] - locate elements based on the testIdAttribute. See more of [locate by test id](https://playwright.dev/docs/locators#locate-by-test-id).
3254
3266
  */
3267
+ // @ts-ignore
3268
+ // @ts-ignore
3269
+ // @ts-ignore
3255
3270
  type PlaywrightConfig = {
3256
3271
  url?: string;
3257
3272
  browser?: 'chromium' | 'firefox' | 'webkit' | 'electron';
@@ -4904,6 +4919,14 @@ declare namespace CodeceptJS {
4904
4919
  * @returns automatically synchronized promise through #recorder
4905
4920
  */
4906
4921
  waitForEnabled(locator: CodeceptJS.LocatorOrString, sec?: number): void;
4922
+ /**
4923
+ * Waits for element to become disabled (by default waits for 1sec).
4924
+ * Element can be located by CSS or XPath.
4925
+ * @param locator - element located by CSS|XPath|strict locator.
4926
+ * @param [sec = 1] - (optional) time in seconds to wait, 1 by default.
4927
+ * @returns automatically synchronized promise through #recorder
4928
+ */
4929
+ waitForDisabled(locator: CodeceptJS.LocatorOrString, sec?: number): void;
4907
4930
  /**
4908
4931
  * Waits for the specified value to be in value attribute.
4909
4932
  *
@@ -6771,6 +6794,9 @@ declare namespace CodeceptJS {
6771
6794
  * @property [chrome] - pass additional [Puppeteer run options](https://github.com/GoogleChrome/puppeteer/blob/master/docs/api.md#puppeteerlaunchoptions).
6772
6795
  * @property [highlightElement] - highlight the interacting elements. Default: false. Note: only activate under verbose mode (--verbose).
6773
6796
  */
6797
+ // @ts-ignore
6798
+ // @ts-ignore
6799
+ // @ts-ignore
6774
6800
  type PuppeteerConfig = {
6775
6801
  url: string;
6776
6802
  basicAuth?: any;
@@ -8713,6 +8739,9 @@ declare namespace CodeceptJS {
8713
8739
  * @property [onResponse] - an async function which can update response object.
8714
8740
  * @property [maxUploadFileSize] - set the max content file size in MB when performing api calls.
8715
8741
  */
8742
+ // @ts-ignore
8743
+ // @ts-ignore
8744
+ // @ts-ignore
8716
8745
  type RESTConfig = {
8717
8746
  endpoint?: string;
8718
8747
  prettyPrintJson?: boolean;
@@ -9891,6 +9920,9 @@ declare namespace CodeceptJS {
9891
9920
  * @property [logLevel = silent] - level of logging verbosity. Default: silent. Options: trace | debug | info | warn | error | silent. More info: https://webdriver.io/docs/configuration/#loglevel
9892
9921
  * @property [devtoolsProtocol = false] - enable devtools protocol. Default: false. More info: https://webdriver.io/docs/automationProtocols/#devtools-protocol.
9893
9922
  */
9923
+ // @ts-ignore
9924
+ // @ts-ignore
9925
+ // @ts-ignore
9894
9926
  type WebDriverConfig = {
9895
9927
  url: string;
9896
9928
  browser: string;