@faststore/core 4.10.1-dev.1 → 4.10.1-dev.2
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 +144 -156
- package/CHANGELOG.md +6 -0
- package/package.json +6 -6
- package/src/pages/[slug]/p.tsx +7 -2
- package/src/server/content/service.ts +27 -10
- package/test/server/content/service.test.ts +40 -1
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
|
|
2
|
-
> @faststore/core@4.10.1-dev.
|
|
2
|
+
> @faststore/core@4.10.1-dev.1 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.1 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.1 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.1 test /home/runner/work/faststore/faststore/packages/core
|
|
3
3
|
> vitest run
|
|
4
4
|
|
|
5
5
|
|
|
@@ -7,33 +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 1284[2mms[22m[39m
|
|
11
10
|
Browserslist: browsers data (caniuse-lite) is 8 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
|
-
[33m[2m✓[22m[39m
|
|
17
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/
|
|
18
|
-
[33m[2m✓[22m[39m shows
|
|
19
|
-
|
|
20
|
-
[33m[2m✓[22m[39m
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
[33m[2m✓[22m[39m
|
|
24
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
25
|
-
[33m[2m✓[22m[39m opens the reject confirmation modal with the default English copy [33m 1448[2mms[22m[39m
|
|
26
|
-
[33m[2m✓[22m[39m opens the reject confirmation modal with CMS-provided labels [33m 435[2mms[22m[39m
|
|
27
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/ui/RichText/RichText.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[33m 397[2mms[22m[39m
|
|
28
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/OrganizationDrawer.browser.test.tsx [2m([22m[2m10 tests[22m[2m)[22m[33m 2039[2mms[22m[39m
|
|
29
|
-
[33m[2m✓[22m[39m renders the menu view with contract details and manage footer [33m 1045[2mms[22m[39m
|
|
30
|
-
[33m[2m✓[22m[39m opens the contract switcher and returns to the menu on back [33m 410[2mms[22m[39m
|
|
31
|
-
[33m[2m✓[22m[39m resets to the menu when the drawer closes [33m 323[2mms[22m[39m
|
|
32
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/CartRecommendationShelf/CartRecommendationShelf.browser.test.tsx [2m([22m[2m13 tests[22m[2m)[22m[32m 240[2mms[22m[39m
|
|
13
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/ui/useScrollRestoration.browser.test.ts [2m([22m[2m43 tests[22m[2m)[22m[33m 1047[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 2181[2mms[22m[39m
|
|
15
|
+
[33m[2m✓[22m[39m shows an error state when the list fails to load [33m 468[2mms[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 1688[2mms[22m[39m
|
|
17
|
+
[33m[2m✓[22m[39m shows the tab bar and renders Personal cards by default [33m 704[2mms[22m[39m
|
|
18
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/BuyingPolicyAlert.browser.test.tsx [2m([22m[2m13 tests[22m[2m)[22m[33m 1744[2mms[22m[39m
|
|
19
|
+
[33m[2m✓[22m[39m opens the reject confirmation modal with the default English copy [33m 762[2mms[22m[39m
|
|
20
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/ui/RichText/RichText.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m 254[2mms[22m[39m
|
|
21
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/OrganizationDrawer.browser.test.tsx [2m([22m[2m10 tests[22m[2m)[22m[33m 1201[2mms[22m[39m
|
|
22
|
+
[33m[2m✓[22m[39m renders the menu view with contract details and manage footer [33m 597[2mms[22m[39m
|
|
23
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/localization/useBindingSelector.browser.test.tsx [2m([22m[2m9 tests[22m[2m)[22m[32m 60[2mms[22m[39m
|
|
33
24
|
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/reconcileSessionLocale.browser.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m 11[2mms[22m[39m
|
|
34
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
35
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/ui/ProductGallery/GalleryPageHeightLock.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m
|
|
36
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/recommendations/useRecommendationShelf.browser.test.tsx [2m([22m[2m12 tests[22m[2m)[22m[32m
|
|
25
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/CartRecommendationShelf/CartRecommendationShelf.browser.test.tsx [2m([22m[2m13 tests[22m[2m)[22m[32m 143[2mms[22m[39m
|
|
26
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/ui/ProductGallery/GalleryPageHeightLock.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m 49[2mms[22m[39m
|
|
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
|
|
37
28
|
[90mstderr[2m | test/components/RecommendationShelf/RecommendationShelf.browser.test.tsx
|
|
38
29
|
[22m[39mError in optimistic validation: TypeError: Failed to parse URL from /api/graphql?operationName=ValidateCartMutation&operationHash=3c71b0d3fc2bade14df68abfa271858beb361b12
|
|
39
30
|
[90m at node:internal/deps/undici/undici:16416:13[39m
|
|
@@ -63,10 +54,10 @@ Browserslist: browsers data (caniuse-lite) is 8 months old. Please run:
|
|
|
63
54
|
[90mstderr[2m | test/components/RecommendationShelf/RecommendationShelf.browser.test.tsx[2m > [22m[2mRecommendationShelf[2m > [22m[2mrenders nothing when there is an error
|
|
64
55
|
[22m[39mError fetching recommendations [90mundefined[39m boom for campaign vrn:recommendations:acc:rec-top-items-v2:campaign-1
|
|
65
56
|
|
|
66
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/RecommendationShelf/RecommendationShelf.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m
|
|
67
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/CartSidebar/CartSidebar.browser.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m
|
|
68
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/getInitialSession.browser.test.ts [2m([22m[2m7 tests[22m[2m)[22m[32m
|
|
69
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrderDetails.browser.test.tsx [2m([22m[2m4 tests[22m[2m)[22m[32m
|
|
57
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/RecommendationShelf/RecommendationShelf.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m 71[2mms[22m[39m
|
|
58
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/CartSidebar/CartSidebar.browser.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m 71[2mms[22m[39m
|
|
59
|
+
[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 75[2mms[22m[39m
|
|
70
61
|
[90mstderr[2m | test/pages/password-protection.browser.test.tsx[2m > [22m[2mPasswordProtectionLogin[2m > [22m[2mposts the password and redirects to the requested return path
|
|
71
62
|
[22m[39mWarning: An update to PasswordProtectionLogin inside a test was not wrapped in act(...).
|
|
72
63
|
|
|
@@ -152,7 +143,6 @@ act(() => {
|
|
|
152
143
|
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
|
|
153
144
|
at PasswordProtectionLogin (/home/runner/work/faststore/faststore/packages/core/src/pages/password-protection/index.tsx:19:69)
|
|
154
145
|
|
|
155
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/navigation/Navbar.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 93[2mms[22m[39m
|
|
156
146
|
[90mstderr[2m | test/pages/password-protection.browser.test.tsx[2m > [22m[2mPasswordProtectionLogin[2m > [22m[2muses the fallback invalid-password message when API omits an error
|
|
157
147
|
[22m[39mWarning: An update to PasswordProtectionLogin inside a test was not wrapped in act(...).
|
|
158
148
|
|
|
@@ -249,6 +239,7 @@ act(() => {
|
|
|
249
239
|
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
|
|
250
240
|
at PasswordProtectionLogin (/home/runner/work/faststore/faststore/packages/core/src/pages/password-protection/index.tsx:19:69)
|
|
251
241
|
|
|
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
|
|
252
243
|
[90mstderr[2m | test/pages/password-protection.browser.test.tsx[2m > [22m[2mPasswordProtectionLogin[2m > [22m[2mshows service unavailable when the login request fails
|
|
253
244
|
[22m[39mWarning: An update to PasswordProtectionLogin inside a test was not wrapped in act(...).
|
|
254
245
|
|
|
@@ -297,9 +288,9 @@ act(() => {
|
|
|
297
288
|
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
|
|
298
289
|
at PasswordProtectionLogin (/home/runner/work/faststore/faststore/packages/core/src/pages/password-protection/index.tsx:19:69)
|
|
299
290
|
|
|
300
|
-
[32m✓[39m [30m[46m browser [49m[39m test/pages/password-protection.browser.test.tsx [2m([22m[2m6 tests[22m[2m)[22m[33m
|
|
301
|
-
|
|
302
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
291
|
+
[32m✓[39m [30m[46m browser [49m[39m test/pages/password-protection.browser.test.tsx [2m([22m[2m6 tests[22m[2m)[22m[33m 451[2mms[22m[39m
|
|
292
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/OrganizationDrawerFooter.browser.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[33m 347[2mms[22m[39m
|
|
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
|
|
303
294
|
[90mstderr[2m | test/components/cms/RenderSections.browser.test.tsx
|
|
304
295
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
305
296
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -308,9 +299,8 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
308
299
|
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
309
300
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
310
301
|
|
|
311
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
312
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/
|
|
313
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/cms/RenderSections.browser.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m 99[2mms[22m[39m
|
|
302
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/navigation/NavbarSlider.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 24[2mms[22m[39m
|
|
303
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/cms/RenderSections.browser.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m 52[2mms[22m[39m
|
|
314
304
|
[90mstderr[2m | test/sdk/localization/store-url.browser.test.ts
|
|
315
305
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
316
306
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -319,15 +309,15 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
319
309
|
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
320
310
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
321
311
|
|
|
322
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/localization/store-url.browser.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m
|
|
323
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
324
|
-
[32m✓[39m [30m[46m browser [49m[39m test/
|
|
325
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/templates/SearchPage/SearchWrapper.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m
|
|
326
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/recommendations/useRecommendationShelf.sessionFallback.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
327
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountListQuotes.browser.test.tsx [2m([22m[2m4 tests[22m[2m)[22m[32m
|
|
328
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/navigation/NavbarAccountArea.browser.test.tsx [2m([22m[2m4 tests[22m[2m)[22m[32m
|
|
329
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/CartRecommendationShelf/CartRecommendationProductCard.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m
|
|
330
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/changeContractToken.browser.test.ts [2m([22m[2m9 tests[22m[2m)[22m[32m
|
|
312
|
+
[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 207[2mms[22m[39m
|
|
314
|
+
[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
|
|
315
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/templates/SearchPage/SearchWrapper.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 17[2mms[22m[39m
|
|
316
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/recommendations/useRecommendationShelf.sessionFallback.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 120[2mms[22m[39m
|
|
317
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountListQuotes.browser.test.tsx [2m([22m[2m4 tests[22m[2m)[22m[32m 85[2mms[22m[39m
|
|
318
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/navigation/NavbarAccountArea.browser.test.tsx [2m([22m[2m4 tests[22m[2m)[22m[32m 31[2mms[22m[39m
|
|
319
|
+
[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 12[2mms[22m[39m
|
|
331
321
|
[90mstderr[2m | test/components/account/doLogout.browser.test.ts
|
|
332
322
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
333
323
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -336,9 +326,9 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
336
326
|
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
337
327
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
338
328
|
|
|
339
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/doLogout.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
340
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/
|
|
341
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/
|
|
329
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/doLogout.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m 14[2mms[22m[39m
|
|
330
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/OrganizationDrawerHeader.browser.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m 177[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 26[2mms[22m[39m
|
|
342
332
|
[90mstderr[2m | test/sdk/account/clearPersistedSessionState.browser.test.ts
|
|
343
333
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
344
334
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -347,14 +337,14 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
347
337
|
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
348
338
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
349
339
|
|
|
350
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/clearPersistedSessionState.browser.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m
|
|
351
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrderDelivery.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
352
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryOptionAccordion.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
353
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrderStatus.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m
|
|
354
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/region/useRegion.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
355
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountListCards.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m
|
|
356
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrdersList.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
357
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/SummaryCard.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
340
|
+
[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 48[2mms[22m[39m
|
|
342
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryOptionAccordion.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 57[2mms[22m[39m
|
|
343
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrderStatus.browser.test.tsx [2m([22m[2m3 tests[22m[2m)[22m[32m 68[2mms[22m[39m
|
|
344
|
+
[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 53[2mms[22m[39m
|
|
346
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/sections/Account/AccountOrdersList.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 23[2mms[22m[39m
|
|
347
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/SummaryCard.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 50[2mms[22m[39m
|
|
358
348
|
[90mstderr[2m | test/sdk/session/sessionStore.browser.test.ts
|
|
359
349
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
360
350
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -363,9 +353,9 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
363
353
|
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
364
354
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
365
355
|
|
|
366
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/sessionStore.browser.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
367
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/OrganizationSignInButton.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
368
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryOptionAccordionDeliveryInfo.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
356
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/sessionStore.browser.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
357
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/OrganizationSignInButton.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 147[2mms[22m[39m
|
|
358
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryOptionAccordionDeliveryInfo.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m 22[2mms[22m[39m
|
|
369
359
|
[90mstderr[2m | test/sdk/session/validateSession.browser.test.ts
|
|
370
360
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
371
361
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -374,13 +364,14 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
374
364
|
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
375
365
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
376
366
|
|
|
377
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/validateSession.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
378
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/StatusCard.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
379
|
-
[32m✓[39m [30m[46m browser [49m[39m test/utils/isLocalHost.browser.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m
|
|
380
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/reconcileSessionLocale.disabled.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
381
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryCard.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
382
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryOptionAccordionProducts.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
383
|
-
[32m✓[39m [30m[46m browser [49m[39m test/components/skeletons/ProductGridSkeleton.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m
|
|
367
|
+
[32m✓[39m [30m[46m browser [49m[39m test/sdk/session/validateSession.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
368
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/StatusCard.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 69[2mms[22m[39m
|
|
369
|
+
[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
|
+
[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 32[2mms[22m[39m
|
|
372
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/DeliveryOptionAccordionProducts.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m 19[2mms[22m[39m
|
|
373
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/skeletons/ProductGridSkeleton.browser.test.tsx [2m([22m[2m2 tests[22m[2m)[22m[32m 17[2mms[22m[39m
|
|
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
|
|
384
375
|
[90mstderr[2m | test/sdk/account/refreshToken.browser.test.ts
|
|
385
376
|
[22m[39mError in optimistic validation: TypeError: Cannot read properties of undefined (reading 'read')
|
|
386
377
|
at waitForSessionValidated [90m(/home/runner/work/faststore/faststore/packages/core/[39msrc/sdk/cart/waitForSessionValidated.ts:16:32[90m)[39m
|
|
@@ -389,11 +380,13 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
389
380
|
at a (/home/runner/work/faststore/faststore/packages/sdk/dist/es/index.mjs:357:23)
|
|
390
381
|
[90m at processTicksAndRejections (node:internal/process/task_queues:103:5)[39m
|
|
391
382
|
|
|
392
|
-
[32m✓[39m [30m[46m browser [49m[39m test/sdk/account/refreshToken.browser.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m
|
|
393
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
394
|
-
[32m✓[39m [30m[
|
|
395
|
-
[32m✓[39m [30m[
|
|
396
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
383
|
+
[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[43m node [49m[39m test/server/password-protection-service.test.ts [2m([22m[2m22 tests[22m[2m)[22m[32m 19[2mms[22m[39m
|
|
385
|
+
[32m✓[39m [30m[46m browser [49m[39m test/components/account/orders/FilterFacetPendingApproval.browser.test.tsx [2m([22m[2m1 test[22m[2m)[22m[32m 143[2mms[22m[39m
|
|
386
|
+
[32m✓[39m [30m[43m node [49m[39m test/pages/api/switch-contract.test.ts [2m([22m[2m25 tests[22m[2m)[22m[32m 66[2mms[22m[39m
|
|
387
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/content/service.test.ts [2m([22m[2m16 tests[22m[2m)[22m[32m 15[2mms[22m[39m
|
|
388
|
+
[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
|
|
397
390
|
[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
|
|
398
391
|
[22m[39mFailed to fetch pickup points: Error: network
|
|
399
392
|
at [90m/home/runner/work/faststore/faststore/packages/core/[39mtest/sdk/deliveryPromise/provider.effect.test.tsx:250:30
|
|
@@ -420,16 +413,13 @@ This ensures that you're testing the behavior the user would see in the browser.
|
|
|
420
413
|
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)
|
|
421
414
|
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)
|
|
422
415
|
|
|
423
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/deliveryPromise/provider.effect.test.tsx [2m([22m[2m9 tests[22m[2m)[22m[32m
|
|
424
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
425
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
426
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/localization/
|
|
427
|
-
[32m✓[39m [30m[43m node [49m[39m test/pages/api/unlock.test.ts [2m([22m[2m15 tests[22m[2m)[22m[32m 175[2mms[22m[39m
|
|
428
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/session/syncSalesChannelFromOrderForm.test.ts [2m([22m[2m14 tests[22m[2m)[22m[32m 14[2mms[22m[39m
|
|
416
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/deliveryPromise/provider.effect.test.tsx [2m([22m[2m9 tests[22m[2m)[22m[32m 57[2mms[22m[39m
|
|
417
|
+
[32m✓[39m [30m[43m node [49m[39m test/pages/api/unlock.test.ts [2m([22m[2m15 tests[22m[2m)[22m[32m 92[2mms[22m[39m
|
|
418
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/session/syncSalesChannelFromOrderForm.test.ts [2m([22m[2m14 tests[22m[2m)[22m[32m 5[2mms[22m[39m
|
|
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
|
|
429
420
|
[90mstderr[2m | test/components/search/SearchInputComponent.test.tsx
|
|
430
421
|
[22m[39mWarning: forwardRef render functions accept exactly two parameters: props and ref. Did you forget to use the ref parameter?
|
|
431
422
|
|
|
432
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/localization/bindingSelector.test.ts [2m([22m[2m18 tests[22m[2m)[22m[32m 9[2mms[22m[39m
|
|
433
423
|
[90mstderr[2m | test/components/search/SearchInputComponent.test.tsx[2m > [22m[2mSearchInput (OES integration)[2m > [22m[2mrenders without crashing
|
|
434
424
|
[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.
|
|
435
425
|
at div
|
|
@@ -490,23 +480,23 @@ Warning: React does not recognize the `providerProps` prop on a DOM element. If
|
|
|
490
480
|
at Suspense
|
|
491
481
|
at Wrapper (/home/runner/work/faststore/faststore/packages/core/test/components/search/SearchInputComponent.test.tsx:106:20)
|
|
492
482
|
|
|
493
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/search/SearchInputComponent.test.tsx [2m([22m[2m6 tests[22m[2m)[22m[32m
|
|
494
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountListQuotesTable.test.tsx [2m([22m[2m15 tests[22m[2m)[22m[
|
|
495
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/search/useSearchHistory.test.ts [2m([22m[2m13 tests[22m[2m)[22m[32m
|
|
496
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountListQuotes.test.tsx [2m([22m[2m11 tests[22m[2m)[22m[33m 840[2mms[22m[39m
|
|
497
|
-
[33m[2m✓[22m[39m navigates with the search term on blur [33m 361[2mms[22m[39m
|
|
498
|
-
[33m[2m✓[22m[39m navigates without a label param when the search is cleared [33m 360[2mms[22m[39m
|
|
483
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/search/SearchInputComponent.test.tsx [2m([22m[2m6 tests[22m[2m)[22m[32m 42[2mms[22m[39m
|
|
484
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountListQuotesTable.test.tsx [2m([22m[2m15 tests[22m[2m)[22m[32m 281[2mms[22m[39m
|
|
485
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/search/useSearchHistory.test.ts [2m([22m[2m13 tests[22m[2m)[22m[32m 28[2mms[22m[39m
|
|
499
486
|
[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
|
|
500
487
|
[22m[39m{ extensions: { status: [33m401[39m } }
|
|
501
488
|
|
|
502
489
|
[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
|
|
503
490
|
[22m[39m{ extensions: { status: [33m502[39m } }
|
|
504
491
|
|
|
505
|
-
[32m✓[39m [30m[43m node [49m[39m test/pages/pvt/account/cards/index.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m
|
|
506
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
507
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
508
|
-
|
|
509
|
-
|
|
492
|
+
[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 8[2mms[22m[39m
|
|
494
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountListQuotes.test.tsx [2m([22m[2m11 tests[22m[2m)[22m[33m 783[2mms[22m[39m
|
|
495
|
+
[33m[2m✓[22m[39m navigates with the search term on blur [33m 357[2mms[22m[39m
|
|
496
|
+
[33m[2m✓[22m[39m navigates without a label param when the search is cleared [33m 358[2mms[22m[39m
|
|
497
|
+
[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
|
|
498
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/productJsonLd.test.ts [2m([22m[2m36 tests[22m[2m)[22m[32m 7[2mms[22m[39m
|
|
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
|
|
510
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
|
|
511
501
|
[22m[39mGraphql execution returned with error: [
|
|
512
502
|
{
|
|
@@ -616,78 +606,76 @@ Warning: React does not recognize the `providerProps` prop on a DOM element. If
|
|
|
616
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)
|
|
617
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)
|
|
618
608
|
|
|
619
|
-
[32m✓[39m [30m[43m node [49m[39m test/pages/api/graphql.test.ts [2m([22m[2m19 tests[22m[2m)[22m[32m
|
|
620
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/clearCookies.test.ts [2m([22m[2m20 tests[22m[2m)[22m[32m
|
|
621
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/multipleTemplates.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m
|
|
609
|
+
[32m✓[39m [30m[43m node [49m[39m test/pages/api/graphql.test.ts [2m([22m[2m19 tests[22m[2m)[22m[32m 20[2mms[22m[39m
|
|
610
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/clearCookies.test.ts [2m([22m[2m20 tests[22m[2m)[22m[32m 16[2mms[22m[39m
|
|
611
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/multipleTemplates.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
622
612
|
[90mstderr[2m | test/sdk/account/useSetPassword.test.ts[2m > [22m[2museSetPassword[2m > [22m[2mmaps wrongcredentials error responses to the existing message
|
|
623
613
|
[22m[39mSet password request failed: Bad Request
|
|
624
614
|
|
|
625
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/useSetPassword.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m
|
|
626
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/orderEntry/useOrderEntryOperation.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m
|
|
627
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/localization/localizeRedirectDestination.test.ts [2m([22m[2m11 tests[22m[2m)[22m[32m
|
|
628
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountQuotesFilterSlider.test.tsx [2m([22m[2m8 tests[22m[2m)[22m[32m
|
|
629
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountQuotesStatusSelector.test.tsx [2m([22m[2m14 tests[22m[2m)[22m[32m
|
|
630
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/localization/hreflang.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m
|
|
631
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/getMyAccountRoutes.test.ts [2m([22m[2m13 tests[22m[2m)[22m[32m
|
|
632
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountQuotesSelectedTags.test.tsx [2m([22m[2m10 tests[22m[2m)[22m[32m
|
|
633
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/redirects/index.test.ts [2m([22m[2m7 tests[22m[2m)[22m[32m
|
|
634
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/orderEntry/useOrderEntryUpload.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m
|
|
635
|
-
[32m✓[39m [30m[43m node [49m[39m test/proxy.localization.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m
|
|
636
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/orderEntry/useOrderEntry.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m
|
|
615
|
+
[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
|
|
616
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/orderEntry/useOrderEntryOperation.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m 26[2mms[22m[39m
|
|
617
|
+
[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 91[2mms[22m[39m
|
|
619
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountQuotesStatusSelector.test.tsx [2m([22m[2m14 tests[22m[2m)[22m[32m 111[2mms[22m[39m
|
|
620
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/localization/hreflang.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
621
|
+
[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
|
|
622
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/quotes/MyAccountQuotesSelectedTags.test.tsx [2m([22m[2m10 tests[22m[2m)[22m[32m 66[2mms[22m[39m
|
|
623
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/redirects/index.test.ts [2m([22m[2m7 tests[22m[2m)[22m[32m 43[2mms[22m[39m
|
|
624
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/orderEntry/useOrderEntryUpload.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m 28[2mms[22m[39m
|
|
625
|
+
[32m✓[39m [30m[43m node [49m[39m test/proxy.localization.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 32[2mms[22m[39m
|
|
626
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/orderEntry/useOrderEntry.test.ts [2m([22m[2m8 tests[22m[2m)[22m[32m 23[2mms[22m[39m
|
|
637
627
|
[32m✓[39m [30m[43m node [49m[39m test/components/account/orders/getDeliveryOptionLabel.test.ts [2m([22m[2m21 tests[22m[2m)[22m[32m 8[2mms[22m[39m
|
|
638
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/graphql/retryPolicy.test.ts [2m([22m[2m18 tests[22m[2m)[22m[32m
|
|
639
|
-
[32m✓[39m [30m[43m node [49m[39m test/server/cms/myAccountDefaultSections.test.ts [2m([22m[2m9 tests[22m[2m)[22m[32m
|
|
640
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/productJsonLdRendering.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m
|
|
641
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/trustedForwardedHost.test.ts [2m([22m[2m27 tests[22m[2m)[22m[32m
|
|
642
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
647
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
648
|
-
|
|
649
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/
|
|
650
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
651
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/
|
|
652
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/
|
|
653
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
654
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/
|
|
655
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
656
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
657
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
658
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
659
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
660
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
661
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
662
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
663
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
664
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
665
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
666
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
667
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/
|
|
668
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/
|
|
669
|
-
[32m✓[39m [30m[43m node [49m[39m test/utils/
|
|
670
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/recommendations/
|
|
671
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
672
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/
|
|
673
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
674
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
675
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
676
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
677
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
678
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
679
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/
|
|
680
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
681
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
682
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/
|
|
683
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
684
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
685
|
-
[32m✓[39m [30m[43m node [49m[39m test/
|
|
686
|
-
[32m✓[39m [30m[43m node [49m[39m test/components/account/orders/orderDetailsLabels.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
687
|
-
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/clearPersistedSessionState.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m 12[2mms[22m[39m
|
|
628
|
+
[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 4[2mms[22m[39m
|
|
630
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/productJsonLdRendering.test.tsx [2m([22m[2m5 tests[22m[2m)[22m[32m 9[2mms[22m[39m
|
|
631
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/trustedForwardedHost.test.ts [2m([22m[2m27 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
632
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/analytics/useStartRecommendationSession.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m 23[2mms[22m[39m
|
|
633
|
+
[32m✓[39m [30m[43m node [49m[39m test/proxy.test.ts [2m([22m[2m4 tests[22m[2m)[22m[32m 11[2mms[22m[39m
|
|
634
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/webops-api.test.ts [2m([22m[2m9 tests[22m[2m)[22m[32m 7[2mms[22m[39m
|
|
635
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/orderEntry/useOrderFormItems.test.ts [2m([22m[2m7 tests[22m[2m)[22m[32m 18[2mms[22m[39m
|
|
636
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/account/orders/StatusCard.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 12[2mms[22m[39m
|
|
637
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/index.test.ts [2m([22m[2m7 tests[22m[2m)[22m[33m 1131[2mms[22m[39m
|
|
638
|
+
[33m[2m✓[22m[39m should handle options and execute [33m 791[2mms[22m[39m
|
|
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
|
|
640
|
+
[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/cart/waitForSessionValidated.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 6[2mms[22m[39m
|
|
642
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/account/refreshToken.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 5[2mms[22m[39m
|
|
643
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/cms/global.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 7[2mms[22m[39m
|
|
644
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/deliveryPromise/provider.test.ts [2m([22m[2m11 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
645
|
+
[32m✓[39m [30m[43m node [49m[39m test/sdk/auth/useAuth.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 12[2mms[22m[39m
|
|
646
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/getRequestHostname.test.ts [2m([22m[2m12 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
647
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/account/Layout.test.tsx [2m([22m[2m6 tests[22m[2m)[22m[32m 44[2mms[22m[39m
|
|
648
|
+
[32m✓[39m [30m[43m node [49m[39m test/pages/api/preview.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m 6[2mms[22m[39m
|
|
649
|
+
[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/components/search/SearchInput.test.ts [2m([22m[2m6 tests[22m[2m)[22m[32m 5[2mms[22m[39m
|
|
651
|
+
[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 2[2mms[22m[39m
|
|
653
|
+
[32m✓[39m [30m[43m node [49m[39m test/server/cms/index.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
654
|
+
[32m✓[39m [30m[43m node [49m[39m test/components/region/useRegion.test.ts [2m([22m[2m1 test[22m[2m)[22m[32m 13[2mms[22m[39m
|
|
655
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/retry.test.ts [2m([22m[2m5 tests[22m[2m)[22m[32m 10[2mms[22m[39m
|
|
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
|
|
657
|
+
[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 178[2mms[22m[39m
|
|
659
|
+
[32m✓[39m [30m[43m node [49m[39m test/utils/unlockResponse.test.ts [2m([22m[2m11 tests[22m[2m)[22m[32m 4[2mms[22m[39m
|
|
660
|
+
[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
|
+
[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
|
|
663
|
+
[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/components/quotes/MyAccountQuoteStatusBadge.test.tsx [2m([22m[2m4 tests[22m[2m)[22m[32m 19[2mms[22m[39m
|
|
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
|
|
666
|
+
[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
|
+
[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
|
+
[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 19[2mms[22m[39m
|
|
670
|
+
[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
|
+
[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 2[2mms[22m[39m
|
|
673
|
+
[32m✓[39m [30m[43m node [49m[39m test/instrumentation.test.ts [2m([22m[2m3 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
674
|
+
[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
|
+
[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
|
|
688
676
|
|
|
689
677
|
[2m Test Files [22m [1m[32m135 passed[39m[22m[90m (135)[39m
|
|
690
|
-
[2m Tests [22m [1m[
|
|
691
|
-
[2m Start at [22m
|
|
692
|
-
[2m Duration [22m
|
|
678
|
+
[2m Tests [22m [1m[32m1077 passed[39m[22m[90m (1077)[39m
|
|
679
|
+
[2m Start at [22m 19:24:01
|
|
680
|
+
[2m Duration [22m 37.79s[2m (transform 8.93s, setup 0ms, import 32.76s, tests 14.78s, environment 45.53s)[22m
|
|
693
681
|
|
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.10.1-dev.2](https://github.com/vtex/faststore/compare/v4.10.1-dev.1...v4.10.1-dev.2) (2026-10-27)
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
- **core:** keep CMS author emails off public page props ([a63c6b1](https://github.com/vtex/faststore/commit/a63c6b1b880055a9ceb6395ad3bba04ad2ce4a95))
|
|
11
|
+
|
|
6
12
|
## [4.10.1-dev.1](https://github.com/vtex/faststore/compare/v4.10.1-dev.0...v4.10.1-dev.1) (2026-10-21)
|
|
7
13
|
|
|
8
14
|
### 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.2",
|
|
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/api": "4.10.1-dev.
|
|
75
|
-
"@faststore/
|
|
76
|
-
"@faststore/
|
|
77
|
-
"@faststore/
|
|
78
|
-
"@faststore/
|
|
74
|
+
"@faststore/api": "4.10.1-dev.2",
|
|
75
|
+
"@faststore/diagnostics": "4.10.1-dev.2",
|
|
76
|
+
"@faststore/ui": "4.10.1-dev.2",
|
|
77
|
+
"@faststore/lighthouse": "4.10.1-dev.2",
|
|
78
|
+
"@faststore/sdk": "4.10.1-dev.2"
|
|
79
79
|
},
|
|
80
80
|
"devDependencies": {
|
|
81
81
|
"@cypress/code-coverage": "^3.12.1",
|
package/src/pages/[slug]/p.tsx
CHANGED
|
@@ -85,14 +85,18 @@ const OG_PRODUCT_CONDITION_BY_SCHEMA: Record<string, string> = {
|
|
|
85
85
|
'https://schema.org/UsedCondition': 'used',
|
|
86
86
|
}
|
|
87
87
|
|
|
88
|
-
type Props =
|
|
88
|
+
type Props = {
|
|
89
|
+
sections: PDPContentType['sections']
|
|
90
|
+
settings: PDPContentType['settings']
|
|
89
91
|
data: ServerProductQueryQuery
|
|
90
92
|
globalSections: GlobalSectionsData
|
|
93
|
+
offers: ReturnType<typeof toProductJsonLdOffer>
|
|
91
94
|
meta: {
|
|
92
95
|
title: string
|
|
93
96
|
description: string
|
|
94
97
|
canonical: string
|
|
95
98
|
}
|
|
99
|
+
key: string
|
|
96
100
|
}
|
|
97
101
|
|
|
98
102
|
// Array merging strategy from deepmerge that makes client arrays overwrite server array
|
|
@@ -500,7 +504,8 @@ export const getStaticProps: GetStaticProps<
|
|
|
500
504
|
return {
|
|
501
505
|
props: {
|
|
502
506
|
data,
|
|
503
|
-
|
|
507
|
+
sections: cmsPage.sections,
|
|
508
|
+
settings: cmsPage.settings,
|
|
504
509
|
meta,
|
|
505
510
|
offers,
|
|
506
511
|
globalSections: globalSectionsResult,
|
|
@@ -17,7 +17,9 @@ import { getPLP, type PLPContentType } from '../cms/plp'
|
|
|
17
17
|
import type { ContentOptions, ContentParams } from './types'
|
|
18
18
|
import { isBranchPreview, isContentPlatformSource } from './utils'
|
|
19
19
|
|
|
20
|
-
type ContentResult = ContentData |
|
|
20
|
+
type ContentResult = ContentData | PageContentType
|
|
21
|
+
|
|
22
|
+
const CONTENT_AUTHOR_FIELDS = ['createdBy', 'updatedBy'] as const
|
|
21
23
|
|
|
22
24
|
type ContentListCacheEntry = {
|
|
23
25
|
expiresAt: number
|
|
@@ -163,7 +165,7 @@ export class ContentService {
|
|
|
163
165
|
private async listAndFillEntries(
|
|
164
166
|
serviceParams: EntryPathParams,
|
|
165
167
|
isPreview: boolean
|
|
166
|
-
): Promise<{ data:
|
|
168
|
+
): Promise<{ data: PageContentType[] }> {
|
|
167
169
|
// TODO: This should be temporary until the cp data-plane have a search engine.
|
|
168
170
|
const MAX_PAGES = 25
|
|
169
171
|
const allEntries: ContentEntry[] = []
|
|
@@ -189,7 +191,7 @@ export class ContentService {
|
|
|
189
191
|
entries: ContentEntry[],
|
|
190
192
|
serviceParams: EntryPathParams,
|
|
191
193
|
isPreview: boolean
|
|
192
|
-
): Promise<{ data:
|
|
194
|
+
): Promise<{ data: PageContentType[] }> {
|
|
193
195
|
const data = await Promise.all(
|
|
194
196
|
entries.map(async (entry) => {
|
|
195
197
|
const entryData = await this.getEntryData(
|
|
@@ -220,15 +222,21 @@ export class ContentService {
|
|
|
220
222
|
throw new Error(`${operation} requires entryId or slug`)
|
|
221
223
|
}
|
|
222
224
|
|
|
225
|
+
const entry = await this.loadEntry(params, isPreview)
|
|
226
|
+
|
|
227
|
+
return withoutContentAuthorMetadata(entry as PageContentType)
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
private loadEntry(params: EntryPathParams, isPreview: boolean) {
|
|
223
231
|
if (isPreview) {
|
|
224
232
|
return params.entryId
|
|
225
|
-
?
|
|
226
|
-
:
|
|
233
|
+
? this.clientCP.previewEntryById(params)
|
|
234
|
+
: this.clientCP.previewEntryBySlug(params)
|
|
227
235
|
}
|
|
228
236
|
|
|
229
237
|
return params.entryId
|
|
230
|
-
?
|
|
231
|
-
:
|
|
238
|
+
? this.clientCP.getEntry(params)
|
|
239
|
+
: this.clientCP.getEntryBySlug(params)
|
|
232
240
|
}
|
|
233
241
|
|
|
234
242
|
private async fetchFirstEntryFromList(
|
|
@@ -341,16 +349,25 @@ export class ContentService {
|
|
|
341
349
|
private mergeEntryWithData(
|
|
342
350
|
entry: ContentEntry,
|
|
343
351
|
data: PageContentType
|
|
344
|
-
):
|
|
352
|
+
): PageContentType {
|
|
345
353
|
return {
|
|
346
|
-
...
|
|
347
|
-
...data,
|
|
354
|
+
...withoutContentAuthorMetadata(data),
|
|
348
355
|
id: entry.id,
|
|
349
356
|
name: entry.name ?? '',
|
|
350
357
|
}
|
|
351
358
|
}
|
|
352
359
|
}
|
|
353
360
|
|
|
361
|
+
function withoutContentAuthorMetadata<T extends object>(value: T): T {
|
|
362
|
+
const content = { ...value } as Record<string, unknown>
|
|
363
|
+
|
|
364
|
+
for (const field of CONTENT_AUTHOR_FIELDS) {
|
|
365
|
+
delete content[field]
|
|
366
|
+
}
|
|
367
|
+
|
|
368
|
+
return content as T
|
|
369
|
+
}
|
|
370
|
+
|
|
354
371
|
function isNotFoundError(err: unknown): boolean {
|
|
355
372
|
if (err instanceof MissingContentError) return true
|
|
356
373
|
if (err instanceof Error && /\b404\b/.test(err.message)) return true
|
|
@@ -39,7 +39,17 @@ const entryData: Record<string, Record<string, unknown>> = {
|
|
|
39
39
|
},
|
|
40
40
|
}
|
|
41
41
|
|
|
42
|
-
const toEntry = (id: string) => ({
|
|
42
|
+
const toEntry = (id: string): ContentEntry => ({
|
|
43
|
+
id,
|
|
44
|
+
name: id,
|
|
45
|
+
account: 'example-account',
|
|
46
|
+
storeId: 'faststore',
|
|
47
|
+
createdAt: '2026-01-01T00:00:00.000Z',
|
|
48
|
+
updatedAt: '2026-01-02T00:00:00.000Z',
|
|
49
|
+
createdBy: 'editor@example.com',
|
|
50
|
+
updatedBy: 'other@example.com',
|
|
51
|
+
slug: id,
|
|
52
|
+
})
|
|
43
53
|
|
|
44
54
|
function createFakeClientCP(pages: string[][]) {
|
|
45
55
|
return {
|
|
@@ -52,6 +62,8 @@ function createFakeClientCP(pages: string[][]) {
|
|
|
52
62
|
}),
|
|
53
63
|
getEntry: vi.fn(async ({ entryId }: EntryPathParams) => ({
|
|
54
64
|
...entryData[entryId as string],
|
|
65
|
+
createdBy: 'payload@example.com',
|
|
66
|
+
updatedBy: 'payload@example.com',
|
|
55
67
|
})),
|
|
56
68
|
previewEntryById: vi.fn(async ({ entryId }: EntryPathParams) => ({
|
|
57
69
|
...entryData[entryId as string],
|
|
@@ -173,6 +185,33 @@ describe('ContentService', () => {
|
|
|
173
185
|
vi.useRealTimers()
|
|
174
186
|
})
|
|
175
187
|
|
|
188
|
+
it('keeps Content Platform author emails out of public page content', async () => {
|
|
189
|
+
const { service, clientCP } = createServiceWithClient()
|
|
190
|
+
clientCP.getEntryBySlug.mockResolvedValueOnce({
|
|
191
|
+
sections: [{ name: 'Direct' }],
|
|
192
|
+
createdBy: 'editor@example.com',
|
|
193
|
+
updatedBy: 'other@example.com',
|
|
194
|
+
})
|
|
195
|
+
|
|
196
|
+
const directPage = await service.getSingleContent({
|
|
197
|
+
contentType: 'pdp',
|
|
198
|
+
slug: 'product-slug',
|
|
199
|
+
})
|
|
200
|
+
const { data } = await service.getMultipleContent({ contentType: 'pdp' })
|
|
201
|
+
const listedPage = data[0]
|
|
202
|
+
|
|
203
|
+
expect(directPage.sections).toEqual([{ name: 'Direct' }])
|
|
204
|
+
expect(directPage).not.toHaveProperty('createdBy')
|
|
205
|
+
expect(directPage).not.toHaveProperty('updatedBy')
|
|
206
|
+
expect(listedPage.id).toBe('generic')
|
|
207
|
+
expect(listedPage.name).toBe('generic')
|
|
208
|
+
expect(listedPage.sections).toEqual([{ name: 'Generic' }])
|
|
209
|
+
expect(listedPage).not.toHaveProperty('createdBy')
|
|
210
|
+
expect(listedPage).not.toHaveProperty('updatedBy')
|
|
211
|
+
expect(listedPage).not.toHaveProperty('account')
|
|
212
|
+
expect(listedPage).not.toHaveProperty('storeId')
|
|
213
|
+
})
|
|
214
|
+
|
|
176
215
|
it('shares one list and entry fetch across concurrent PLPs with different slugs', async () => {
|
|
177
216
|
const { service, clientCP } = createServiceWithClient()
|
|
178
217
|
|