@faststore/core 4.11.1-dev.0 → 4.11.1-dev.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/.turbo/turbo-generate.log +3 -3
- package/.turbo/turbo-test.log +161 -152
- package/@generated/graphql.ts +0 -1
- package/@generated/schema.graphql +0 -3
- package/CHANGELOG.md +6 -0
- package/package.json +6 -6
- package/src/server/index.ts +6 -4
- package/test/server/storeDirectives.test.ts +89 -0
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
|
|
2
|
-
> @faststore/core@4.11.0 generate /home/runner/work/faststore/faststore/packages/core
|
|
2
|
+
> @faststore/core@4.11.1-dev.0 generate /home/runner/work/faststore/faststore/packages/core
|
|
3
3
|
> pnpm run gen-types && pnpm run cache-graphql
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
> @faststore/core@4.11.0 gen-types /home/runner/work/faststore/faststore/packages/core
|
|
6
|
+
> @faststore/core@4.11.1-dev.0 gen-types /home/runner/work/faststore/faststore/packages/core
|
|
7
7
|
> node ../cli/bin/run generate-types .
|
|
8
8
|
|
|
9
9
|
[33m[STARTED][39m Parse Configuration
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
[32m[COMPLETED][39m Generate to @generated/
|
|
20
20
|
[32m[COMPLETED][39m Generate outputs
|
|
21
21
|
|
|
22
|
-
> @faststore/core@4.11.0 cache-graphql /home/runner/work/faststore/faststore/packages/core
|
|
22
|
+
> @faststore/core@4.11.1-dev.0 cache-graphql /home/runner/work/faststore/faststore/packages/core
|
|
23
23
|
> node ../cli/bin/run cache-graphql --config=./discovery.config.default.js --queries=./@generated/persisted-documents.json
|
|
24
24
|
|
|
25
25
|
[Info] - Config file location: /home/runner/work/faststore/faststore/packages/core/discovery.config.default.js
|
package/.turbo/turbo-test.log
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
> @faststore/core@4.11.0 test /home/runner/work/faststore/faststore/packages/core
|
|
2
|
+
> @faststore/core@4.11.1-dev.0 test /home/runner/work/faststore/faststore/packages/core
|
|
3
3
|
> vitest run
|
|
4
4
|
|
|
5
5
|
|
|
@@ -7,27 +7,26 @@
|
|
|
7
7
|
|
|
8
8
|
Not implemented: navigation to another Document
|
|
9
9
|
Not implemented: navigation to another Document
|
|
10
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/ui/useScrollRestoration.browser.test.ts [2m([22m[2m43 tests[22m[2m)[22m[33m 1055[2mms[22m[39m
|
|
11
10
|
Browserslist: browsers data (caniuse-lite) is 9 months old. Please run:
|
|
12
11
|
npx update-browserslist-db@latest
|
|
13
12
|
Why you should do it regularly: https://github.com/browserslist/update-db#readme
|
|
14
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
[33m[2m✓[22m[39m
|
|
18
|
-
|
|
19
|
-
[33m[2m✓[22m[39m
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
24
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/OrganizationDrawer.browser.test.tsx [2m([22m[2m10 tests[22m[2m)[22m[33m
|
|
25
|
-
[33m[2m✓[22m[39m renders the menu view with contract details and manage footer [33m
|
|
26
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/
|
|
27
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
28
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
29
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
30
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
13
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/ui/useScrollRestoration.browser.test.ts [2m([22m[2m43 tests[22m[2m)[22m[33m 1054[2mms[22m[39m
|
|
14
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/cards/MyAccountListCards.browser.test.tsx [2m([22m[2m16 tests[22m[2m)[22m[33m 2269[2mms[22m[39m
|
|
15
|
+
[33m[2m✓[22m[39m shows the tab bar and renders Personal cards by default [33m 916[2mms[22m[39m
|
|
16
|
+
[33m[2m✓[22m[39m paginates when there are more than 25 cards [33m 353[2mms[22m[39m
|
|
17
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/ContractSwitcher.browser.test.tsx [2m([22m[2m22 tests[22m[2m)[22m[33m 3227[2mms[22m[39m
|
|
18
|
+
[33m[2m✓[22m[39m shows an error state when the list fails to load [33m 710[2mms[22m[39m
|
|
19
|
+
[33m[2m✓[22m[39m requires selecting a contract before Confirm is enabled, then switches (REQ-03) [33m 426[2mms[22m[39m
|
|
20
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/BuyingPolicyAlert.browser.test.tsx [2m([22m[2m13 tests[22m[2m)[22m[33m 2121[2mms[22m[39m
|
|
21
|
+
[33m[2m✓[22m[39m opens the reject confirmation modal with the default English copy [33m 773[2mms[22m[39m
|
|
22
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/ui/RichText/RichText.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m 246[2mms[22m[39m
|
|
23
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/OrganizationDrawer.browser.test.tsx [2m([22m[2m10 tests[22m[2m)[22m[33m 1590[2mms[22m[39m
|
|
24
|
+
[33m[2m✓[22m[39m renders the menu view with contract details and manage footer [33m 871[2mms[22m[39m
|
|
25
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/product/usePageProductsQuery.browser.test.ts [2m([22m[2m9 tests[22m[2m)[22m[32m 128[2mms[22m[39m
|
|
26
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/CartRecommendationShelf/CartRecommendationShelf.browser.test.tsx [2m([22m[2m13 tests[22m[2m)[22m[32m 126[2mms[22m[39m
|
|
27
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/localization/useBindingSelector.browser.test.tsx [2m([22m[2m9 tests[22m[2m)[22m[32m 58[2mms[22m[39m
|
|
28
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/reconcileSessionLocale.browser.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m 15[2mms[22m[39m
|
|
29
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/ui/ProductGallery/GalleryPageHeightLock.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m 95[2mms[22m[39m
|
|
31
30
|
[90mstderr[2m | test/components/RecommendationShelf/RecommendationShelf.browser.test.tsx
|
|
32
31
|
[22m[39mError in optimistic validation: TypeError: Failed to parse URL from /api/graphql?operationName=ValidateCartMutation&operationHash=3c71b0d3fc2bade14df68abfa271858beb361b12
|
|
33
32
|
[90m at node:internal/deps/undici/undici:16416:13[39m
|
|
@@ -57,11 +56,22 @@ Browserslist: browsers data (caniuse-lite) is 9 months old. Please run:
|
|
|
57
56
|
[90mstderr[2m | test/components/RecommendationShelf/RecommendationShelf.browser.test.tsx[2m > [22m[2mRecommendationShelf[2m > [22m[2mrenders nothing when there is an error
|
|
58
57
|
[22m[39mError fetching recommendations [90mundefined[39m boom for campaign vrn:recommendations:acc:rec-top-items-v2:campaign-1
|
|
59
58
|
|
|
60
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/RecommendationShelf/RecommendationShelf.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m
|
|
61
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
62
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
63
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/
|
|
64
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
59
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/RecommendationShelf/RecommendationShelf.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m 72[2mms[22m[39m
|
|
60
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/recommendations/useRecommendationShelf.browser.test.tsx [2m([22m[2m12 tests[22m[2m)[22m[32m 46[2mms[22m[39m
|
|
61
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/CartSidebar/CartSidebar.browser.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m 54[2mms[22m[39m
|
|
62
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/product/useProductQuery.browser.test.ts [2m([22m[2m5 tests[22m[2m)[22m[33m 346[2mms[22m[39m
|
|
63
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/getInitialSession.browser.test.ts [2m([22m[2m7 tests[22m[2m)[22m[32m 8[2mms[22m[39m
|
|
64
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrderDetails.browser.test.tsx [2m([22m[2m4 tests[22m[2m)[22m[32m 109[2mms[22m[39m
|
|
65
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/navigation/Navbar.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 85[2mms[22m[39m
|
|
66
|
+
[90mstderr[2m | test/sdk/session/validateSession.browser.test.ts
|
|
67
|
+
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
68
|
+
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
69
|
+
at validateCart [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/index.ts:124:9[90m)[39m
|
|
70
|
+
at onValidate [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/useStore.ts:18:20[90m)[39m
|
|
71
|
+
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
72
|
+
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
73
|
+
|
|
74
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/validateSession.browser.test.ts [2m([22m[2m9 tests[22m[2m)[22m[32m 19[2mms[22m[39m
|
|
65
75
|
[90mstderr[2m | test/pages/password-protection.browser.test.tsx[2m > [22m[2mPasswordProtectionLogin[2m > [22m[2mposts the password and redirects to the requested return path
|
|
66
76
|
[22m[39mWarning: An update to PasswordProtectionLogin inside a test was not wrapped in act(...).
|
|
67
77
|
|
|
@@ -195,14 +205,6 @@ act(() => {
|
|
|
195
205
|
This ensures that you're testing the behavior the user would see in the browser. Learn more at https://reactjs.org/link/wrap-tests-with-act
|
|
196
206
|
at PasswordProtectionLogin (/home/runner/work/faststore/faststore/packages/core/src/pages/password-protection/index.tsx:19:69)
|
|
197
207
|
|
|
198
|
-
[90mstderr[2m | test/sdk/session/validateSession.browser.test.ts
|
|
199
|
-
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
200
|
-
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
201
|
-
at validateCart [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/index.ts:124:9[90m)[39m
|
|
202
|
-
at onValidate [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/useStore.ts:18:20[90m)[39m
|
|
203
|
-
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
204
|
-
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
205
|
-
|
|
206
208
|
[90mstderr[2m | test/pages/password-protection.browser.test.tsx[2m > [22m[2mPasswordProtectionLogin[2m > [22m[2mshows service unavailable when the response is not a login payload
|
|
207
209
|
[22m[39mWarning: An update to PasswordProtectionLogin inside a test was not wrapped in act(...).
|
|
208
210
|
|
|
@@ -299,12 +301,10 @@ act(() => {
|
|
|
299
301
|
This ensures that you're testing the behavior the user would see in the browser. Learn more at https://reactjs.org/link/wrap-tests-with-act
|
|
300
302
|
at PasswordProtectionLogin (/home/runner/work/faststore/faststore/packages/core/src/pages/password-protection/index.tsx:19:69)
|
|
301
303
|
|
|
302
|
-
[32m✓[39m [30m[46m browser [49m[39m test/pages/password-protection.browser.test.tsx [2m([22m[2m6 tests[22m[2m)[22m[33m
|
|
303
|
-
[33m[2m✓[22m[39m renders the password protection form [33m
|
|
304
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
305
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
306
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/useSwitchContract.browser.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 44[2mms[22m[39m
|
|
307
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/OrganizationDrawerFooter.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m 281[2mms[22m[39m
|
|
304
|
+
[32m✓[39m [30m[46m browser [49m[39m test/pages/password-protection.browser.test.tsx [2m([22m[2m6 tests[22m[2m)[22m[33m 751[2mms[22m[39m
|
|
305
|
+
[33m[2m✓[22m[39m renders the password protection form [33m 310[2mms[22m[39m
|
|
306
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/OrganizationDrawerFooter.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[33m 464[2mms[22m[39m
|
|
307
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/useSwitchContract.browser.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 37[2mms[22m[39m
|
|
308
308
|
[90mstderr[2m | test/components/cms/RenderSections.browser.test.tsx
|
|
309
309
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
310
310
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -313,9 +313,9 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
313
313
|
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
314
314
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
315
315
|
|
|
316
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/cms/RenderSections.browser.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m
|
|
317
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
318
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
316
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/cms/RenderSections.browser.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m 66[2mms[22m[39m
|
|
317
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/navigation/NavbarSlider.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 33[2mms[22m[39m
|
|
318
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/product/usePageProductsQuery.deliveryPromise.browser.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 27[2mms[22m[39m
|
|
319
319
|
[90mstderr[2m | test/sdk/localization/store-url.browser.test.ts
|
|
320
320
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
321
321
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -324,9 +324,10 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
324
324
|
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
325
325
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
326
326
|
|
|
327
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/useAvailableContracts.browser.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m 31[2mms[22m[39m
|
|
328
327
|
[32m✓[39m [30m[46m browser [49m[39m test/sdk/localization/store-url.browser.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
329
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
328
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/useAvailableContracts.browser.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m 29[2mms[22m[39m
|
|
329
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/Menu.browser.test.tsx [2m([22m[2m6 tests[22m[2m)[22m[32m 246[2mms[22m[39m
|
|
330
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/templates/SearchPage/SearchWrapper.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 22[2mms[22m[39m
|
|
330
331
|
[90mstderr[2m | test/sdk/session/refreshTokenRoute.browser.test.ts
|
|
331
332
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
332
333
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -335,13 +336,12 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
335
336
|
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
336
337
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
337
338
|
|
|
338
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/templates/SearchPage/SearchWrapper.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 23[2mms[22m[39m
|
|
339
339
|
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/refreshTokenRoute.browser.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 6[2mms[22m[39m
|
|
340
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/recommendations/useRecommendationShelf.sessionFallback.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
341
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/
|
|
342
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/
|
|
343
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/
|
|
344
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/changeContractToken.browser.test.ts [2m([22m[2m9 tests[22m[2m)[22m[32m
|
|
340
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/recommendations/useRecommendationShelf.sessionFallback.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 125[2mms[22m[39m
|
|
341
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountListQuotes.browser.test.tsx [2m([22m[2m4 tests[22m[2m)[22m[32m 101[2mms[22m[39m
|
|
342
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/navigation/NavbarAccountArea.browser.test.tsx [2m([22m[2m4 tests[22m[2m)[22m[32m 46[2mms[22m[39m
|
|
343
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/CartRecommendationShelf/CartRecommendationProductCard.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 36[2mms[22m[39m
|
|
344
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/changeContractToken.browser.test.ts [2m([22m[2m9 tests[22m[2m)[22m[32m 16[2mms[22m[39m
|
|
345
345
|
[90mstderr[2m | test/components/account/doLogout.browser.test.ts
|
|
346
346
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
347
347
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -350,11 +350,11 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
350
350
|
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
351
351
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
352
352
|
|
|
353
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/doLogout.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
354
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/OrganizationDrawerHeader.browser.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m
|
|
355
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/product/useProductNotFoundRedirect.browser.test.ts [2m([22m[2m7 tests[22m[2m)[22m[32m
|
|
356
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/useRefreshToken.browser.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m
|
|
357
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/ui/LocalizationButton.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m
|
|
353
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/doLogout.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m 55[2mms[22m[39m
|
|
354
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/OrganizationDrawerHeader.browser.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m 264[2mms[22m[39m
|
|
355
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/product/useProductNotFoundRedirect.browser.test.ts [2m([22m[2m7 tests[22m[2m)[22m[32m 25[2mms[22m[39m
|
|
356
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/useRefreshToken.browser.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 133[2mms[22m[39m
|
|
357
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/ui/LocalizationButton.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 33[2mms[22m[39m
|
|
358
358
|
[90mstderr[2m | test/sdk/account/clearPersistedSessionState.browser.test.ts
|
|
359
359
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
360
360
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -363,14 +363,15 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
363
363
|
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
364
364
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
365
365
|
|
|
366
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
367
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
368
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrderDelivery.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
369
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryOptionAccordion.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
370
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrderStatus.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m
|
|
371
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountListCards.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m
|
|
372
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/region/useRegion.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
373
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrdersList.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
366
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/clearPersistedSessionState.browser.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 15[2mms[22m[39m
|
|
367
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/OrganizationSignInButton.browser.test.tsx [2m([22m[2m4 tests[22m[2m)[22m[32m 240[2mms[22m[39m
|
|
368
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrderDelivery.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 61[2mms[22m[39m
|
|
369
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryOptionAccordion.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 87[2mms[22m[39m
|
|
370
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrderStatus.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 98[2mms[22m[39m
|
|
371
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountListCards.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 66[2mms[22m[39m
|
|
372
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/region/useRegion.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m 19[2mms[22m[39m
|
|
373
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrdersList.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 20[2mms[22m[39m
|
|
374
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/SummaryCard.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 69[2mms[22m[39m
|
|
374
375
|
[90mstderr[2m | test/sdk/session/sessionStore.browser.test.ts
|
|
375
376
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
376
377
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -379,10 +380,9 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
379
380
|
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
380
381
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
381
382
|
|
|
382
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/sessionStore.browser.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
383
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/
|
|
384
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
385
|
-
[32m✓[39m [30m[46m browser [49m[39m test/utils/shouldBypassRefreshToken.browser.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
383
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/sessionStore.browser.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m 6[2mms[22m[39m
|
|
384
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryOptionAccordionDeliveryInfo.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m 32[2mms[22m[39m
|
|
385
|
+
[32m✓[39m [30m[46m browser [49m[39m test/utils/shouldBypassRefreshToken.browser.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 5[2mms[22m[39m
|
|
386
386
|
[90mstderr[2m | test/sdk/account/refreshToken.browser.test.ts
|
|
387
387
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
388
388
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -392,16 +392,17 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
392
392
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
393
393
|
|
|
394
394
|
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/refreshToken.browser.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
395
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/reconcileSessionLocale.disabled.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
396
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/StatusCard.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
397
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryCard.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
398
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryOptionAccordionProducts.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
399
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/skeletons/ProductGridSkeleton.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
400
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
401
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
402
|
-
[32m✓[39m [30m[43m node [49m[39m test/server/password-protection-service.test.ts [2m([22m[2m22 tests[22m[2m)[22m[32m
|
|
403
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/FilterFacetPendingApproval.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
404
|
-
[32m✓[39m [30m[43m node [49m[39m test/server/content/service.test.ts [2m([22m[2m27 tests[22m[2m)[22m[32m
|
|
395
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/reconcileSessionLocale.disabled.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
396
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/StatusCard.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 81[2mms[22m[39m
|
|
397
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryCard.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m 39[2mms[22m[39m
|
|
398
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryOptionAccordionProducts.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m 33[2mms[22m[39m
|
|
399
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/skeletons/ProductGridSkeleton.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 30[2mms[22m[39m
|
|
400
|
+
[32m✓[39m [30m[43m node [49m[39m test/pages/api/switch-contract.test.ts [2m([22m[2m61 tests[22m[2m)[22m[32m 131[2mms[22m[39m
|
|
401
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/localization/bindingPaths.test.ts [2m([22m[2m71 tests[22m[2m)[22m[32m 21[2mms[22m[39m
|
|
402
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/password-protection-service.test.ts [2m([22m[2m22 tests[22m[2m)[22m[32m 27[2mms[22m[39m
|
|
403
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/FilterFacetPendingApproval.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m 161[2mms[22m[39m
|
|
404
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/content/service.test.ts [2m([22m[2m27 tests[22m[2m)[22m[32m 32[2mms[22m[39m
|
|
405
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/localization/useBindingSelector.test.tsx [2m([22m[2m22 tests[22m[2m)[22m[32m 9[2mms[22m[39m
|
|
405
406
|
[90mstderr[2m | test/sdk/deliveryPromise/provider.effect.test.tsx[2m > [22m[2mDeliveryPromiseProvider pickup fetch[2m > [22m[2mclears the loading flag after a failed request and retries on the next update
|
|
406
407
|
[22m[39mFailed to fetch pickup points: Error: network
|
|
407
408
|
at [90m/home/runner/work/faststore/faststore/packages/core/[39mtest/sdk/deliveryPromise/provider.effect.test.tsx:250:30
|
|
@@ -428,6 +429,7 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
428
429
|
at trace (file:///home/runner/work/faststore/faststore/node_modules/[4m.pnpm[24m/vitest@4.0.18_@opentelemetry+api@1.9.0_@types+node@20.19.13_jiti@2.6.1_jsdom@27.4.0_sas_13be941c57d55f08f06eeaf1c180ddfe/node_modules/[4mvitest[24m/dist/chunks/test.B8ej_ZHS.js:239:21)
|
|
429
430
|
at runTest (file:///home/runner/work/faststore/faststore/node_modules/[4m.pnpm[24m/@vitest+runner@4.0.18/node_modules/[4m@vitest/runner[24m/dist/index.js:1653:12)
|
|
430
431
|
|
|
432
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/deliveryPromise/provider.effect.test.tsx [2m([22m[2m9 tests[22m[2m)[22m[32m 73[2mms[22m[39m
|
|
431
433
|
[90mstderr[2m | test/pages/api/graphql.test.ts[2m > [22m[2m/api/graphql error status propagation[2m > [22m[2mpropagates the upstream 400 from a wrapped BadRequestError instead of 500
|
|
432
434
|
[22m[39mGraphql execution returned with error: [
|
|
433
435
|
{
|
|
@@ -440,7 +442,6 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
440
442
|
[90mstderr[2m | test/pages/api/graphql.test.ts[2m > [22m[2m/api/graphql error status propagation[2m > [22m[2mpropagates UnauthorizedError status
|
|
441
443
|
[22m[39mGraphql execution returned with error: [ { message: [32m'nope'[39m, status: [33m401[39m, type: [32m'UnauthorizedError'[39m } ]
|
|
442
444
|
|
|
443
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/deliveryPromise/provider.effect.test.tsx [2m([22m[2m9 tests[22m[2m)[22m[32m 62[2mms[22m[39m
|
|
444
445
|
[90mstderr[2m | test/pages/api/graphql.test.ts[2m > [22m[2m/api/graphql error status propagation[2m > [22m[2mpropagates ForbiddenError status
|
|
445
446
|
[22m[39mGraphql execution returned with error: [ { message: [32m'nope'[39m, status: [33m403[39m, type: [32m'ForbiddenError'[39m } ]
|
|
446
447
|
|
|
@@ -570,12 +571,11 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
570
571
|
extensions: { status: [33m401[39m, type: [32m'UnauthorizedError'[39m }
|
|
571
572
|
}
|
|
572
573
|
|
|
573
|
-
[32m✓[39m [30m[43m node [49m[39m test/pages/api/graphql.test.ts [2m([22m[2m30 tests[22m[2m)[22m[32m
|
|
574
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
575
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
576
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
577
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/
|
|
578
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/localization/bindingSelector.test.ts [2m([22m[2m18 tests[22m[2m)[22m[32m 6[2mms[22m[39m
|
|
574
|
+
[32m✓[39m [30m[43m node [49m[39m test/pages/api/graphql.test.ts [2m([22m[2m30 tests[22m[2m)[22m[32m 32[2mms[22m[39m
|
|
575
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/match-url.test.ts [2m([22m[2m10 tests[22m[2m)[22m[32m 9[2mms[22m[39m
|
|
576
|
+
[32m✓[39m [30m[43m node [49m[39m test/pages/api/unlock.test.ts [2m([22m[2m15 tests[22m[2m)[22m[32m 113[2mms[22m[39m
|
|
577
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/session/syncSalesChannelFromOrderForm.test.ts [2m([22m[2m14 tests[22m[2m)[22m[32m 9[2mms[22m[39m
|
|
578
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/localization/bindingSelector.test.ts [2m([22m[2m18 tests[22m[2m)[22m[32m 8[2mms[22m[39m
|
|
579
579
|
[90mstderr[2m | test/components/search/SearchInputComponent.test.tsx
|
|
580
580
|
[22m[39mWarning: forwardRef render functions accept exactly two parameters: props and ref. Did you forget to use the ref parameter?
|
|
581
581
|
|
|
@@ -639,96 +639,105 @@ Warning: React does not recognize the `providerProps` prop on a DOM element. If
|
|
|
639
639
|
at Suspense
|
|
640
640
|
at Wrapper (/home/runner/work/faststore/faststore/packages/core/test/components/search/SearchInputComponent.test.tsx:106:20)
|
|
641
641
|
|
|
642
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/search/SearchInputComponent.test.tsx [2m([22m[2m6 tests[22m[2m)[22m[32m
|
|
643
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/refreshToken.test.ts [2m([22m[2m21 tests[22m[2m)[22m[32m
|
|
644
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountListQuotesTable.test.tsx [2m([22m[2m15 tests[22m[2m)[22m[
|
|
645
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/search/useSearchHistory.test.ts [2m([22m[2m13 tests[22m[2m)[22m[32m
|
|
642
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/search/SearchInputComponent.test.tsx [2m([22m[2m6 tests[22m[2m)[22m[32m 70[2mms[22m[39m
|
|
643
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/refreshToken.test.ts [2m([22m[2m21 tests[22m[2m)[22m[32m 13[2mms[22m[39m
|
|
644
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountListQuotesTable.test.tsx [2m([22m[2m15 tests[22m[2m)[22m[33m 333[2mms[22m[39m
|
|
645
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/search/useSearchHistory.test.ts [2m([22m[2m13 tests[22m[2m)[22m[32m 35[2mms[22m[39m
|
|
646
646
|
[90mstderr[2m | test/pages/pvt/account/cards/index.test.ts[2m > [22m[2mCards page getServerSideProps[2m > [22m[2mredirects to /pvt/account/403 when the query fails with 401/403
|
|
647
647
|
[22m[39m{ extensions: { status: [33m401[39m } }
|
|
648
648
|
|
|
649
649
|
[90mstderr[2m | test/pages/pvt/account/cards/index.test.ts[2m > [22m[2mCards page getServerSideProps[2m > [22m[2mrenders the error state (no redirect) when the query fails with a non-auth status
|
|
650
650
|
[22m[39m{ extensions: { status: [33m502[39m } }
|
|
651
651
|
|
|
652
|
-
[32m✓[39m [30m[43m node [49m[39m test/pages/pvt/account/cards/index.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m
|
|
653
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
654
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
655
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/
|
|
656
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountListQuotes.test.tsx [2m([22m[2m11 tests[22m[2m)[22m[33m 791[2mms[22m[39m
|
|
657
|
-
[33m[2m✓[22m[39m navigates with the search term on blur [33m 358[2mms[22m[39m
|
|
658
|
-
[33m[2m✓[22m[39m navigates without a label param when the search is cleared [33m 357[2mms[22m[39m
|
|
652
|
+
[32m✓[39m [30m[43m node [49m[39m test/pages/pvt/account/cards/index.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m 7[2mms[22m[39m
|
|
653
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/quoteFilters.test.ts [2m([22m[2m26 tests[22m[2m)[22m[32m 20[2mms[22m[39m
|
|
654
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/productJsonLd.test.ts [2m([22m[2m36 tests[22m[2m)[22m[32m 7[2mms[22m[39m
|
|
655
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/cookieCacheBusting.test.ts [2m([22m[2m10 tests[22m[2m)[22m[32m 9[2mms[22m[39m
|
|
659
656
|
[32m✓[39m [30m[43m node [49m[39m test/experimental/myAccountCmsServerSideProps.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 7[2mms[22m[39m
|
|
660
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
661
|
-
|
|
657
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountListQuotes.test.tsx [2m([22m[2m11 tests[22m[2m)[22m[33m 811[2mms[22m[39m
|
|
658
|
+
[33m[2m✓[22m[39m navigates with the search term on blur [33m 359[2mms[22m[39m
|
|
659
|
+
[33m[2m✓[22m[39m navigates without a label param when the search is cleared [33m 356[2mms[22m[39m
|
|
660
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/clearCookies.test.ts [2m([22m[2m20 tests[22m[2m)[22m[32m 16[2mms[22m[39m
|
|
661
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/multipleTemplates.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m 5[2mms[22m[39m
|
|
662
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/orderEntry/useOrderEntryOperation.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m 36[2mms[22m[39m
|
|
662
663
|
[90mstderr[2m | test/sdk/account/useSetPassword.test.ts[2m > [22m[2museSetPassword[2m > [22m[2mmaps wrongcredentials error responses to the existing message
|
|
663
664
|
[22m[39mSet password request failed: Bad Request
|
|
664
665
|
|
|
665
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/useSetPassword.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m
|
|
666
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
667
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
668
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountQuotesFilterSlider.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m 90[2mms[22m[39m
|
|
666
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/useSetPassword.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m 36[2mms[22m[39m
|
|
667
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/localization/localizeRedirectDestination.test.ts [2m([22m[2m11 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
668
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountQuotesFilterSlider.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m 126[2mms[22m[39m
|
|
669
669
|
[32m✓[39m [30m[43m node [49m[39m test/utils/localization/hreflang.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m 5[2mms[22m[39m
|
|
670
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountQuotesStatusSelector.test.tsx [2m([22m[2m14 tests[22m[2m)[22m[32m
|
|
670
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountQuotesStatusSelector.test.tsx [2m([22m[2m14 tests[22m[2m)[22m[32m 122[2mms[22m[39m
|
|
671
671
|
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/getMyAccountRoutes.test.ts [2m([22m[2m13 tests[22m[2m)[22m[32m 5[2mms[22m[39m
|
|
672
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountQuotesSelectedTags.test.tsx [2m([22m[2m10 tests[22m[2m)[22m[32m
|
|
673
|
-
[32m✓[39m [30m[43m node [49m[39m test/server/content/promiseCache.test.ts [2m([22m[2m10 tests[22m[2m)[22m[32m 9[2mms[22m[39m
|
|
672
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountQuotesSelectedTags.test.tsx [2m([22m[2m10 tests[22m[2m)[22m[32m 96[2mms[22m[39m
|
|
674
673
|
[32m✓[39m [30m[43m node [49m[39m test/server/cms/index.test.ts [2m([22m[2m7 tests[22m[2m)[22m[32m 8[2mms[22m[39m
|
|
675
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
676
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/
|
|
677
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/orderEntry/
|
|
678
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
674
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/content/promiseCache.test.ts [2m([22m[2m10 tests[22m[2m)[22m[32m 12[2mms[22m[39m
|
|
675
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/redirects/index.test.ts [2m([22m[2m7 tests[22m[2m)[22m[32m 41[2mms[22m[39m
|
|
676
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/orderEntry/useOrderEntryUpload.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m 46[2mms[22m[39m
|
|
677
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/orderEntry/useOrderEntry.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m 41[2mms[22m[39m
|
|
678
|
+
[32m✓[39m [30m[43m node [49m[39m test/proxy.localization.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 35[2mms[22m[39m
|
|
679
679
|
[32m✓[39m [30m[43m node [49m[39m test/utils/trustedForwardedHost.test.ts [2m([22m[2m36 tests[22m[2m)[22m[32m 7[2mms[22m[39m
|
|
680
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/account/orders/getDeliveryOptionLabel.test.ts [2m([22m[2m21 tests[22m[2m)[22m[32m
|
|
681
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
682
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
683
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/productJsonLdRendering.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m
|
|
684
|
-
[32m✓[39m [30m[43m node [49m[39m test/server/index.test.ts [2m([22m[2m7 tests[22m[2m)[22m[33m
|
|
680
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/account/orders/getDeliveryOptionLabel.test.ts [2m([22m[2m21 tests[22m[2m)[22m[32m 6[2mms[22m[39m
|
|
681
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/cms/myAccountDefaultSections.test.ts [2m([22m[2m9 tests[22m[2m)[22m[32m 6[2mms[22m[39m
|
|
682
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/graphql/retryPolicy.test.ts [2m([22m[2m18 tests[22m[2m)[22m[32m 15[2mms[22m[39m
|
|
683
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/productJsonLdRendering.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m 8[2mms[22m[39m
|
|
684
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/index.test.ts [2m([22m[2m7 tests[22m[2m)[22m[33m 694[2mms[22m[39m
|
|
685
|
+
[33m[2m✓[22m[39m should handle options and execute [33m 337[2mms[22m[39m
|
|
686
|
+
[32m✓[39m [30m[43m node [49m[39m test/proxy.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 16[2mms[22m[39m
|
|
685
687
|
[32m✓[39m [30m[43m node [49m[39m test/sdk/analytics/useStartRecommendationSession.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m 32[2mms[22m[39m
|
|
686
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
687
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
688
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
689
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
690
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
691
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/account/orders/StatusCard.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 17[2mms[22m[39m
|
|
688
|
+
[32m✓[39m [30m[43m node [49m[39m test/pages/api/logout.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 27[2mms[22m[39m
|
|
689
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/shouldBypassRefreshToken.test.ts [2m([22m[2m14 tests[22m[2m)[22m[32m 6[2mms[22m[39m
|
|
690
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/orderEntry/useOrderFormItems.test.ts [2m([22m[2m7 tests[22m[2m)[22m[32m 32[2mms[22m[39m
|
|
691
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/webops-api.test.ts [2m([22m[2m9 tests[22m[2m)[22m[32m 12[2mms[22m[39m
|
|
692
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/account/orders/StatusCard.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 15[2mms[22m[39m
|
|
692
693
|
[32m✓[39m [30m[43m node [49m[39m test/sdk/deliveryPromise/queries.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 6[2mms[22m[39m
|
|
693
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/localization/store-url.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m
|
|
694
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/cart/waitForSessionValidated.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m
|
|
695
|
-
[32m✓[39m [30m[43m node [49m[39m test/server/cms/global.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m
|
|
696
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/deliveryPromise/provider.test.ts [2m([22m[2m11 tests[22m[2m)[22m[32m
|
|
697
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/auth/useAuth.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
[32m
|
|
701
|
-
[32m
|
|
702
|
-
[32m
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
694
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/localization/store-url.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
695
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/cart/waitForSessionValidated.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 8[2mms[22m[39m
|
|
696
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/cms/global.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 5[2mms[22m[39m
|
|
697
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/deliveryPromise/provider.test.ts [2m([22m[2m11 tests[22m[2m)[22m[32m 5[2mms[22m[39m
|
|
698
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/auth/useAuth.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 35[2mms[22m[39m
|
|
699
|
+
[90mstderr[2m | test/server/storeDirectives.test.ts[2m > [22m[2mstore directives through the core server[2m > [22m[2mapplies @auth from a store field and validates the session once
|
|
700
|
+
[22m[39mhttps://storeframework.vtexcommercestable.com.br/api/vtexid/credential/validate {
|
|
701
|
+
headers: { [32m'content-type'[39m: [32m'application/json'[39m, [32m'X-FORWARDED-HOST'[39m: [32m''[39m },
|
|
702
|
+
body: [32m'[redacted]'[39m,
|
|
703
|
+
method: [32m'POST'[39m
|
|
704
|
+
} { status: [33m401[39m, statusText: [32m'Unauthorized'[39m, headers: {} }
|
|
705
|
+
|
|
706
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/storeDirectives.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m 80[2mms[22m[39m
|
|
707
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/getRequestHostname.test.ts [2m([22m[2m12 tests[22m[2m)[22m[32m 10[2mms[22m[39m
|
|
708
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/rootSpan.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 33[2mms[22m[39m
|
|
709
|
+
[32m✓[39m [30m[43m node [49m[39m test/pages/api/preview.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m 7[2mms[22m[39m
|
|
710
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/search/SearchInput.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
711
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/account/Layout.test.tsx [2m([22m[2m6 tests[22m[2m)[22m[32m 45[2mms[22m[39m
|
|
712
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/validateSessionRefreshToken.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m 5[2mms[22m[39m
|
|
713
|
+
[32m✓[39m [30m[43m node [49m[39m test/pages/pvt/account/403.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
714
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/region/useRegion.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m 19[2mms[22m[39m
|
|
706
715
|
[32m✓[39m [30m[43m node [49m[39m test/sdk/recommendations/vrn.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
707
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/retry.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m
|
|
708
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/getIsB2BBuyer.test.ts [2m([22m[2m7 tests[22m[2m)[22m[32m
|
|
709
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/recommendations/useRecommendationUserId.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 176[2mms[22m[39m
|
|
716
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/retry.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 12[2mms[22m[39m
|
|
717
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/getIsB2BBuyer.test.ts [2m([22m[2m7 tests[22m[2m)[22m[32m 5[2mms[22m[39m
|
|
710
718
|
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/getB2BSessionClaims.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
711
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
712
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/
|
|
713
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
714
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
715
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
716
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
719
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/recommendations/useRecommendationUserId.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 185[2mms[22m[39m
|
|
720
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/userOrderStatus.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 5[2mms[22m[39m
|
|
721
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/unlockResponse.test.ts [2m([22m[2m11 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
722
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/recommendations/useRecommendations.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
723
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/account/OrganizationDrawerBody.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 41[2mms[22m[39m
|
|
724
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/deliveryPromise/reducer.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
725
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountQuoteStatusBadge.test.tsx [2m([22m[2m4 tests[22m[2m)[22m[32m 36[2mms[22m[39m
|
|
717
726
|
[32m✓[39m [30m[43m node [49m[39m test/utils/isLocalHost.test.ts [2m([22m[2m7 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
718
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/session/toSessionInput.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m
|
|
719
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/account/orders/getOrderTotalLabel.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m
|
|
720
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/account/orders/listOrdersLabels.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
721
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
722
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
723
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/session/isSignInAreaResolved.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m
|
|
727
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/session/toSessionInput.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
728
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/account/orders/getOrderTotalLabel.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
729
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/account/orders/listOrdersLabels.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
730
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/auth/ProfileChallenge.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 31[2mms[22m[39m
|
|
731
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/getCookie.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
732
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/session/isSignInAreaResolved.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
724
733
|
[32m✓[39m [30m[43m node [49m[39m test/utils/filterChannel.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
725
734
|
[32m✓[39m [30m[43m node [49m[39m test/sdk/analytics/utils.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
726
|
-
[32m✓[39m [30m[43m node [49m[39m test/instrumentation.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m
|
|
735
|
+
[32m✓[39m [30m[43m node [49m[39m test/instrumentation.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
727
736
|
[32m✓[39m [30m[43m node [49m[39m test/components/account/orders/orderDetailsLabels.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m 2[2mms[22m[39m
|
|
728
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/clearPersistedSessionState.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
737
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/clearPersistedSessionState.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m 9[2mms[22m[39m
|
|
729
738
|
|
|
730
|
-
[2m Test Files [22m [1m[
|
|
731
|
-
[2m Tests [22m [1m[
|
|
732
|
-
[2m Start at [22m
|
|
733
|
-
[2m Duration [22m
|
|
739
|
+
[2m Test Files [22m [1m[32m147 passed[39m[22m[90m (147)[39m
|
|
740
|
+
[2m Tests [22m [1m[32m1251 passed[39m[22m[90m (1251)[39m
|
|
741
|
+
[2m Start at [22m 14:51:41
|
|
742
|
+
[2m Duration [22m 53.68s[2m (transform 11.67s, setup 0ms, import 48.07s, tests 19.18s, environment 64.85s)[22m
|
|
734
743
|
|
package/@generated/graphql.ts
CHANGED
|
@@ -56,7 +56,6 @@ export type Scalars = {
|
|
|
56
56
|
*/
|
|
57
57
|
FormattedVariants: { input: any; output: any; }
|
|
58
58
|
JSONObject: { input: any; output: any; }
|
|
59
|
-
/** A string or the string representation of an object (a stringified object). */
|
|
60
59
|
ObjectOrString: { input: any; output: any; }
|
|
61
60
|
/**
|
|
62
61
|
* Example:
|
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,12 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [4.11.1-dev.1](https://github.com/vtex/faststore/compare/v4.11.1-dev.0...v4.11.1-dev.1) (2026-11-04)
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
- **api:** apply [@auth](https://github.com/auth) and [@cache](https://github.com/cache)Control to store schema extensions ([#3524](https://github.com/vtex/faststore/issues/3524)) ([f6abd0d](https://github.com/vtex/faststore/commit/f6abd0d4f7312794a4195ce693526b539550275e)), closes [#3111](https://github.com/vtex/faststore/issues/3111) [/github.com/vtex/faststore/pull/3524#issuecomment-6258456970](https://github.com//github.com/vtex/faststore/pull/3524/issues/issuecomment-6258456970) [#3111](https://github.com/vtex/faststore/issues/3111) [#3063](https://github.com/vtex/faststore/issues/3063)
|
|
11
|
+
|
|
6
12
|
## [4.11.1-dev.0](https://github.com/vtex/faststore/compare/v4.11.0...v4.11.1-dev.0) (2026-11-03)
|
|
7
13
|
|
|
8
14
|
## [4.10.3-dev.1](https://github.com/vtex/faststore/compare/v4.10.3-dev.0...v4.10.3-dev.1) (2026-10-29)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@faststore/core",
|
|
3
|
-
"version": "4.11.1-dev.
|
|
3
|
+
"version": "4.11.1-dev.1",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -71,11 +71,11 @@
|
|
|
71
71
|
"style-loader": "^3.3.1",
|
|
72
72
|
"swr": "^2.2.5",
|
|
73
73
|
"use-sync-external-store": "^1.6.0",
|
|
74
|
-
"@faststore/diagnostics": "4.11.1-dev.
|
|
75
|
-
"@faststore/sdk": "4.11.1-dev.
|
|
76
|
-
"@faststore/
|
|
77
|
-
"@faststore/ui": "4.11.1-dev.
|
|
78
|
-
"@faststore/
|
|
74
|
+
"@faststore/diagnostics": "4.11.1-dev.1",
|
|
75
|
+
"@faststore/sdk": "4.11.1-dev.1",
|
|
76
|
+
"@faststore/api": "4.11.1-dev.1",
|
|
77
|
+
"@faststore/ui": "4.11.1-dev.1",
|
|
78
|
+
"@faststore/lighthouse": "4.11.1-dev.1"
|
|
79
79
|
},
|
|
80
80
|
"devDependencies": {
|
|
81
81
|
"@cypress/code-coverage": "^3.12.1",
|
package/src/server/index.ts
CHANGED
|
@@ -15,6 +15,7 @@ import {
|
|
|
15
15
|
GraphqlVtexContextFactory,
|
|
16
16
|
GraphqlVtexSchema,
|
|
17
17
|
isFastStoreError,
|
|
18
|
+
platformTypeDefs,
|
|
18
19
|
} from '@faststore/api'
|
|
19
20
|
import { OTELAPI } from '@faststore/diagnostics'
|
|
20
21
|
import { loadFilesSync } from '@graphql-tools/load-files'
|
|
@@ -57,10 +58,11 @@ function loadGeneratedSchema(): TypeSource {
|
|
|
57
58
|
}
|
|
58
59
|
|
|
59
60
|
export function getFinalAPISchema() {
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
61
|
+
// `platformTypeDefs` is the native SDL plus the directive definitions.
|
|
62
|
+
// Building `GraphqlVtexSchema()` here would run the transformers and throw
|
|
63
|
+
// the result away: this value is only merged as type definitions, and the
|
|
64
|
+
// call below applies the transformers once.
|
|
65
|
+
const finalTypeDefs = mergeTypeDefs([platformTypeDefs, loadGeneratedSchema()])
|
|
64
66
|
|
|
65
67
|
const schema = makeExecutableSchema({
|
|
66
68
|
typeDefs: finalTypeDefs,
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
import { stringifyCacheControl } from '@faststore/api'
|
|
2
|
+
import { beforeEach, describe, expect, it, vi } from 'vitest'
|
|
3
|
+
|
|
4
|
+
import { execute } from '../../src/server'
|
|
5
|
+
|
|
6
|
+
const probeResolvers = vi.hoisted(() => ({
|
|
7
|
+
Query: {
|
|
8
|
+
probeAuth: vi.fn(() => 'auth-ok'),
|
|
9
|
+
probeCache: vi.fn(() => 'cache-ok'),
|
|
10
|
+
},
|
|
11
|
+
}))
|
|
12
|
+
|
|
13
|
+
const fetchMock = vi.hoisted(() => vi.fn())
|
|
14
|
+
|
|
15
|
+
vi.mock('../../src/customizations/src/graphql/thirdParty/resolvers', () => ({
|
|
16
|
+
default: probeResolvers,
|
|
17
|
+
}))
|
|
18
|
+
|
|
19
|
+
vi.mock('isomorphic-unfetch', () => ({
|
|
20
|
+
default: (...args: unknown[]) => fetchMock(...args),
|
|
21
|
+
}))
|
|
22
|
+
|
|
23
|
+
vi.mock('@graphql-tools/load-files', () => ({
|
|
24
|
+
loadFilesSync: () => [
|
|
25
|
+
/* GraphQL */ `
|
|
26
|
+
extend type Query {
|
|
27
|
+
probeAuth: String @auth
|
|
28
|
+
probeCache: String
|
|
29
|
+
@cacheControl(scope: "private", sMaxAge: 7, staleWhileRevalidate: 11)
|
|
30
|
+
}
|
|
31
|
+
`,
|
|
32
|
+
],
|
|
33
|
+
}))
|
|
34
|
+
|
|
35
|
+
const operation = (operationName: string, query: string) => ({
|
|
36
|
+
variables: {},
|
|
37
|
+
query,
|
|
38
|
+
operation: {
|
|
39
|
+
__meta__: { operationName, operationHash: operationName },
|
|
40
|
+
},
|
|
41
|
+
})
|
|
42
|
+
|
|
43
|
+
describe('store directives through the core server', () => {
|
|
44
|
+
beforeEach(() => {
|
|
45
|
+
probeResolvers.Query.probeAuth.mockClear()
|
|
46
|
+
probeResolvers.Query.probeCache.mockClear()
|
|
47
|
+
fetchMock.mockReset()
|
|
48
|
+
fetchMock.mockResolvedValue({
|
|
49
|
+
ok: false,
|
|
50
|
+
status: 401,
|
|
51
|
+
statusText: 'Unauthorized',
|
|
52
|
+
headers: new Headers(),
|
|
53
|
+
text: async () => 'unauthorized',
|
|
54
|
+
json: async () => ({}),
|
|
55
|
+
})
|
|
56
|
+
})
|
|
57
|
+
|
|
58
|
+
it('applies @cacheControl from a store field to the response extensions', async () => {
|
|
59
|
+
const result = await execute(
|
|
60
|
+
operation('ProbeCacheQuery', 'query ProbeCacheQuery { probeCache }')
|
|
61
|
+
)
|
|
62
|
+
|
|
63
|
+
expect(result.errors).toBeUndefined()
|
|
64
|
+
expect(result.data).toEqual({ probeCache: 'cache-ok' })
|
|
65
|
+
expect(result.extensions.cacheControl).toEqual({
|
|
66
|
+
scope: 'private',
|
|
67
|
+
sMaxAge: 7,
|
|
68
|
+
staleWhileRevalidate: 11,
|
|
69
|
+
})
|
|
70
|
+
expect(
|
|
71
|
+
stringifyCacheControl(result.extensions.cacheControl ?? {}, false)
|
|
72
|
+
).toBe('private, s-maxage=7, stale-while-revalidate=11')
|
|
73
|
+
})
|
|
74
|
+
|
|
75
|
+
it('applies @auth from a store field and validates the session once', async () => {
|
|
76
|
+
const result = await execute(
|
|
77
|
+
operation('ProbeAuthQuery', 'query ProbeAuthQuery { probeAuth }')
|
|
78
|
+
)
|
|
79
|
+
|
|
80
|
+
expect(result.data).toEqual({ probeAuth: null })
|
|
81
|
+
expect(result.errors?.length).toBeGreaterThan(0)
|
|
82
|
+
expect(probeResolvers.Query.probeAuth).not.toHaveBeenCalled()
|
|
83
|
+
expect(
|
|
84
|
+
fetchMock.mock.calls.filter(([url]) =>
|
|
85
|
+
String(url).includes('/api/vtexid/credential/validate')
|
|
86
|
+
)
|
|
87
|
+
).toHaveLength(1)
|
|
88
|
+
})
|
|
89
|
+
})
|