@webship-js/magento-steps 2.0.0 → 2.0.1
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/README.md +18 -12
- package/package.json +1 -1
- package/tests/step-definitions/README.md +1 -1
package/README.md
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
<p align="center"><img src="https://raw.githubusercontent.com/webship/magento-steps/2.0.x/assets/logo.svg" alt="Magento logo" width="96"></p>
|
|
2
|
+
|
|
1
3
|
# magento-steps
|
|
2
4
|
|
|
3
5
|
Cucumber step definitions for testing Magento Open Source stores with
|
|
@@ -75,10 +77,10 @@ npm install --save-dev @webship-js/magento-steps
|
|
|
75
77
|
|
|
76
78
|
| Path | Purpose |
|
|
77
79
|
| --- | --- |
|
|
78
|
-
| `tests/step-definitions/magento.steps.js` | Both sides: messages, confirmation dialogs, the settled wait. |
|
|
79
80
|
| `tests/step-definitions/magento-admin.steps.js` | Admin panel: session, named pages, page title, menu, access denied, page buttons, grids, forms, tabs. |
|
|
80
81
|
| `tests/step-definitions/magento-admin-content.steps.js` | Admin content: products, the category tree, orders, customers, configuration, cache and index, clean-up. |
|
|
81
82
|
| `tests/step-definitions/magento-storefront.steps.js` | Storefront: customer session, menu, breadcrumbs, product list, search, product page, mini cart, cart, checkout, account, wish list, compare, reviews, newsletter, field errors. |
|
|
83
|
+
| `tests/step-definitions/magento.steps.js` | Both sides: messages, confirmation dialogs, the settled wait. |
|
|
82
84
|
| `tests/step-definitions/magento-helpers.js` | Shared plumbing. It registers no step. |
|
|
83
85
|
| `tests/features/*.feature` | Reference features for a store with the sample data. |
|
|
84
86
|
| `tests/features/90-assertions-must-fail.feature` | Scenarios that state something false: `npm run test:must-fail` passes only when every one of them fails with a helpful message. |
|
|
@@ -89,17 +91,6 @@ npm install --save-dev @webship-js/magento-steps
|
|
|
89
91
|
|
|
90
92
|
128 step definitions. The JSDoc block above each one holds five examples.
|
|
91
93
|
|
|
92
|
-
### Both sides
|
|
93
|
-
|
|
94
|
-
```gherkin
|
|
95
|
-
Then I should see the success message "You saved the product."
|
|
96
|
-
Then I should not see an error message
|
|
97
|
-
Then I should see the confirmation "Are you sure you want to delete this category?"
|
|
98
|
-
When I confirm the action
|
|
99
|
-
When I dismiss the confirmation
|
|
100
|
-
When I wait for the page to settle
|
|
101
|
-
```
|
|
102
|
-
|
|
103
94
|
### Admin panel: session, pages, menu
|
|
104
95
|
|
|
105
96
|
```gherkin
|
|
@@ -252,6 +243,17 @@ the form a person sees.
|
|
|
252
243
|
placed order" is then found in the orders grid of the admin panel and in the
|
|
253
244
|
order history of the customer, in the same scenario.
|
|
254
245
|
|
|
246
|
+
### Both sides
|
|
247
|
+
|
|
248
|
+
```gherkin
|
|
249
|
+
Then I should see the success message "You saved the product."
|
|
250
|
+
Then I should not see an error message
|
|
251
|
+
Then I should see the confirmation "Are you sure you want to delete this category?"
|
|
252
|
+
When I confirm the action
|
|
253
|
+
When I dismiss the confirmation
|
|
254
|
+
When I wait for the page to settle
|
|
255
|
+
```
|
|
256
|
+
|
|
255
257
|
## Accounts
|
|
256
258
|
|
|
257
259
|
The accounts are configuration, not test data. They are named in
|
|
@@ -398,3 +400,7 @@ failed scenario once more.
|
|
|
398
400
|
## License
|
|
399
401
|
|
|
400
402
|
MIT
|
|
403
|
+
|
|
404
|
+
## Logo
|
|
405
|
+
|
|
406
|
+
The Magento logo in this README comes from Simple Icons 16.37.0 (CC0-1.0), filled with the colour the set lists for the brand. The Magento name and logo are trademarks of their owner; this pack is not affiliated with or endorsed by them.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@webship-js/magento-steps",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.1",
|
|
4
4
|
"description": "Cucumber step definitions for testing Magento Open Source stores with webship-js: the admin panel (session, menu, grids, forms, catalog, orders, customers, cart price rules, content, configuration, cache and index, permissions) and the storefront (catalog, layered navigation, search, product page, cart, checkout, customer account, wish list, compare, reviews, newsletter).",
|
|
5
5
|
"main": "tests/step-definitions/magento.steps.js",
|
|
6
6
|
"files": [
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
|
|
3
3
|
| File | Covers |
|
|
4
4
|
| --- | --- |
|
|
5
|
-
| `magento.steps.js` | Both sides: the messages (success, error, warning, notice), the confirmation dialogs, the settled wait. |
|
|
6
5
|
| `magento-admin.steps.js` | The admin panel: log in by account handle, log out, the session, named pages and the page title, the menu, the access denied page, page buttons, grids (keyword search, filters, sorting, paging, page size, row selection, actions, cell values), forms (fields by label, switches, the category chooser, sections, tabs, field errors, save). |
|
|
7
6
|
| `magento-admin-content.steps.js` | Admin content: a product by SKU and its gallery, the category tree, orders (open, status, comments, hold, invoice, ship, credit memo, cancel), a customer by email, the configuration, the cache and index state, the clean-up of records. |
|
|
8
7
|
| `magento-storefront.steps.js` | The storefront: the customer session, the top menu, breadcrumbs, the product list (amount, sorting, direction, list and grid, paging, layered navigation), search and suggestions, the product page (options, quantity, add to cart, price), the mini cart, the cart (quantity, remove, totals, coupon, shipping estimate), the checkout through to the order number, the account pages, the order history, the address book, the wish list, the comparison list, reviews, the newsletter, field errors. |
|
|
8
|
+
| `magento.steps.js` | Both sides: the messages (success, error, warning, notice), the confirmation dialogs, the settled wait. |
|
|
9
9
|
| `magento-helpers.js` | Shared plumbing: the wait budget, the settled signal, presence and value assertions, URLs, the users registry, messages, dialogs, named admin pages, both kinds of admin grid, admin form fields and sections. It registers no step. |
|
|
10
10
|
|
|
11
11
|
## Rules for a new step
|