Skip to content

Commit 418245a

Browse files
authored
release 3.6.2 (#4332)
1 parent defee8e commit 418245a

File tree

2 files changed

+97
-1
lines changed

2 files changed

+97
-1
lines changed

CHANGELOG.md

+96
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,99 @@
1+
## 3.6.2
2+
3+
❤️ Thanks all to those who contributed to make this release! ❤️
4+
5+
🛩️ *Features*
6+
* feat(REST): support httpAgent conf (#4328) - by @KobeNguyent
7+
8+
Support the httpAgent conf to create the TSL connection via REST helper
9+
10+
```
11+
{
12+
helpers: {
13+
REST: {
14+
endpoint: 'http://site.com/api',
15+
prettyPrintJson: true,
16+
httpAgent: {
17+
key: fs.readFileSync(__dirname + '/path/to/keyfile.key'),
18+
cert: fs.readFileSync(__dirname + '/path/to/certfile.cert'),
19+
rejectUnauthorized: false,
20+
keepAlive: true
21+
}
22+
}
23+
}
24+
}
25+
```
26+
27+
* feat(wd): screenshots for sessions (#4322) - by @KobeNguyent
28+
29+
Currently only screenshot of the active session is saved, this PR aims to save the screenshot of every session for easy debugging
30+
31+
```
32+
Scenario('should save screenshot for sessions @WebDriverIO @Puppeteer @Playwright', async ({ I }) => {
33+
await I.amOnPage('/form/bug1467');
34+
await I.saveScreenshot('original.png');
35+
await I.amOnPage('/');
36+
await I.saveScreenshot('main_session.png');
37+
session('john', async () => {
38+
await I.amOnPage('/form/bug1467');
39+
event.dispatcher.emit(event.test.failed, this);
40+
});
41+
42+
const fileName = clearString('should save screenshot for active session @WebDriverIO @Puppeteer @Playwright');
43+
const [original, failed] = await I.getSHA256Digests([
44+
`${output_dir}/original.png`,
45+
`${output_dir}/john_${fileName}.failed.png`,
46+
]);
47+
48+
// Assert that screenshots of same page in same session are equal
49+
await I.expectEqual(original, failed);
50+
51+
// Assert that screenshots of sessions are created
52+
const [main_original, session_failed] = await I.getSHA256Digests([
53+
`${output_dir}/main_session.png`,
54+
`${output_dir}/john_${fileName}.failed.png`,
55+
]);
56+
await I.expectNotEqual(main_original, session_failed);
57+
});
58+
```
59+
![Screenshot 2024-04-29 at 11 07 47](https://github.com/codeceptjs/CodeceptJS/assets/7845001/5dddf85a-ed77-474b-adfd-2f208d3c16a8)
60+
61+
62+
* feat: locate element with withClassAttr (#4321) - by @KobeNguyent
63+
64+
Find an element with class attribute
65+
66+
```js
67+
// find div with class contains 'form'
68+
locate('div').withClassAttr('text');
69+
```
70+
71+
* fix(playwright): set the record video resolution (#4311) - by @KobeNguyent
72+
You could now set the recording video resolution
73+
```
74+
url: siteUrl,
75+
windowSize: '300x500',
76+
show: false,
77+
restart: true,
78+
browser: 'chromium',
79+
trace: true,
80+
video: true,
81+
recordVideo: {
82+
size: {
83+
width: 400,
84+
height: 600,
85+
},
86+
},
87+
```
88+
89+
🐛 *Bug Fixes*
90+
* fix: several issues of stepByStep report (#4331) - by @KobeNguyent
91+
92+
📖 *Documentation*
93+
* fix: wrong format docs (#4330) - by @KobeNguyent
94+
* fix(docs): wrong method is mentioned (#4320) - by @KobeNguyent
95+
* fix: ChatGPT docs - by @davert
96+
197
## 3.6.1
298

399
* Fixed regression in interactive pause.

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "codeceptjs",
3-
"version": "3.6.1",
3+
"version": "3.6.2",
44
"description": "Supercharged End 2 End Testing Framework for NodeJS",
55
"keywords": [
66
"acceptance",

0 commit comments

Comments
 (0)