Skip to content

Commit

Permalink
clean up
Browse files Browse the repository at this point in the history
  • Loading branch information
fpbrault committed Nov 12, 2024
1 parent 9ddd23d commit 0a6bd4e
Showing 1 changed file with 29 additions and 28 deletions.
57 changes: 29 additions & 28 deletions packages/samples/headless-ssr-commerce/e2e/cart/cart.spec.ts
Original file line number Diff line number Diff line change
@@ -1,34 +1,35 @@
import {test, expect} from './cart.fixture';

test.beforeEach(async ({page, context}) => {
await context.addCookies([
{
name: 'headless-cart',
value: JSON.stringify([
{
name: 'Waxique Epoxy Wax',
price: 33,
productId: 'SP03973_00001',
quantity: 1,
},
{
name: 'Khaki Bottle',
price: 16,
productId: 'SP03929_00012',
quantity: 2,
},
{
name: 'Waxum Wax Package',
price: 27,
productId: 'SP03972_00001',
quantity: 1,
},
]),
path: '/',
domain: 'localhost',
},
]);
const cartCookie = [
{
name: 'headless-cart',
value: JSON.stringify([
{
name: 'Waxique Epoxy Wax',
price: 33,
productId: 'SP03973_00001',
quantity: 1,
},
{
name: 'Khaki Bottle',
price: 16,
productId: 'SP03929_00012',
quantity: 2,
},
{
name: 'Waxum Wax Package',
price: 27,
productId: 'SP03972_00001',
quantity: 1,
},
]),
path: '/',
domain: 'localhost',
},
];

test.beforeEach(async ({page, context}) => {
await context.addCookies(cartCookie);
await page.goto('/cart');
});

Expand Down

0 comments on commit 0a6bd4e

Please sign in to comment.