@uuv/runner-commons 2.4.1 → 2.6.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.
- package/CHANGELOG.md +20 -0
- package/dist/assets/i18n/web/en/en-enriched-wordings.json +14 -7
- package/dist/assets/i18n/web/en/en-roles.js +13 -11
- package/dist/assets/i18n/web/en/en.json +2 -2
- package/dist/assets/i18n/web/fr/fr-roles.js +11 -3
- package/dist/step-definition-generator/accessible-role.d.ts +2 -0
- package/dist/step-definition-generator/accessible-role.js +2 -0
- package/dist/step-definition-generator/generate-based-role-step-definitions.js +8 -0
- package/dist/step-definition-generator/generate-step-definitions-documentation.js +29 -6
- package/package.json +1 -1
- package/src/assets/i18n/web/en/en-enriched-wordings.json +14 -7
- package/src/assets/i18n/web/en/en.json +2 -2
- package/src/assets/i18n/web/fr/fr-enriched-wordings.json +14 -7
- package/src/assets/i18n/web/fr/fr.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,23 @@
|
|
|
1
|
+
## [2.6.0](https://github.com/Orange-OpenSource/uuv/compare/runner-commons-v2.5.0...runner-commons-v2.6.0) (2024-02-02)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Features
|
|
5
|
+
|
|
6
|
+
* rationalize list sentences, [#453](https://github.com/Orange-OpenSource/uuv/issues/453) ([dd98466](https://github.com/Orange-OpenSource/uuv/commit/dd98466f025a61d9ec007001b0a05de2482adef6))
|
|
7
|
+
* setup role based parameters shouldGenerateContainsSentence & shouldGenerateTypeSentence, [#453](https://github.com/Orange-OpenSource/uuv/issues/453) ([613b821](https://github.com/Orange-OpenSource/uuv/commit/613b821fadc70040fbfd4a27cc57b2197cc674bc))
|
|
8
|
+
|
|
9
|
+
## [2.5.0](https://github.com/Orange-OpenSource/uuv/compare/runner-commons-v2.4.1...runner-commons-v2.5.0) (2024-01-23)
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
### Features
|
|
13
|
+
|
|
14
|
+
* **a11y:** add RGAA 1.1.6 and 1.1.3, [#429](https://github.com/Orange-OpenSource/uuv/issues/429) ([0e65889](https://github.com/Orange-OpenSource/uuv/commit/0e65889b479651c27e16c29fdb8e5123fe689f03))
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
### Bug Fixes
|
|
18
|
+
|
|
19
|
+
* **runner-playwright:** update dependency axe-core to v4.8.3 ([4623485](https://github.com/Orange-OpenSource/uuv/commit/46234851677cf0e5f0479fe30bc786ae2a607f1e))
|
|
20
|
+
|
|
1
21
|
## [2.4.1](https://github.com/Orange-OpenSource/uuv/compare/runner-commons-v2.4.0...runner-commons-v2.4.1) (2024-01-21)
|
|
2
22
|
|
|
3
23
|
|
|
@@ -3,37 +3,44 @@
|
|
|
3
3
|
{
|
|
4
4
|
"key": "key.when.withinElement.roleAndName",
|
|
5
5
|
"description": "Selects the element whose [accessible role](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles#aria_role_types) and accessible [name](https://russmaxdesign.github.io/html-elements-names/) are specified <br />⚠ remember to deselect the element with <b>[I reset context](#i-reset-context)</b> if you're no longer acting on it",
|
|
6
|
-
"wording": "within $indefiniteArticle $roleName named {string}"
|
|
6
|
+
"wording": "within $indefiniteArticle $roleName named {string}",
|
|
7
|
+
"section": "general"
|
|
7
8
|
},
|
|
8
9
|
{
|
|
9
10
|
"key": "key.then.element.withRoleAndName",
|
|
10
11
|
"description": "Checks that an Html element exists with the specified [accessible role](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles#aria_role_types) and [name](https://russmaxdesign.github.io/html-elements-names/)",
|
|
11
|
-
"wording": "I should see $indefiniteArticle $roleName named {string}"
|
|
12
|
+
"wording": "I should see $indefiniteArticle $roleName named {string}",
|
|
13
|
+
"section": "general"
|
|
12
14
|
},
|
|
13
15
|
{
|
|
14
16
|
"key": "key.then.element.not.withRoleAndName",
|
|
15
17
|
"description": "Checks that an Html element does not exists with the specified [accessible role](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles#aria_role_types) and [name](https://russmaxdesign.github.io/html-elements-names/)",
|
|
16
|
-
"wording": "I should not see $indefiniteArticle $roleName named {string}"
|
|
18
|
+
"wording": "I should not see $indefiniteArticle $roleName named {string}",
|
|
19
|
+
"section": "general"
|
|
17
20
|
},
|
|
18
21
|
{
|
|
19
22
|
"key": "key.then.element.withRoleAndNameAndContent",
|
|
20
23
|
"description": "Checks that an Html element exists with the specified [accessible role](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles#aria_role_types), [name](https://russmaxdesign.github.io/html-elements-names/) and content",
|
|
21
|
-
"wording": "I should see $indefiniteArticle $roleName named {string} and containing {string}"
|
|
24
|
+
"wording": "I should see $indefiniteArticle $roleName named {string} and containing {string}",
|
|
25
|
+
"section": "contains"
|
|
22
26
|
},
|
|
23
27
|
{
|
|
24
28
|
"key": "key.then.element.withRoleAndNameAndContentDisabled",
|
|
25
29
|
"description": "Checks that an Html element exists with the specified [accessible role](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles#aria_role_types), [name](https://russmaxdesign.github.io/html-elements-names/) and content, and with the disabled attribute set to true",
|
|
26
|
-
"wording": "I should see $indefiniteArticle $roleName named {string} and containing {string} disabled"
|
|
30
|
+
"wording": "I should see $indefiniteArticle $roleName named {string} and containing {string} disabled",
|
|
31
|
+
"section": "contains"
|
|
27
32
|
},
|
|
28
33
|
{
|
|
29
34
|
"key": "key.then.element.withRoleAndNameAndContentEnabled",
|
|
30
35
|
"description": "Checks that an Html element exists with the specified [accessible role](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles#aria_role_types), [name](https://russmaxdesign.github.io/html-elements-names/) and content, and with the disabled attribute set to false",
|
|
31
|
-
"wording": "I should see $indefiniteArticle $roleName named {string} and containing {string} enabled"
|
|
36
|
+
"wording": "I should see $indefiniteArticle $roleName named {string} and containing {string} enabled",
|
|
37
|
+
"section": "contains"
|
|
32
38
|
},
|
|
33
39
|
{
|
|
34
40
|
"key": "key.when.type",
|
|
35
41
|
"description": "Writes the sentence given as a parameter inside the specified field (useful for example to fill in a form field)",
|
|
36
|
-
"wording": "I type the sentence {string} in $definiteArticle $roleName named {string}"
|
|
42
|
+
"wording": "I type the sentence {string} in $definiteArticle $roleName named {string}",
|
|
43
|
+
"section": "type"
|
|
37
44
|
}
|
|
38
45
|
]
|
|
39
46
|
}
|
|
@@ -12,21 +12,23 @@ var INDEFINITE_ARTICLE;
|
|
|
12
12
|
INDEFINITE_ARTICLE["AN"] = "an";
|
|
13
13
|
})(INDEFINITE_ARTICLE || (INDEFINITE_ARTICLE = {}));
|
|
14
14
|
class EnAccessibleRole extends accessible_role_1.AccessibleRole {
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
15
|
+
id;
|
|
16
|
+
name;
|
|
17
|
+
definiteArticle;
|
|
18
|
+
indefiniteArticle;
|
|
19
|
+
shouldGenerateTypeSentence;
|
|
20
|
+
shouldGenerateContainsSentence;
|
|
21
|
+
constructor(id, name, definiteArticle = DEFINITE_ARTICLE.THE, indefiniteArticle = INDEFINITE_ARTICLE.A, shouldGenerateTypeSentence = true, shouldGenerateContainsSentence = true) {
|
|
18
22
|
super();
|
|
19
23
|
this.id = id;
|
|
20
24
|
this.name = name;
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
this.indefiniteArticle = indefiniteArticle;
|
|
26
|
-
}
|
|
25
|
+
this.definiteArticle = definiteArticle;
|
|
26
|
+
this.indefiniteArticle = indefiniteArticle;
|
|
27
|
+
this.shouldGenerateTypeSentence = shouldGenerateTypeSentence;
|
|
28
|
+
this.shouldGenerateContainsSentence = shouldGenerateContainsSentence;
|
|
27
29
|
}
|
|
28
30
|
static from(input) {
|
|
29
|
-
return new EnAccessibleRole(input.id, input.name, input.definiteArticle, input.indefiniteArticle);
|
|
31
|
+
return new EnAccessibleRole(input.id, input.name, input.definiteArticle, input.indefiniteArticle, input.shouldGenerateTypeSentence, input.shouldGenerateContainsSentence);
|
|
30
32
|
}
|
|
31
33
|
getDefiniteArticle() {
|
|
32
34
|
return this.definiteArticle.toString();
|
|
@@ -73,7 +75,7 @@ exports.EN_ROLES = [
|
|
|
73
75
|
{ id: "input", name: "entry", indefiniteArticle: INDEFINITE_ARTICLE.AN },
|
|
74
76
|
{ id: "landmark", name: "landmark" },
|
|
75
77
|
{ id: "link", name: "link" },
|
|
76
|
-
{ id: "list", name: "list" },
|
|
78
|
+
{ id: "list", name: "list", shouldGenerateContainsSentence: false, shouldGenerateTypeSentence: false },
|
|
77
79
|
{ id: "listbox", name: "list box" },
|
|
78
80
|
{ id: "listitem", name: "list item" },
|
|
79
81
|
{ id: "log", name: "log" },
|
|
@@ -156,8 +156,8 @@
|
|
|
156
156
|
},
|
|
157
157
|
{
|
|
158
158
|
"key": "key.then.list.withNameAndContent",
|
|
159
|
-
"description": "Checks that there is a list with the specified [name](https://russmaxdesign.github.io/html-elements-names/)
|
|
160
|
-
"wording": "I should see
|
|
159
|
+
"description": "Checks that there is a list with the specified [name](https://russmaxdesign.github.io/html-elements-names/) containing list items.<br/> <u>Example</u>\\n```gherkin\\nThen I should see a list named \"test-list\" and containing\\n| First element |\\n| Second element |\\n| Third element |\\n```",
|
|
160
|
+
"wording": "I should see a list named {string} and containing"
|
|
161
161
|
},
|
|
162
162
|
{
|
|
163
163
|
"key": "key.then.element.not.withContent",
|
|
@@ -14,14 +14,20 @@ var FR_INDEFINITE_ARTICLE;
|
|
|
14
14
|
FR_INDEFINITE_ARTICLE["UNE"] = "une";
|
|
15
15
|
})(FR_INDEFINITE_ARTICLE || (FR_INDEFINITE_ARTICLE = {}));
|
|
16
16
|
class FrAccessibleRole extends accessible_role_1.AccessibleRole {
|
|
17
|
+
id;
|
|
18
|
+
name;
|
|
17
19
|
definiteArticle;
|
|
18
20
|
indefiniteArticle;
|
|
19
|
-
|
|
21
|
+
shouldGenerateTypeSentence;
|
|
22
|
+
shouldGenerateContainsSentence;
|
|
23
|
+
constructor(id, name, definiteArticle, indefiniteArticle, shouldGenerateTypeSentence = true, shouldGenerateContainsSentence = true) {
|
|
20
24
|
super();
|
|
21
25
|
this.id = id;
|
|
22
26
|
this.name = name;
|
|
23
27
|
this.definiteArticle = definiteArticle;
|
|
24
28
|
this.indefiniteArticle = indefiniteArticle;
|
|
29
|
+
this.shouldGenerateTypeSentence = shouldGenerateTypeSentence;
|
|
30
|
+
this.shouldGenerateContainsSentence = shouldGenerateContainsSentence;
|
|
25
31
|
}
|
|
26
32
|
getDefiniteArticle() {
|
|
27
33
|
return this.definiteArticle.toString();
|
|
@@ -237,7 +243,9 @@ exports.FR_ROLES = [
|
|
|
237
243
|
id: "list",
|
|
238
244
|
name: "liste",
|
|
239
245
|
definiteArticle: FR_DEFINITE_ARTICLE.LA,
|
|
240
|
-
indefiniteArticle: FR_INDEFINITE_ARTICLE.UNE
|
|
246
|
+
indefiniteArticle: FR_INDEFINITE_ARTICLE.UNE,
|
|
247
|
+
shouldGenerateContainsSentence: false,
|
|
248
|
+
shouldGenerateTypeSentence: false
|
|
241
249
|
},
|
|
242
250
|
{
|
|
243
251
|
id: "listbox",
|
|
@@ -557,4 +565,4 @@ exports.FR_ROLES = [
|
|
|
557
565
|
definiteArticle: FR_DEFINITE_ARTICLE.LA,
|
|
558
566
|
indefiniteArticle: FR_INDEFINITE_ARTICLE.UNE
|
|
559
567
|
}
|
|
560
|
-
].map(role => new FrAccessibleRole(role.id, role.name, role.definiteArticle, role.indefiniteArticle));
|
|
568
|
+
].map((role) => new FrAccessibleRole(role.id, role.name, role.definiteArticle, role.indefiniteArticle, role.shouldGenerateContainsSentence, role.shouldGenerateContainsSentence));
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
export declare abstract class AccessibleRole {
|
|
2
2
|
id: string;
|
|
3
3
|
name: string;
|
|
4
|
+
shouldGenerateTypeSentence: boolean;
|
|
5
|
+
shouldGenerateContainsSentence: boolean;
|
|
4
6
|
abstract getDefiniteArticle(): string;
|
|
5
7
|
abstract getIndefiniteArticle(): string;
|
|
6
8
|
abstract getOfDefiniteArticle(): string;
|
|
@@ -91,6 +91,14 @@ class BasedRoleStepDefinition extends common_1.GenerateFileProcessing {
|
|
|
91
91
|
.replaceAll("$ofDefiniteArticle", role.getOfDefiniteArticle())
|
|
92
92
|
.replaceAll(conf.key + ".description", conf.description);
|
|
93
93
|
});
|
|
94
|
+
// Exclude Role based Content sentence if specified
|
|
95
|
+
if (!role.shouldGenerateContainsSentence) {
|
|
96
|
+
dataUpdated = dataUpdated.replace(/\/\/ Begin of Content Section[\s\S]*?\/\/ End of Content Section/, "");
|
|
97
|
+
}
|
|
98
|
+
// Exclude Role based Type sentence if specified
|
|
99
|
+
if (!role.shouldGenerateTypeSentence) {
|
|
100
|
+
dataUpdated = dataUpdated.replace(/\/\/ Begin of Type Section[\s\S]*?\/\/ End of Type Section/, "");
|
|
101
|
+
}
|
|
94
102
|
const generatedFilename = generatedFile.replace("$roleId", role.id);
|
|
95
103
|
// console.debug(">>> data", dataUpdated)
|
|
96
104
|
// console.debug(">>> generatedFilename", generatedFilename)
|
|
@@ -130,17 +130,17 @@ function runGenerateDoc(destDir) {
|
|
|
130
130
|
.replaceAll("$namedAdjective", role.namedAdjective())
|
|
131
131
|
.replaceAll("$ofDefiniteArticle", role.getOfDefiniteArticle());
|
|
132
132
|
const wordingsEnrichedJson = JSON.parse(dataUpdated);
|
|
133
|
-
const { step: enrichedGiven, autocompletionSuggestions: enrichedGivenAutocompletionSuggestions } = computeStepDefinition(wordingsEnrichedJson.enriched, "key.given", undefined, "####");
|
|
133
|
+
const { step: enrichedGiven, autocompletionSuggestions: enrichedGivenAutocompletionSuggestions } = computeStepDefinition(wordingsEnrichedJson.enriched, "key.given", undefined, "####", role);
|
|
134
134
|
if (enrichedGiven.length > 1) {
|
|
135
135
|
rows.push(...enrichedGiven);
|
|
136
136
|
autocompletionSuggestions.push(...enrichedGivenAutocompletionSuggestions);
|
|
137
137
|
}
|
|
138
|
-
const { step: enrichedWhen, autocompletionSuggestions: enrichedWhenAutocompletionSuggestions } = computeStepDefinition(wordingsEnrichedJson.enriched, "key.when", undefined, "####");
|
|
138
|
+
const { step: enrichedWhen, autocompletionSuggestions: enrichedWhenAutocompletionSuggestions } = computeStepDefinition(wordingsEnrichedJson.enriched, "key.when", undefined, "####", role);
|
|
139
139
|
if (enrichedWhen.length > 1) {
|
|
140
140
|
rows.push(...enrichedWhen);
|
|
141
141
|
autocompletionSuggestions.push(...enrichedWhenAutocompletionSuggestions);
|
|
142
142
|
}
|
|
143
|
-
const { step: enrichedThen, autocompletionSuggestions: enrichedThenAutocompletionSuggestions } = computeStepDefinition(wordingsEnrichedJson.enriched, "key.then", undefined, "####");
|
|
143
|
+
const { step: enrichedThen, autocompletionSuggestions: enrichedThenAutocompletionSuggestions } = computeStepDefinition(wordingsEnrichedJson.enriched, "key.then", undefined, "####", role);
|
|
144
144
|
if (enrichedThen.length > 1) {
|
|
145
145
|
rows.push(...enrichedThen);
|
|
146
146
|
autocompletionSuggestions.push(...enrichedThenAutocompletionSuggestions);
|
|
@@ -152,17 +152,27 @@ function runGenerateDoc(destDir) {
|
|
|
152
152
|
};
|
|
153
153
|
}
|
|
154
154
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
155
|
-
function computeStepDefinition(wordingsJson, stepKey, stepTitle, level = "###") {
|
|
155
|
+
function computeStepDefinition(wordingsJson, stepKey, stepTitle, level = "###", role) {
|
|
156
156
|
const step = [];
|
|
157
157
|
const autocompletionSuggestion = [];
|
|
158
158
|
if (stepTitle) {
|
|
159
159
|
step.push(stepTitle);
|
|
160
160
|
}
|
|
161
161
|
wordingsJson.forEach((conf) => {
|
|
162
|
-
if (conf.key.startsWith(stepKey)) {
|
|
162
|
+
if (conf.key.startsWith(stepKey) && shouldGenerate(conf, role)) {
|
|
163
163
|
const wording = `${level} ${conf.wording}`;
|
|
164
164
|
step.push(wording);
|
|
165
|
-
|
|
165
|
+
conf.description?.split("\\n").forEach((descriptionLine, index, array) => {
|
|
166
|
+
if (index === 0) {
|
|
167
|
+
step.push(`> ${descriptionLine ?? ""}`);
|
|
168
|
+
}
|
|
169
|
+
else if (index === array.length - 1) {
|
|
170
|
+
step.push(` ${descriptionLine ?? ""}\n`);
|
|
171
|
+
}
|
|
172
|
+
else {
|
|
173
|
+
step.push(` ${descriptionLine ?? ""}`);
|
|
174
|
+
}
|
|
175
|
+
});
|
|
166
176
|
autocompletionSuggestion.push({
|
|
167
177
|
suggestion: conf.wording
|
|
168
178
|
.replaceAll("\\", ""),
|
|
@@ -182,6 +192,19 @@ function runGenerateDoc(destDir) {
|
|
|
182
192
|
autocompletionSuggestions: autocompletionSuggestion
|
|
183
193
|
};
|
|
184
194
|
}
|
|
195
|
+
function shouldGenerate(wordingsConf, role) {
|
|
196
|
+
if (role === undefined) {
|
|
197
|
+
return true;
|
|
198
|
+
}
|
|
199
|
+
switch (wordingsConf.section) {
|
|
200
|
+
case "contains":
|
|
201
|
+
return role.shouldGenerateContainsSentence;
|
|
202
|
+
case "type":
|
|
203
|
+
return role.shouldGenerateTypeSentence;
|
|
204
|
+
default:
|
|
205
|
+
return true;
|
|
206
|
+
}
|
|
207
|
+
}
|
|
185
208
|
function writeWordingFile(generatedFile, data, lang, indexOfFile) {
|
|
186
209
|
fs_1.default.writeFileSync(generatedFile, data);
|
|
187
210
|
console.log(`[WRITE] ${indexOfFile}-${lang}-generated-wording-description.md written successfully`);
|
package/package.json
CHANGED
|
@@ -3,37 +3,44 @@
|
|
|
3
3
|
{
|
|
4
4
|
"key": "key.when.withinElement.roleAndName",
|
|
5
5
|
"description": "Selects the element whose [accessible role](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles#aria_role_types) and accessible [name](https://russmaxdesign.github.io/html-elements-names/) are specified <br />⚠ remember to deselect the element with <b>[I reset context](#i-reset-context)</b> if you're no longer acting on it",
|
|
6
|
-
"wording": "within $indefiniteArticle $roleName named {string}"
|
|
6
|
+
"wording": "within $indefiniteArticle $roleName named {string}",
|
|
7
|
+
"section": "general"
|
|
7
8
|
},
|
|
8
9
|
{
|
|
9
10
|
"key": "key.then.element.withRoleAndName",
|
|
10
11
|
"description": "Checks that an Html element exists with the specified [accessible role](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles#aria_role_types) and [name](https://russmaxdesign.github.io/html-elements-names/)",
|
|
11
|
-
"wording": "I should see $indefiniteArticle $roleName named {string}"
|
|
12
|
+
"wording": "I should see $indefiniteArticle $roleName named {string}",
|
|
13
|
+
"section": "general"
|
|
12
14
|
},
|
|
13
15
|
{
|
|
14
16
|
"key": "key.then.element.not.withRoleAndName",
|
|
15
17
|
"description": "Checks that an Html element does not exists with the specified [accessible role](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles#aria_role_types) and [name](https://russmaxdesign.github.io/html-elements-names/)",
|
|
16
|
-
"wording": "I should not see $indefiniteArticle $roleName named {string}"
|
|
18
|
+
"wording": "I should not see $indefiniteArticle $roleName named {string}",
|
|
19
|
+
"section": "general"
|
|
17
20
|
},
|
|
18
21
|
{
|
|
19
22
|
"key": "key.then.element.withRoleAndNameAndContent",
|
|
20
23
|
"description": "Checks that an Html element exists with the specified [accessible role](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles#aria_role_types), [name](https://russmaxdesign.github.io/html-elements-names/) and content",
|
|
21
|
-
"wording": "I should see $indefiniteArticle $roleName named {string} and containing {string}"
|
|
24
|
+
"wording": "I should see $indefiniteArticle $roleName named {string} and containing {string}",
|
|
25
|
+
"section": "contains"
|
|
22
26
|
},
|
|
23
27
|
{
|
|
24
28
|
"key": "key.then.element.withRoleAndNameAndContentDisabled",
|
|
25
29
|
"description": "Checks that an Html element exists with the specified [accessible role](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles#aria_role_types), [name](https://russmaxdesign.github.io/html-elements-names/) and content, and with the disabled attribute set to true",
|
|
26
|
-
"wording": "I should see $indefiniteArticle $roleName named {string} and containing {string} disabled"
|
|
30
|
+
"wording": "I should see $indefiniteArticle $roleName named {string} and containing {string} disabled",
|
|
31
|
+
"section": "contains"
|
|
27
32
|
},
|
|
28
33
|
{
|
|
29
34
|
"key": "key.then.element.withRoleAndNameAndContentEnabled",
|
|
30
35
|
"description": "Checks that an Html element exists with the specified [accessible role](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles#aria_role_types), [name](https://russmaxdesign.github.io/html-elements-names/) and content, and with the disabled attribute set to false",
|
|
31
|
-
"wording": "I should see $indefiniteArticle $roleName named {string} and containing {string} enabled"
|
|
36
|
+
"wording": "I should see $indefiniteArticle $roleName named {string} and containing {string} enabled",
|
|
37
|
+
"section": "contains"
|
|
32
38
|
},
|
|
33
39
|
{
|
|
34
40
|
"key": "key.when.type",
|
|
35
41
|
"description": "Writes the sentence given as a parameter inside the specified field (useful for example to fill in a form field)",
|
|
36
|
-
"wording": "I type the sentence {string} in $definiteArticle $roleName named {string}"
|
|
42
|
+
"wording": "I type the sentence {string} in $definiteArticle $roleName named {string}",
|
|
43
|
+
"section": "type"
|
|
37
44
|
}
|
|
38
45
|
]
|
|
39
46
|
}
|
|
@@ -156,8 +156,8 @@
|
|
|
156
156
|
},
|
|
157
157
|
{
|
|
158
158
|
"key": "key.then.list.withNameAndContent",
|
|
159
|
-
"description": "Checks that there is a list with the specified [name](https://russmaxdesign.github.io/html-elements-names/)
|
|
160
|
-
"wording": "I should see
|
|
159
|
+
"description": "Checks that there is a list with the specified [name](https://russmaxdesign.github.io/html-elements-names/) containing list items.<br/> <u>Example</u>\\n```gherkin\\nThen I should see a list named \"test-list\" and containing\\n| First element |\\n| Second element |\\n| Third element |\\n```",
|
|
160
|
+
"wording": "I should see a list named {string} and containing"
|
|
161
161
|
},
|
|
162
162
|
{
|
|
163
163
|
"key": "key.then.element.not.withContent",
|
|
@@ -3,37 +3,44 @@
|
|
|
3
3
|
{
|
|
4
4
|
"key": "key.when.withinElement.roleAndName",
|
|
5
5
|
"description": "Sélectionne l'élément ayant le rôle $roleId et le [nom accessible](https://russmaxdesign.github.io/html-elements-names/) sont spécifiés <br />⚠ pensez à déselectionner l'élement avec <b>[je reinitialise le contexte](#je-reinitialise-le-contexte)</b> si vous n'agissez plus dessus",
|
|
6
|
-
"wording": "je vais à l'intérieur $ofDefiniteArticle$roleName $namedAdjective {string}"
|
|
6
|
+
"wording": "je vais à l'intérieur $ofDefiniteArticle$roleName $namedAdjective {string}",
|
|
7
|
+
"section": "general"
|
|
7
8
|
},
|
|
8
9
|
{
|
|
9
10
|
"key": "key.then.element.withRoleAndName",
|
|
10
11
|
"description": "Vérifie l'existence d'un élément Html ayant le rôle $roleId et le [nom accessible](https://russmaxdesign.github.io/html-elements-names/) spécifiés",
|
|
11
|
-
"wording": "je dois voir $indefiniteArticle $roleName $namedAdjective {string}"
|
|
12
|
+
"wording": "je dois voir $indefiniteArticle $roleName $namedAdjective {string}",
|
|
13
|
+
"section": "general"
|
|
12
14
|
},
|
|
13
15
|
{
|
|
14
16
|
"key": "key.then.element.not.withRoleAndName",
|
|
15
17
|
"description": "Vérifie l'inexistence d'un élément Html ayant le rôle $roleId et le [nom accessible](https://russmaxdesign.github.io/html-elements-names/) spécifiés",
|
|
16
|
-
"wording": "je ne dois pas voir $indefiniteArticle $roleName $namedAdjective {string}"
|
|
18
|
+
"wording": "je ne dois pas voir $indefiniteArticle $roleName $namedAdjective {string}",
|
|
19
|
+
"section": "general"
|
|
17
20
|
},
|
|
18
21
|
{
|
|
19
22
|
"key": "key.then.element.withRoleAndNameAndContent",
|
|
20
23
|
"description": "Vérifie l'existence d'un élément Html ayant le rôle $roleId, le [nom accessible](https://russmaxdesign.github.io/html-elements-names/) et le contenu spécifiés",
|
|
21
|
-
"wording": "je dois voir $indefiniteArticle $roleName $namedAdjective {string} et contenant {string}"
|
|
24
|
+
"wording": "je dois voir $indefiniteArticle $roleName $namedAdjective {string} et contenant {string}",
|
|
25
|
+
"section": "contains"
|
|
22
26
|
},
|
|
23
27
|
{
|
|
24
28
|
"key": "key.then.element.withRoleAndNameAndContentDisabled",
|
|
25
29
|
"description": "Vérifie l'existence d'un élément Html ayant le rôle $roleId, le [nom accessible](https://russmaxdesign.github.io/html-elements-names/), le contenu spécifiés et avec l'attribut disabled à false",
|
|
26
|
-
"wording": "je dois voir $indefiniteArticle $roleName $namedAdjective {string} et contenant {string} inactif"
|
|
30
|
+
"wording": "je dois voir $indefiniteArticle $roleName $namedAdjective {string} et contenant {string} inactif",
|
|
31
|
+
"section": "contains"
|
|
27
32
|
},
|
|
28
33
|
{
|
|
29
34
|
"key": "key.then.element.withRoleAndNameAndContentEnabled",
|
|
30
35
|
"description": "Vérifie l'existence d'un élément Html ayant le rôle $roleId, le [nom accessible](https://russmaxdesign.github.io/html-elements-names/), le contenu spécifiés et avec l'attribut disabled à true",
|
|
31
|
-
"wording": "je dois voir $indefiniteArticle $roleName $namedAdjective {string} et contenant {string} actif"
|
|
36
|
+
"wording": "je dois voir $indefiniteArticle $roleName $namedAdjective {string} et contenant {string} actif",
|
|
37
|
+
"section": "contains"
|
|
32
38
|
},
|
|
33
39
|
{
|
|
34
40
|
"key": "key.when.type",
|
|
35
41
|
"description": "Saisie de la phrase passée en paramètre dans le champ spécifié(utile par exemple pour remplir un champ de formulaire).",
|
|
36
|
-
"wording": "je saisie le(s) mot(s) {string} dans $definiteArticle$roleName $namedAdjective {string}"
|
|
42
|
+
"wording": "je saisie le(s) mot(s) {string} dans $definiteArticle$roleName $namedAdjective {string}",
|
|
43
|
+
"section": "type"
|
|
37
44
|
}
|
|
38
45
|
]
|
|
39
46
|
}
|
|
@@ -156,8 +156,8 @@
|
|
|
156
156
|
},
|
|
157
157
|
{
|
|
158
158
|
"key": "key.then.list.withNameAndContent",
|
|
159
|
-
"description": "Vérifie qu'il existe une liste avec le nom et
|
|
160
|
-
"wording": "je dois voir
|
|
159
|
+
"description": "Vérifie qu'il existe une liste avec le nom et les éléments de liste spécifiés.<br/> <u>Exemple</u>\\n```gherkin\\nAlors je dois voir une liste nommée \"test-list\" et contenant\\n| Premier élément |\\n| Deuxième élément |\\n| Troisième élément |\\n```",
|
|
160
|
+
"wording": "je dois voir une liste nommée {string} et contenant"
|
|
161
161
|
},
|
|
162
162
|
{
|
|
163
163
|
"key": "key.then.element.not.withContent",
|