CodeceptJS v2.6.0 Release Notes
Release Date: 2020-03-31 // about 4 years ago-
- ⚡️ [Playwright] Updated to Playwright 0.12 by @Georgegriff.
⬆️ Upgrade playwright to 0.12:
npm i playwright@^0.12 --save
- Fixed opening two browsers on start
executeScript
- passed function now accepts only one argument. Pass in objects or arrays if you need multtple arguments:js // Old style, does not work anymore: I.executeScript((x, y) => x + y, x, y); // New style, passing an object: I.executeScript(({x, y}) => x + y, {x, y});
click
- automatically waits for element to become clickable (visible, not animated) and waits for navigation.clickLink
- deprecatedwaitForClickable
- deprecatedforceClick
- added- Added support for custom locators. See #2277
- Introduced device emulation:
- globally via
emulate
config option - per session
- globally via
⚡️ [WebDriver] Updated to webdriverio v6 by @PeterNgTr.
🚀 Read release notes, then ⬆️ upgrade webdriverio to 6.0:
npm i webdriverio@^6.0 --save
🚚 (webdriverio v5 support is deprecated and will be removed in CodeceptJS 3.0)
👍 [WebDriver] Introduced Shadow DOM support by @gkushang
I.click({ shadow: ['my-app', 'recipe-hello', 'button'] });
- 🛠 Fixed parallel execution of
run-workers
for Gherkin scenarios by @koushikmohan1996 - 📦 [MockRequest] Updated and moved to standalone package:
- full support for record/replay mode for Puppeteer
- added
mockServer
method to use flexible PollyJS API to define mocks - fixed stale browser screen in record mode.
- 🔌 [Playwright] Added support on for
screenshotOnFail
plugin by @amonkc - 👀 Gherkin improvement: setting different tags per examples. See #2208 by @acuper
- ⚡️ [TestCafe] Updated
click
to take first visible element. Fixes #2226 by @theTainted - ⚡️ [Puppeteer][WebDriver] Updated
waitForClickable
method to check for element overlapping. See #2261 by @PiQx - 👍 [Puppeteer] Dropped
puppeteer-firefox
support, as Puppeteer supports Firefox natively. - 👀 [REST] Rrespect Content-Type header. See #2262 by @pmarshall-legacy
- 👀 [allure plugin] Fixes BeforeSuite failures in allure reports. See #2248 by @Georgegriff
- 👀 [WebDriver][Puppeteer][Playwright] A screenshot of for an active session is saved in multi-session mode. See #2253 by @ChexWarrior
- 🛠 Fixed
--profile
option by @pablopaul. Profile value to be passed intorun-multiple
andrun-workers
:
npx codecept run-workers 2 --profile firefox
👀 Value is available at
process.env.profile
(previouslyprocess.profile
). See #2302. Fixes #1968 #1315- ✅ commentStep Plugin introduced. Allows to annotate logical parts of a test:
__`Given`; I.amOnPage('/profile') __`When`; I.click('Logout'); __`Then`; I.see('You are logged out');