woocommerce/plugins/woocommerce-blocks/assets/js
Darren Ethier 41ca430ffe Add initial cart flow tests (https://github.com/woocommerce/woocommerce-blocks/pull/2678)
* more setup configuration for rtl

* move default state for cart out of reducer

This also creates a file for default store states, it should make it easier to execute tests in various environments.

* Make sure there’s a default object for cart line item row

* set defaults for cartData

* add fetchMock as a global in eslint config

* add initial cart flow tests

This is just to get the ball rolling, the cart block needs more tests

* fix missing @wordpress/jest-console configs (because I overwrote the original configuration)

* update test because of change in branch

* switch import order

* add globals.d.ts file to declare globals we use.

This is a quick solution to prevent typescript linting warning about `fetchMock`. At some point we could also create a proper interface for it or import the types (if they exist) for the `jest-mock` package.

The new `globals.d.ts` file is excluded from published builds.
2020-06-10 14:21:34 -04:00
..
atomic Add Atomic Category and Tag blocks (https://github.com/woocommerce/woocommerce-blocks/pull/2667) 2020-06-10 16:56:13 +01:00
base Add initial cart flow tests (https://github.com/woocommerce/woocommerce-blocks/pull/2678) 2020-06-10 14:21:34 -04:00
blocks Add initial cart flow tests (https://github.com/woocommerce/woocommerce-blocks/pull/2678) 2020-06-10 14:21:34 -04:00
blocks-registry Ensure all inline @todos in code are covered by issues and obsolete @todos removed. (https://github.com/woocommerce/woocommerce-blocks/pull/2557) 2020-05-26 13:31:33 -04:00
components Add Atomic SKU block (https://github.com/woocommerce/woocommerce-blocks/pull/2645) 2020-06-05 15:36:07 +01:00
data Add initial cart flow tests (https://github.com/woocommerce/woocommerce-blocks/pull/2678) 2020-06-10 14:21:34 -04:00
filters Fix blocks not being added in WP <= 5.2 (https://github.com/woocommerce/woocommerce-blocks/pull/2001) 2020-03-26 13:39:54 +01:00
hocs Migrate REST API usage to the Store API (https://github.com/woocommerce/woocommerce-blocks/pull/2282) 2020-04-24 14:36:47 +01:00
icons Ignore dashicons imports (https://github.com/woocommerce/woocommerce-blocks/pull/2664) 2020-06-08 11:27:40 -04:00
legacy Update atomic block structure (https://github.com/woocommerce/woocommerce-blocks/pull/2587) 2020-05-29 14:49:56 +01:00
middleware Fix X-WC-Store-API-Nonce updates (https://github.com/woocommerce/woocommerce-blocks/pull/2429) 2020-05-08 10:39:03 -04:00
module_replacements Ignore dashicons imports (https://github.com/woocommerce/woocommerce-blocks/pull/2664) 2020-06-08 11:27:40 -04:00
payment-method-extensions/payment-methods Ensure all inline @todos in code are covered by issues and obsolete @todos removed. (https://github.com/woocommerce/woocommerce-blocks/pull/2557) 2020-05-26 13:31:33 -04:00
previews Single Product Block Edit Mode (https://github.com/woocommerce/woocommerce-blocks/pull/2577) 2020-05-28 12:41:10 +01:00
settings Expand Feature flags (https://github.com/woocommerce/woocommerce-blocks/pull/2591) 2020-06-05 20:13:51 +01:00
shared/context Add Inner Block Rendering and Atomic Block Styles (https://github.com/woocommerce/woocommerce-blocks/pull/2607) 2020-06-05 13:18:16 +01:00
type-defs Audit payment method interface API (https://github.com/woocommerce/woocommerce-blocks/pull/2622) 2020-06-05 11:20:05 -04:00
utils Accept object parameters in renderFrontend util (https://github.com/woocommerce/woocommerce-blocks/pull/2567) 2020-05-27 11:11:30 +01:00
index.js Give Woo Icon special treatment by making it a component (https://github.com/woocommerce/woocommerce-blocks/pull/1702) 2020-02-10 14:24:02 +01:00