-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathfeature-request-issue-github.spec.ts
More file actions
86 lines (76 loc) · 2.19 KB
/
Copy pathfeature-request-issue-github.spec.ts
File metadata and controls
86 lines (76 loc) · 2.19 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
import { aui } from './helper/jest.setup';
describe('request a feature in Github with askui', () => {
it('should open askui Github repo', async () => {
// Starting point is google.com
// Focus is the in the search field
await aui.type('https://github.com/askui/askui').exec();
await aui.pressKey('enter').exec();
});
it('should open an issue', async () => {
await aui.click()
.text('Issues')
.above()
.text('Code')
.exec();
await aui.clickButton('New issue')
await aui.click()
.button()
.withText('Get started')
.below()
.text('Create a report to help us improve')
.exec();
await aui.expect()
.text('Issue: Feature request')
.exists()
.exec();
await aui.typeIn('scrollUntil')
.text('Title')
.above()
.button()
.withText('write')
.exec();
await aui.click()
.textfield()
.below()
.button()
.withText('write')
.exec();
await aui.pressTwoKeys('control', 'A')
.exec();
await aui.pressKey('delete')
.exec();
});
it('should fill the feature request', async () => {
const requestTextLines: string[] = [
'# ScrollUntil',
' ',
'## Problem',
' ',
'Whenever the current user wants to scroll to find an elements,'
+ 'they are forced to guess the scroll offset',
' ',
'## Solution:',
' ',
'A scrollUntil function, so that the user will only write ,'
+ 'until which element they want to scroll and not care about the scroll offset',
' ',
'## Notes:',
' ',
'please Make sure to do it as fast as possible, '
+ 'I want the user to enjoy using ME as testing solution',
'** Feature Request, that was requested by the askui Nodejs package :crown: **',
];
/* eslint-disable no-await-in-loop */
for (let i = 0; i < requestTextLines.length; i += 1) {
await aui.type(requestTextLines[i]).exec();
await aui.pressKey('enter').exec();
}
});
it('should submit new issue', async () => {
await aui.expect()
.text('scrollUntil')
.exists()
.exec();
await aui.clickButton('Submit new issue');
});
});