@faststore/core 4.10.1-dev.2 → 4.10.1-dev.3
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 +121 -119
- package/CHANGELOG.md +8 -0
- package/package.json +6 -6
- package/src/server/cms/index.ts +59 -7
- package/src/server/cms/pdp.ts +10 -5
- package/src/server/cms/plp.ts +10 -5
- package/src/server/content/promiseCache.ts +68 -0
- package/src/server/content/service.ts +45 -42
- package/test/server/cms/index.test.ts +102 -9
- package/test/server/content/promiseCache.test.ts +150 -0
- package/test/server/content/service.test.ts +237 -10
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
|
|
2
|
-
> @faststore/core@4.10.1-dev.
|
|
2
|
+
> @faststore/core@4.10.1-dev.2 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.10.1-dev.
|
|
6
|
+
> @faststore/core@4.10.1-dev.2 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.10.1-dev.
|
|
22
|
+
> @faststore/core@4.10.1-dev.2 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.10.1-dev.
|
|
2
|
+
> @faststore/core@4.10.1-dev.2 test /home/runner/work/faststore/faststore/packages/core
|
|
3
3
|
> vitest run
|
|
4
4
|
|
|
5
5
|
|
|
@@ -7,24 +7,24 @@
|
|
|
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 990[2mms[22m[39m
|
|
10
11
|
Browserslist: browsers data (caniuse-lite) is 8 months old. Please run:
|
|
11
12
|
npx update-browserslist-db@latest
|
|
12
13
|
Why you should do it regularly: https://github.com/browserslist/update-db#readme
|
|
13
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
14
|
-
|
|
15
|
-
[33m[2m✓[22m[39m
|
|
16
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/cards/MyAccountListCards.browser.test.tsx [2m([22m[2m16 tests[22m[2m)[22m[33m
|
|
17
|
-
[33m[2m✓[22m[39m shows the tab bar and renders Personal cards by default [33m
|
|
18
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/BuyingPolicyAlert.browser.test.tsx [2m([22m[2m13 tests[22m[2m)[22m[33m
|
|
19
|
-
[33m[2m✓[22m[39m opens the reject confirmation modal with the default English copy [33m
|
|
20
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/ui/RichText/RichText.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m
|
|
21
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
25
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
26
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/ui/ProductGallery/GalleryPageHeightLock.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m
|
|
27
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/recommendations/useRecommendationShelf.browser.test.tsx [2m([22m[2m12 tests[22m[2m)[22m[32m 45[2mms[22m[39m
|
|
14
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/ContractSwitcher.browser.test.tsx [2m([22m[2m22 tests[22m[2m)[22m[33m 2577[2mms[22m[39m
|
|
15
|
+
[33m[2m✓[22m[39m shows an error state when the list fails to load [33m 376[2mms[22m[39m
|
|
16
|
+
[33m[2m✓[22m[39m requires selecting a contract before Confirm is enabled, then switches (REQ-03) [33m 413[2mms[22m[39m
|
|
17
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/cards/MyAccountListCards.browser.test.tsx [2m([22m[2m16 tests[22m[2m)[22m[33m 1681[2mms[22m[39m
|
|
18
|
+
[33m[2m✓[22m[39m shows the tab bar and renders Personal cards by default [33m 558[2mms[22m[39m
|
|
19
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/BuyingPolicyAlert.browser.test.tsx [2m([22m[2m13 tests[22m[2m)[22m[33m 1074[2mms[22m[39m
|
|
20
|
+
[33m[2m✓[22m[39m opens the reject confirmation modal with the default English copy [33m 365[2mms[22m[39m
|
|
21
|
+
[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
|
|
22
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/localization/useBindingSelector.browser.test.tsx [2m([22m[2m9 tests[22m[2m)[22m[32m 65[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 906[2mms[22m[39m
|
|
24
|
+
[33m[2m✓[22m[39m renders the menu view with contract details and manage footer [33m 505[2mms[22m[39m
|
|
25
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/CartRecommendationShelf/CartRecommendationShelf.browser.test.tsx [2m([22m[2m13 tests[22m[2m)[22m[32m 112[2mms[22m[39m
|
|
26
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/reconcileSessionLocale.browser.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m 9[2mms[22m[39m
|
|
27
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/ui/ProductGallery/GalleryPageHeightLock.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m 82[2mms[22m[39m
|
|
28
28
|
[90mstderr[2m | test/components/RecommendationShelf/RecommendationShelf.browser.test.tsx
|
|
29
29
|
[22m[39mError in optimistic validation: TypeError: Failed to parse URL from /api/graphql?operationName=ValidateCartMutation&operationHash=3c71b0d3fc2bade14df68abfa271858beb361b12
|
|
30
30
|
[90m at node:internal/deps/undici/undici:16416:13[39m
|
|
@@ -54,10 +54,11 @@ Browserslist: browsers data (caniuse-lite) is 8 months old. Please run:
|
|
|
54
54
|
[90mstderr[2m | test/components/RecommendationShelf/RecommendationShelf.browser.test.tsx[2m > [22m[2mRecommendationShelf[2m > [22m[2mrenders nothing when there is an error
|
|
55
55
|
[22m[39mError fetching recommendations [90mundefined[39m boom for campaign vrn:recommendations:acc:rec-top-items-v2:campaign-1
|
|
56
56
|
|
|
57
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/RecommendationShelf/RecommendationShelf.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m
|
|
58
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
57
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/RecommendationShelf/RecommendationShelf.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m 76[2mms[22m[39m
|
|
58
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/recommendations/useRecommendationShelf.browser.test.tsx [2m([22m[2m12 tests[22m[2m)[22m[32m 88[2mms[22m[39m
|
|
59
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/CartSidebar/CartSidebar.browser.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m 107[2mms[22m[39m
|
|
59
60
|
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/getInitialSession.browser.test.ts [2m([22m[2m7 tests[22m[2m)[22m[32m 11[2mms[22m[39m
|
|
60
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrderDetails.browser.test.tsx [2m([22m[2m4 tests[22m[2m)[22m[32m
|
|
61
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrderDetails.browser.test.tsx [2m([22m[2m4 tests[22m[2m)[22m[32m 81[2mms[22m[39m
|
|
61
62
|
[90mstderr[2m | test/pages/password-protection.browser.test.tsx[2m > [22m[2mPasswordProtectionLogin[2m > [22m[2mposts the password and redirects to the requested return path
|
|
62
63
|
[22m[39mWarning: An update to PasswordProtectionLogin inside a test was not wrapped in act(...).
|
|
63
64
|
|
|
@@ -95,6 +96,7 @@ act(() => {
|
|
|
95
96
|
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
|
|
96
97
|
at PasswordProtectionLogin (/home/runner/work/faststore/faststore/packages/core/src/pages/password-protection/index.tsx:19:69)
|
|
97
98
|
|
|
99
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/navigation/Navbar.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 32[2mms[22m[39m
|
|
98
100
|
[90mstderr[2m | test/pages/password-protection.browser.test.tsx[2m > [22m[2mPasswordProtectionLogin[2m > [22m[2mdefaults returnTo to root and shows API validation errors
|
|
99
101
|
[22m[39mWarning: An update to PasswordProtectionLogin inside a test was not wrapped in act(...).
|
|
100
102
|
|
|
@@ -239,7 +241,6 @@ act(() => {
|
|
|
239
241
|
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
|
|
240
242
|
at PasswordProtectionLogin (/home/runner/work/faststore/faststore/packages/core/src/pages/password-protection/index.tsx:19:69)
|
|
241
243
|
|
|
242
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/navigation/Navbar.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 28[2mms[22m[39m
|
|
243
244
|
[90mstderr[2m | test/pages/password-protection.browser.test.tsx[2m > [22m[2mPasswordProtectionLogin[2m > [22m[2mshows service unavailable when the login request fails
|
|
244
245
|
[22m[39mWarning: An update to PasswordProtectionLogin inside a test was not wrapped in act(...).
|
|
245
246
|
|
|
@@ -288,9 +289,8 @@ act(() => {
|
|
|
288
289
|
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
|
|
289
290
|
at PasswordProtectionLogin (/home/runner/work/faststore/faststore/packages/core/src/pages/password-protection/index.tsx:19:69)
|
|
290
291
|
|
|
291
|
-
[32m✓[39m [30m[46m browser [49m[39m test/pages/password-protection.browser.test.tsx [2m([22m[2m6 tests[22m[2m)[22m[33m
|
|
292
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/OrganizationDrawerFooter.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[33m
|
|
293
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/useSwitchContract.browser.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 27[2mms[22m[39m
|
|
292
|
+
[32m✓[39m [30m[46m browser [49m[39m test/pages/password-protection.browser.test.tsx [2m([22m[2m6 tests[22m[2m)[22m[33m 552[2mms[22m[39m
|
|
293
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/OrganizationDrawerFooter.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[33m 301[2mms[22m[39m
|
|
294
294
|
[90mstderr[2m | test/components/cms/RenderSections.browser.test.tsx
|
|
295
295
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
296
296
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -299,8 +299,9 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
299
299
|
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
300
300
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
301
301
|
|
|
302
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
303
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/
|
|
302
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/useSwitchContract.browser.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 36[2mms[22m[39m
|
|
303
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/navigation/NavbarSlider.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 22[2mms[22m[39m
|
|
304
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/cms/RenderSections.browser.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m 46[2mms[22m[39m
|
|
304
305
|
[90mstderr[2m | test/sdk/localization/store-url.browser.test.ts
|
|
305
306
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
306
307
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -310,14 +311,14 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
310
311
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
311
312
|
|
|
312
313
|
[32m✓[39m [30m[46m browser [49m[39m test/sdk/localization/store-url.browser.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
313
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/Menu.browser.test.tsx [2m([22m[2m6 tests[22m[2m)[22m[32m
|
|
314
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/useAvailableContracts.browser.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m
|
|
315
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/templates/SearchPage/SearchWrapper.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m
|
|
316
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/recommendations/useRecommendationShelf.sessionFallback.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
317
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountListQuotes.browser.test.tsx [2m([22m[2m4 tests[22m[2m)[22m[32m
|
|
318
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/navigation/NavbarAccountArea.browser.test.tsx [2m([22m[2m4 tests[22m[2m)[22m[32m
|
|
314
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/Menu.browser.test.tsx [2m([22m[2m6 tests[22m[2m)[22m[32m 206[2mms[22m[39m
|
|
315
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/useAvailableContracts.browser.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m 23[2mms[22m[39m
|
|
316
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/templates/SearchPage/SearchWrapper.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 24[2mms[22m[39m
|
|
317
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/recommendations/useRecommendationShelf.sessionFallback.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 122[2mms[22m[39m
|
|
318
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountListQuotes.browser.test.tsx [2m([22m[2m4 tests[22m[2m)[22m[32m 73[2mms[22m[39m
|
|
319
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/navigation/NavbarAccountArea.browser.test.tsx [2m([22m[2m4 tests[22m[2m)[22m[32m 48[2mms[22m[39m
|
|
319
320
|
[32m✓[39m [30m[46m browser [49m[39m test/components/CartRecommendationShelf/CartRecommendationProductCard.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 30[2mms[22m[39m
|
|
320
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/changeContractToken.browser.test.ts [2m([22m[2m9 tests[22m[2m)[22m[32m
|
|
321
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/changeContractToken.browser.test.ts [2m([22m[2m9 tests[22m[2m)[22m[32m 13[2mms[22m[39m
|
|
321
322
|
[90mstderr[2m | test/components/account/doLogout.browser.test.ts
|
|
322
323
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
323
324
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -326,9 +327,9 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
326
327
|
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
327
328
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
328
329
|
|
|
329
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/doLogout.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
330
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/
|
|
331
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/
|
|
330
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/doLogout.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m 20[2mms[22m[39m
|
|
331
|
+
[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
|
|
332
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/OrganizationDrawerHeader.browser.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m 234[2mms[22m[39m
|
|
332
333
|
[90mstderr[2m | test/sdk/account/clearPersistedSessionState.browser.test.ts
|
|
333
334
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
334
335
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -338,13 +339,13 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
338
339
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
339
340
|
|
|
340
341
|
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/clearPersistedSessionState.browser.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 11[2mms[22m[39m
|
|
341
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrderDelivery.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
342
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryOptionAccordion.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
343
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrderStatus.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m
|
|
342
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrderDelivery.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 54[2mms[22m[39m
|
|
343
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryOptionAccordion.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 58[2mms[22m[39m
|
|
344
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrderStatus.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 56[2mms[22m[39m
|
|
344
345
|
[32m✓[39m [30m[46m browser [49m[39m test/components/region/useRegion.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m 14[2mms[22m[39m
|
|
345
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountListCards.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m
|
|
346
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrdersList.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
347
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/SummaryCard.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
346
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountListCards.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 47[2mms[22m[39m
|
|
347
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrdersList.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 11[2mms[22m[39m
|
|
348
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/SummaryCard.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 38[2mms[22m[39m
|
|
348
349
|
[90mstderr[2m | test/sdk/session/sessionStore.browser.test.ts
|
|
349
350
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
350
351
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -353,9 +354,9 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
353
354
|
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
354
355
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
355
356
|
|
|
356
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/sessionStore.browser.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
357
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/OrganizationSignInButton.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
358
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryOptionAccordionDeliveryInfo.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
357
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/sessionStore.browser.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
358
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/OrganizationSignInButton.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 180[2mms[22m[39m
|
|
359
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryOptionAccordionDeliveryInfo.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m 23[2mms[22m[39m
|
|
359
360
|
[90mstderr[2m | test/sdk/session/validateSession.browser.test.ts
|
|
360
361
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
361
362
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -364,14 +365,13 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
364
365
|
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
365
366
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
366
367
|
|
|
367
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/validateSession.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
368
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/StatusCard.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
368
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/validateSession.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
369
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/StatusCard.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 73[2mms[22m[39m
|
|
369
370
|
[32m✓[39m [30m[46m browser [49m[39m test/utils/isLocalHost.browser.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
370
371
|
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/reconcileSessionLocale.disabled.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m 2[2mms[22m[39m
|
|
371
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryCard.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
372
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryOptionAccordionProducts.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
373
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/skeletons/ProductGridSkeleton.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
374
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/localization/bindingPaths.test.ts [2m([22m[2m71 tests[22m[2m)[22m[32m 11[2mms[22m[39m
|
|
372
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryCard.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m 28[2mms[22m[39m
|
|
373
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryOptionAccordionProducts.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m 20[2mms[22m[39m
|
|
374
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/skeletons/ProductGridSkeleton.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 16[2mms[22m[39m
|
|
375
375
|
[90mstderr[2m | test/sdk/account/refreshToken.browser.test.ts
|
|
376
376
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
377
377
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -380,13 +380,14 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
380
380
|
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
381
381
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
382
382
|
|
|
383
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/localization/bindingPaths.test.ts [2m([22m[2m71 tests[22m[2m)[22m[32m 13[2mms[22m[39m
|
|
383
384
|
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/refreshToken.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
384
|
-
[32m✓[39m [30m[
|
|
385
|
-
[32m✓[39m [30m[
|
|
386
|
-
[32m✓[39m [30m[43m node [49m[39m test/pages/api/switch-contract.test.ts [2m([22m[2m25 tests[22m[2m)[22m[32m
|
|
387
|
-
[32m✓[39m [30m[43m node [49m[39m test/server/content/service.test.ts [2m([22m[
|
|
385
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/FilterFacetPendingApproval.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m 123[2mms[22m[39m
|
|
386
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/password-protection-service.test.ts [2m([22m[2m22 tests[22m[2m)[22m[32m 16[2mms[22m[39m
|
|
387
|
+
[32m✓[39m [30m[43m node [49m[39m test/pages/api/switch-contract.test.ts [2m([22m[2m25 tests[22m[2m)[22m[32m 110[2mms[22m[39m
|
|
388
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/content/service.test.ts [2m([22m[2m27 tests[22m[2m)[22m[32m 19[2mms[22m[39m
|
|
389
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/localization/useBindingSelector.test.tsx [2m([22m[2m22 tests[22m[2m)[22m[32m 7[2mms[22m[39m
|
|
388
390
|
[32m✓[39m [30m[43m node [49m[39m test/utils/match-url.test.ts [2m([22m[2m10 tests[22m[2m)[22m[32m 5[2mms[22m[39m
|
|
389
|
-
[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
|
|
390
391
|
[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
|
|
391
392
|
[22m[39mFailed to fetch pickup points: Error: network
|
|
392
393
|
at [90m/home/runner/work/faststore/faststore/packages/core/[39mtest/sdk/deliveryPromise/provider.effect.test.tsx:250:30
|
|
@@ -413,13 +414,13 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
413
414
|
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)
|
|
414
415
|
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)
|
|
415
416
|
|
|
416
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/deliveryPromise/provider.effect.test.tsx [2m([22m[2m9 tests[22m[2m)[22m[32m
|
|
417
|
-
[32m✓[39m [30m[43m node [49m[39m test/pages/api/unlock.test.ts [2m([22m[2m15 tests[22m[2m)[22m[32m
|
|
418
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/session/syncSalesChannelFromOrderForm.test.ts [2m([22m[2m14 tests[22m[2m)[22m[32m
|
|
419
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/localization/bindingSelector.test.ts [2m([22m[2m18 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
417
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/deliveryPromise/provider.effect.test.tsx [2m([22m[2m9 tests[22m[2m)[22m[32m 74[2mms[22m[39m
|
|
418
|
+
[32m✓[39m [30m[43m node [49m[39m test/pages/api/unlock.test.ts [2m([22m[2m15 tests[22m[2m)[22m[32m 94[2mms[22m[39m
|
|
419
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/session/syncSalesChannelFromOrderForm.test.ts [2m([22m[2m14 tests[22m[2m)[22m[32m 7[2mms[22m[39m
|
|
420
420
|
[90mstderr[2m | test/components/search/SearchInputComponent.test.tsx
|
|
421
421
|
[22m[39mWarning: forwardRef render functions accept exactly two parameters: props and ref. Did you forget to use the ref parameter?
|
|
422
422
|
|
|
423
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/localization/bindingSelector.test.ts [2m([22m[2m18 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
423
424
|
[90mstderr[2m | test/components/search/SearchInputComponent.test.tsx[2m > [22m[2mSearchInput (OES integration)[2m > [22m[2mrenders without crashing
|
|
424
425
|
[22m[39mWarning: React does not recognize the `visibleDropdown` prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase `visibledropdown` instead. If you accidentally passed it from a parent component, remove it from the DOM element.
|
|
425
426
|
at div
|
|
@@ -480,9 +481,9 @@ Warning: React does not recognize the `providerProps` prop on a DOM element. If
|
|
|
480
481
|
at Suspense
|
|
481
482
|
at Wrapper (/home/runner/work/faststore/faststore/packages/core/test/components/search/SearchInputComponent.test.tsx:106:20)
|
|
482
483
|
|
|
483
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/search/SearchInputComponent.test.tsx [2m([22m[2m6 tests[22m[2m)[22m[32m
|
|
484
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountListQuotesTable.test.tsx [2m([22m[2m15 tests[22m[2m)[22m[32m
|
|
485
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/search/useSearchHistory.test.ts [2m([22m[2m13 tests[22m[2m)[22m[32m
|
|
484
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/search/SearchInputComponent.test.tsx [2m([22m[2m6 tests[22m[2m)[22m[32m 51[2mms[22m[39m
|
|
485
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountListQuotesTable.test.tsx [2m([22m[2m15 tests[22m[2m)[22m[32m 280[2mms[22m[39m
|
|
486
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/search/useSearchHistory.test.ts [2m([22m[2m13 tests[22m[2m)[22m[32m 26[2mms[22m[39m
|
|
486
487
|
[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
|
|
487
488
|
[22m[39m{ extensions: { status: [33m401[39m } }
|
|
488
489
|
|
|
@@ -490,13 +491,12 @@ Warning: React does not recognize the `providerProps` prop on a DOM element. If
|
|
|
490
491
|
[22m[39m{ extensions: { status: [33m502[39m } }
|
|
491
492
|
|
|
492
493
|
[32m✓[39m [30m[43m node [49m[39m test/pages/pvt/account/cards/index.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m 5[2mms[22m[39m
|
|
493
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/cookieCacheBusting.test.ts [2m([22m[2m10 tests[22m[2m)[22m[32m
|
|
494
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountListQuotes.test.tsx [2m([22m[2m11 tests[22m[2m)[22m[33m
|
|
495
|
-
[33m[2m✓[22m[39m navigates with the search term on blur [33m
|
|
496
|
-
[33m[2m✓[22m[39m navigates without a label param when the search is cleared [33m
|
|
497
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/quoteFilters.test.ts [2m([22m[2m26 tests[22m[2m)[22m[32m
|
|
498
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/productJsonLd.test.ts [2m([22m[2m36 tests[22m[2m)[22m[32m
|
|
499
|
-
[32m✓[39m [30m[43m node [49m[39m test/experimental/myAccountCmsServerSideProps.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 6[2mms[22m[39m
|
|
494
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/cookieCacheBusting.test.ts [2m([22m[2m10 tests[22m[2m)[22m[32m 5[2mms[22m[39m
|
|
495
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountListQuotes.test.tsx [2m([22m[2m11 tests[22m[2m)[22m[33m 766[2mms[22m[39m
|
|
496
|
+
[33m[2m✓[22m[39m navigates with the search term on blur [33m 355[2mms[22m[39m
|
|
497
|
+
[33m[2m✓[22m[39m navigates without a label param when the search is cleared [33m 357[2mms[22m[39m
|
|
498
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/quoteFilters.test.ts [2m([22m[2m26 tests[22m[2m)[22m[32m 17[2mms[22m[39m
|
|
499
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/productJsonLd.test.ts [2m([22m[2m36 tests[22m[2m)[22m[32m 8[2mms[22m[39m
|
|
500
500
|
[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
|
|
501
501
|
[22m[39mGraphql execution returned with error: [
|
|
502
502
|
{
|
|
@@ -606,76 +606,78 @@ Warning: React does not recognize the `providerProps` prop on a DOM element. If
|
|
|
606
606
|
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)
|
|
607
607
|
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)
|
|
608
608
|
|
|
609
|
-
[32m✓[39m [30m[43m node [49m[39m test/pages/api/graphql.test.ts [2m([22m[2m19 tests[22m[2m)[22m[32m
|
|
610
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
609
|
+
[32m✓[39m [30m[43m node [49m[39m test/pages/api/graphql.test.ts [2m([22m[2m19 tests[22m[2m)[22m[32m 28[2mms[22m[39m
|
|
610
|
+
[32m✓[39m [30m[43m node [49m[39m test/experimental/myAccountCmsServerSideProps.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 6[2mms[22m[39m
|
|
611
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/clearCookies.test.ts [2m([22m[2m20 tests[22m[2m)[22m[32m 17[2mms[22m[39m
|
|
611
612
|
[32m✓[39m [30m[43m node [49m[39m test/utils/multipleTemplates.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
612
613
|
[90mstderr[2m | test/sdk/account/useSetPassword.test.ts[2m > [22m[2museSetPassword[2m > [22m[2mmaps wrongcredentials error responses to the existing message
|
|
613
614
|
[22m[39mSet password request failed: Bad Request
|
|
614
615
|
|
|
615
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/useSetPassword.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m
|
|
616
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/orderEntry/useOrderEntryOperation.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m
|
|
616
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/useSetPassword.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m 21[2mms[22m[39m
|
|
617
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/orderEntry/useOrderEntryOperation.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m 22[2mms[22m[39m
|
|
617
618
|
[32m✓[39m [30m[43m node [49m[39m test/utils/localization/localizeRedirectDestination.test.ts [2m([22m[2m11 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
618
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountQuotesFilterSlider.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m
|
|
619
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountQuotesStatusSelector.test.tsx [2m([22m[2m14 tests[22m[2m)[22m[32m
|
|
620
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/localization/hreflang.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m
|
|
621
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
622
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
623
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
624
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
625
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
626
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/orderEntry/
|
|
627
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
619
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountQuotesFilterSlider.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m 101[2mms[22m[39m
|
|
620
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountQuotesStatusSelector.test.tsx [2m([22m[2m14 tests[22m[2m)[22m[32m 106[2mms[22m[39m
|
|
621
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/localization/hreflang.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
622
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountQuotesSelectedTags.test.tsx [2m([22m[2m10 tests[22m[2m)[22m[32m 70[2mms[22m[39m
|
|
623
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/getMyAccountRoutes.test.ts [2m([22m[2m13 tests[22m[2m)[22m[32m 6[2mms[22m[39m
|
|
624
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/cms/index.test.ts [2m([22m[2m7 tests[22m[2m)[22m[32m 5[2mms[22m[39m
|
|
625
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/content/promiseCache.test.ts [2m([22m[2m10 tests[22m[2m)[22m[32m 8[2mms[22m[39m
|
|
626
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/redirects/index.test.ts [2m([22m[2m7 tests[22m[2m)[22m[32m 23[2mms[22m[39m
|
|
627
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/orderEntry/useOrderEntryUpload.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m 32[2mms[22m[39m
|
|
628
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/orderEntry/useOrderEntry.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m 42[2mms[22m[39m
|
|
629
|
+
[32m✓[39m [30m[43m node [49m[39m test/proxy.localization.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 36[2mms[22m[39m
|
|
630
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/account/orders/getDeliveryOptionLabel.test.ts [2m([22m[2m21 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
628
631
|
[32m✓[39m [30m[43m node [49m[39m test/sdk/graphql/retryPolicy.test.ts [2m([22m[2m18 tests[22m[2m)[22m[32m 13[2mms[22m[39m
|
|
629
|
-
[32m✓[39m [30m[43m node [49m[39m test/server/cms/myAccountDefaultSections.test.ts [2m([22m[2m9 tests[22m[2m)[22m[32m
|
|
630
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/productJsonLdRendering.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m
|
|
631
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/trustedForwardedHost.test.ts [2m([22m[2m27 tests[22m[2m)[22m[32m
|
|
632
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/analytics/useStartRecommendationSession.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m
|
|
633
|
-
[32m✓[39m [30m[43m node [49m[39m test/proxy.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m
|
|
634
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
635
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
636
|
-
|
|
637
|
-
[32m✓[39m [30m[43m node [49m[39m test/server/
|
|
638
|
-
|
|
639
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/localization/store-url.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
632
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/cms/myAccountDefaultSections.test.ts [2m([22m[2m9 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
633
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/productJsonLdRendering.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m 8[2mms[22m[39m
|
|
634
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/trustedForwardedHost.test.ts [2m([22m[2m27 tests[22m[2m)[22m[32m 5[2mms[22m[39m
|
|
635
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/analytics/useStartRecommendationSession.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m 26[2mms[22m[39m
|
|
636
|
+
[32m✓[39m [30m[43m node [49m[39m test/proxy.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 12[2mms[22m[39m
|
|
637
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/orderEntry/useOrderFormItems.test.ts [2m([22m[2m7 tests[22m[2m)[22m[32m 15[2mms[22m[39m
|
|
638
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/index.test.ts [2m([22m[2m7 tests[22m[2m)[22m[33m 844[2mms[22m[39m
|
|
639
|
+
[33m[2m✓[22m[39m should handle options and execute [33m 490[2mms[22m[39m
|
|
640
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/webops-api.test.ts [2m([22m[2m9 tests[22m[2m)[22m[32m 13[2mms[22m[39m
|
|
641
|
+
[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
|
|
640
642
|
[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
|
|
641
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/
|
|
642
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/
|
|
643
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
644
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
645
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/
|
|
646
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
647
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
648
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
643
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/localization/store-url.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 2[2mms[22m[39m
|
|
644
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/cart/waitForSessionValidated.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 7[2mms[22m[39m
|
|
645
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/refreshToken.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
646
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/cms/global.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
647
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/deliveryPromise/provider.test.ts [2m([22m[2m11 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
648
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/auth/useAuth.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 20[2mms[22m[39m
|
|
649
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/getRequestHostname.test.ts [2m([22m[2m12 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
650
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/account/Layout.test.tsx [2m([22m[2m6 tests[22m[2m)[22m[32m 38[2mms[22m[39m
|
|
649
651
|
[32m✓[39m [30m[43m node [49m[39m test/server/rootSpan.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 24[2mms[22m[39m
|
|
650
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
652
|
+
[32m✓[39m [30m[43m node [49m[39m test/pages/api/preview.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m 5[2mms[22m[39m
|
|
653
|
+
[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
|
|
651
654
|
[32m✓[39m [30m[43m node [49m[39m test/utils/validateSessionRefreshToken.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
652
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/recommendations/vrn.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m
|
|
653
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
654
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/region/useRegion.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
655
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
656
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/getB2BSessionClaims.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 2[2mms[22m[39m
|
|
655
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/recommendations/vrn.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
656
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/retry.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 11[2mms[22m[39m
|
|
657
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/region/useRegion.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m 14[2mms[22m[39m
|
|
658
|
+
[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
|
|
657
659
|
[32m✓[39m [30m[43m node [49m[39m test/utils/userOrderStatus.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 2[2mms[22m[39m
|
|
658
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/recommendations/useRecommendationUserId.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m
|
|
659
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/unlockResponse.test.ts [2m([22m[2m11 tests[22m[2m)[22m[32m
|
|
660
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/recommendations/useRecommendationUserId.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 174[2mms[22m[39m
|
|
661
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/unlockResponse.test.ts [2m([22m[2m11 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
662
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/account/OrganizationDrawerBody.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 32[2mms[22m[39m
|
|
660
663
|
[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
|
|
661
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/account/OrganizationDrawerBody.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 31[2mms[22m[39m
|
|
662
664
|
[32m✓[39m [30m[43m node [49m[39m test/sdk/deliveryPromise/reducer.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m 2[2mms[22m[39m
|
|
665
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountQuoteStatusBadge.test.tsx [2m([22m[2m4 tests[22m[2m)[22m[32m 23[2mms[22m[39m
|
|
663
666
|
[32m✓[39m [30m[43m node [49m[39m test/utils/isLocalHost.test.ts [2m([22m[2m7 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
664
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
665
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/session/toSessionInput.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
667
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/session/toSessionInput.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 2[2mms[22m[39m
|
|
666
668
|
[32m✓[39m [30m[43m node [49m[39m test/components/account/orders/getOrderTotalLabel.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m 2[2mms[22m[39m
|
|
667
669
|
[32m✓[39m [30m[43m node [49m[39m test/components/account/orders/listOrdersLabels.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m 2[2mms[22m[39m
|
|
668
670
|
[32m✓[39m [30m[43m node [49m[39m test/utils/getCookie.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
669
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/auth/ProfileChallenge.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m
|
|
671
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/auth/ProfileChallenge.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 20[2mms[22m[39m
|
|
670
672
|
[32m✓[39m [30m[43m node [49m[39m test/sdk/session/isSignInAreaResolved.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 2[2mms[22m[39m
|
|
671
673
|
[32m✓[39m [30m[43m node [49m[39m test/utils/filterChannel.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m 2[2mms[22m[39m
|
|
672
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/analytics/utils.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
674
|
+
[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
|
|
673
675
|
[32m✓[39m [30m[43m node [49m[39m test/instrumentation.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
674
676
|
[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
|
|
675
677
|
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/clearPersistedSessionState.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m 6[2mms[22m[39m
|
|
676
678
|
|
|
677
|
-
[2m Test Files [22m [1m[
|
|
678
|
-
[2m Tests [22m [1m[
|
|
679
|
-
[2m Start at [22m
|
|
680
|
-
[2m Duration [22m 37.
|
|
679
|
+
[2m Test Files [22m [1m[32m136 passed[39m[22m[90m (136)[39m
|
|
680
|
+
[2m Tests [22m [1m[32m1103 passed[39m[22m[90m (1103)[39m
|
|
681
|
+
[2m Start at [22m 20:07:11
|
|
682
|
+
[2m Duration [22m 37.55s[2m (transform 10.06s, setup 0ms, import 32.77s, tests 14.13s, environment 44.95s)[22m
|
|
681
683
|
|
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,14 @@
|
|
|
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.10.1-dev.3](https://github.com/vtex/faststore/compare/v4.10.1-dev.2...v4.10.1-dev.3) (2026-10-27)
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
- **core:** address review feedback on CMS cache ([8cec85f](https://github.com/vtex/faststore/commit/8cec85f730643dc72914c8477e9021c7437d8921))
|
|
11
|
+
- **core:** cache global and single CMS content across page generations ([6f20530](https://github.com/vtex/faststore/commit/6f205308216be07cb567595ff5ed59f6a229d876))
|
|
12
|
+
- **core:** do not cache empty required CMS content ([21a2dd3](https://github.com/vtex/faststore/commit/21a2dd3a1379c5b60ea96003e0addd6173f2923e))
|
|
13
|
+
|
|
6
14
|
## [4.10.1-dev.2](https://github.com/vtex/faststore/compare/v4.10.1-dev.1...v4.10.1-dev.2) (2026-10-27)
|
|
7
15
|
|
|
8
16
|
### Bug Fixes
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@faststore/core",
|
|
3
|
-
"version": "4.10.1-dev.
|
|
3
|
+
"version": "4.10.1-dev.3",
|
|
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/
|
|
75
|
-
"@faststore/
|
|
76
|
-
"@faststore/
|
|
77
|
-
"@faststore/
|
|
78
|
-
"@faststore/
|
|
74
|
+
"@faststore/diagnostics": "4.10.1-dev.3",
|
|
75
|
+
"@faststore/lighthouse": "4.10.1-dev.3",
|
|
76
|
+
"@faststore/sdk": "4.10.1-dev.3",
|
|
77
|
+
"@faststore/ui": "4.10.1-dev.3",
|
|
78
|
+
"@faststore/api": "4.10.1-dev.3"
|
|
79
79
|
},
|
|
80
80
|
"devDependencies": {
|
|
81
81
|
"@cypress/code-coverage": "^3.12.1",
|
package/src/server/cms/index.ts
CHANGED
|
@@ -3,6 +3,7 @@ import ClientCMS from '@vtex/client-cms'
|
|
|
3
3
|
|
|
4
4
|
import MultipleContentError from 'src/sdk/error/MultipleContentError'
|
|
5
5
|
import { getStoreURL } from 'src/sdk/localization/useLocalizationConfig'
|
|
6
|
+
import { createPromiseCache } from 'src/server/content/promiseCache'
|
|
6
7
|
import { sanitizeHost } from 'src/utils/utilities'
|
|
7
8
|
import config from '../../../discovery.config'
|
|
8
9
|
|
|
@@ -79,16 +80,64 @@ export const clientCMS = new ClientCMS({
|
|
|
79
80
|
host: sanitizeHost(new URL(getStoreURL()).origin),
|
|
80
81
|
})
|
|
81
82
|
|
|
83
|
+
type CMSPageResult = { data: ContentData[] }
|
|
84
|
+
|
|
85
|
+
export const cmsPageCache = createPromiseCache<CMSPageResult>()
|
|
86
|
+
|
|
87
|
+
type GetCMSPageOptions = {
|
|
88
|
+
/**
|
|
89
|
+
* Reuse a document fetched by locator. Only safe when the locator does not
|
|
90
|
+
* come from a preview, since preview versions change between requests.
|
|
91
|
+
*/
|
|
92
|
+
cache?: boolean
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
/**
|
|
96
|
+
* Listings by content type never carry preview data (previews always resolve
|
|
97
|
+
* to a locator), so they are shared across pages. Filtered listings depend on
|
|
98
|
+
* the page (e.g. landing page slug) and stay uncached.
|
|
99
|
+
*/
|
|
82
100
|
export const getCMSPage = async (
|
|
83
101
|
options: Options,
|
|
84
|
-
cmsClient: ClientCMS = clientCMS
|
|
85
|
-
|
|
102
|
+
cmsClient: ClientCMS = clientCMS,
|
|
103
|
+
{ cache = false }: GetCMSPageOptions = {}
|
|
104
|
+
): Promise<CMSPageResult> => {
|
|
105
|
+
const shareable = cmsClient === clientCMS
|
|
106
|
+
|
|
86
107
|
if (isLocator(options)) {
|
|
87
|
-
|
|
88
|
-
.getCMSPage(options)
|
|
89
|
-
|
|
108
|
+
const fetchByLocator = () =>
|
|
109
|
+
cmsClient.getCMSPage(options).then((page) => ({ data: [page] }))
|
|
110
|
+
|
|
111
|
+
if (!cache || !shareable) {
|
|
112
|
+
return fetchByLocator()
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
const { contentType, documentId, versionId, releaseId } = options
|
|
116
|
+
return cmsPageCache.get(
|
|
117
|
+
JSON.stringify([
|
|
118
|
+
'locator',
|
|
119
|
+
contentType,
|
|
120
|
+
documentId,
|
|
121
|
+
versionId,
|
|
122
|
+
releaseId,
|
|
123
|
+
]),
|
|
124
|
+
fetchByLocator
|
|
125
|
+
)
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
if (options.filters || !shareable) {
|
|
129
|
+
return listCMSPages(options, cmsClient)
|
|
90
130
|
}
|
|
91
131
|
|
|
132
|
+
return cmsPageCache.get(JSON.stringify(['list', options.contentType]), () =>
|
|
133
|
+
listCMSPages(options, cmsClient)
|
|
134
|
+
)
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
const listCMSPages = async (
|
|
138
|
+
options: Exclude<Options, Locator>,
|
|
139
|
+
cmsClient: ClientCMS
|
|
140
|
+
): Promise<CMSPageResult> => {
|
|
92
141
|
const pages = []
|
|
93
142
|
const page = 1
|
|
94
143
|
const perPage = 10
|
|
@@ -124,8 +173,11 @@ export const getCMSPage = async (
|
|
|
124
173
|
return { data: pages }
|
|
125
174
|
}
|
|
126
175
|
|
|
127
|
-
export const getPage = async <T extends ContentData>(
|
|
128
|
-
|
|
176
|
+
export const getPage = async <T extends ContentData>(
|
|
177
|
+
options: Options,
|
|
178
|
+
getOptions?: GetCMSPageOptions
|
|
179
|
+
) => {
|
|
180
|
+
const result = await getCMSPage(options, clientCMS, getOptions)
|
|
129
181
|
|
|
130
182
|
const pages = result.data
|
|
131
183
|
|