From 07652be862f4b1e0b6e0ee76473e907f6ab8cfd7 Mon Sep 17 00:00:00 2001 From: Tom Reece Date: Fri, 28 Jun 2019 09:19:16 -0500 Subject: [PATCH 1/3] MQE-1609: Add more MFTF technical guidelines to devdocs --- .../coding-standards/technical-guidelines.md | 28 +++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/guides/v2.2/coding-standards/technical-guidelines.md b/guides/v2.2/coding-standards/technical-guidelines.md index a9f2206e140..dba7cae8841 100644 --- a/guides/v2.2/coding-standards/technical-guidelines.md +++ b/guides/v2.2/coding-standards/technical-guidelines.md @@ -746,6 +746,34 @@ You need to read configuration from different sources (like database or filesyst 11.3.2.3. There MUST be only one `
` entity per file. +#### 11.3.3. Elements + +11.3.3.1. All element selectors MUST follow these [best practices](https://devdocs.magento.com/mftf/docs/best-practices.html). + +11.3.3.2. The element's `name` MUST be unique in the `
`. + +11.3.3.3. The element's `name` SHOULD be written in [camelCase](http://wiki.c2.com/?CamelCase). + +11.3.3.4. Element selectors SHOULD be written in CSS instead of Xpath. + +11.3.3.5. CSS and Xpath selectors MUST NOT reference `@data-bind`. + +11.3.3.6. Parameterized selectors MUST use descriptive names for their parameters. + +11.3.3.7. Elements SHOULD use the `timeout` attribute to wait after interactions. + +#### 11.3.4. Data Entities + +11.3.4.1. Data entity file names MUST follow this pattern: + +* {Type}Data.xml, where {Type} describes the type of entities. +* Use [PascalCase](http://wiki.c2.com/?PascalCase). +* Examples: ProductData.xml or CustomerData.xml + +11.3.4.2. Data entities SHOULD make use of `unique="suffix"` or `unique="prefix"` to ensure that tests using the entity can be repeatedly ran against the same environment. + +11.3.4.3. Changes to existing data entities MUST be compatible with existing tests. + ## 12. Web API 12.1. Both REST and SOAP API's MUST be exposed. From 020701f453a3cc1d35afc1afca3628f67e7c1d97 Mon Sep 17 00:00:00 2001 From: Donald Booth Date: Fri, 28 Jun 2019 09:32:42 -0500 Subject: [PATCH 2/3] Small fixes --- guides/v2.2/coding-standards/technical-guidelines.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/guides/v2.2/coding-standards/technical-guidelines.md b/guides/v2.2/coding-standards/technical-guidelines.md index dba7cae8841..32a75988d80 100644 --- a/guides/v2.2/coding-standards/technical-guidelines.md +++ b/guides/v2.2/coding-standards/technical-guidelines.md @@ -750,13 +750,13 @@ You need to read configuration from different sources (like database or filesyst 11.3.3.1. All element selectors MUST follow these [best practices](https://devdocs.magento.com/mftf/docs/best-practices.html). -11.3.3.2. The element's `name` MUST be unique in the `
`. +11.3.3.2. The element `name` MUST be unique within the `
`. -11.3.3.3. The element's `name` SHOULD be written in [camelCase](http://wiki.c2.com/?CamelCase). +11.3.3.3. The element `name` SHOULD be written in [camelCase](http://wiki.c2.com/?CamelCase). -11.3.3.4. Element selectors SHOULD be written in CSS instead of Xpath. +11.3.3.4. Element selectors SHOULD be written in CSS instead of XPath. -11.3.3.5. CSS and Xpath selectors MUST NOT reference `@data-bind`. +11.3.3.5. CSS and XPath selectors MUST NOT reference `@data-bind`. 11.3.3.6. Parameterized selectors MUST use descriptive names for their parameters. @@ -776,7 +776,7 @@ You need to read configuration from different sources (like database or filesyst ## 12. Web API -12.1. Both REST and SOAP API's MUST be exposed. +12.1. Both REST and SOAP APIs MUST be exposed. 12.2. All [Web API](https://glossary.magento.com/web-api) GET endpoints MUST return lists of entities. From 09351daa8ad6819f803fe9ca1fb84cace3abfda2 Mon Sep 17 00:00:00 2001 From: Tom Reece Date: Fri, 12 Jul 2019 14:04:59 -0500 Subject: [PATCH 3/3] Remove two items that we discussed in meeting --- guides/v2.2/coding-standards/technical-guidelines.md | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/guides/v2.2/coding-standards/technical-guidelines.md b/guides/v2.2/coding-standards/technical-guidelines.md index 32a75988d80..128437f0713 100644 --- a/guides/v2.2/coding-standards/technical-guidelines.md +++ b/guides/v2.2/coding-standards/technical-guidelines.md @@ -754,13 +754,9 @@ You need to read configuration from different sources (like database or filesyst 11.3.3.3. The element `name` SHOULD be written in [camelCase](http://wiki.c2.com/?CamelCase). -11.3.3.4. Element selectors SHOULD be written in CSS instead of XPath. +11.3.3.4. Parameterized selectors MUST use descriptive names for their parameters. -11.3.3.5. CSS and XPath selectors MUST NOT reference `@data-bind`. - -11.3.3.6. Parameterized selectors MUST use descriptive names for their parameters. - -11.3.3.7. Elements SHOULD use the `timeout` attribute to wait after interactions. +11.3.3.5. Elements SHOULD use the `timeout` attribute to wait after interactions. #### 11.3.4. Data Entities