|
1 | 1 | import { faker } from "@faker-js/faker" |
2 | 2 |
|
3 | 3 | import { test, expect } from "../fixtures/tokenizedPage" |
4 | | -import { euAddress, euAddress2 } from "../utils/addresses" |
| 4 | +import { euAddress, euAddress2, usAddress } from "../utils/addresses" |
5 | 5 |
|
6 | 6 | const customerEmail = faker.internet.email().toLocaleLowerCase() |
7 | 7 |
|
@@ -263,6 +263,45 @@ test.describe("with customer email and shipping country code lock", () => { |
263 | 263 | }) |
264 | 264 | }) |
265 | 265 |
|
| 266 | +test.describe("with digital product and shipping country code lock", () => { |
| 267 | + test.use({ |
| 268 | + defaultParams: { |
| 269 | + order: "digital", |
| 270 | + orderAttributes: { |
| 271 | + customer_email: customerEmail, |
| 272 | + shipping_country_code_lock: "IT", |
| 273 | + }, |
| 274 | + }, |
| 275 | + }) |
| 276 | + |
| 277 | + test.skip("Checkout different country code address", async ({ |
| 278 | + checkoutPage, |
| 279 | + }) => { |
| 280 | + await checkoutPage.checkOrderSummary("Order Summary") |
| 281 | + |
| 282 | + const email = await checkoutPage.getCustomerMail() |
| 283 | + |
| 284 | + await expect(email).toHaveValue(customerEmail) |
| 285 | + |
| 286 | + await checkoutPage.checkStep("Customer", "open") |
| 287 | + |
| 288 | + await checkoutPage.setBillingAddress() |
| 289 | + |
| 290 | + await checkoutPage.selectCountry("billing_address", "FR") |
| 291 | + await checkoutPage.page.fill( |
| 292 | + "[data-testid=input_billing_address_state_code]", |
| 293 | + "PA" |
| 294 | + ) |
| 295 | + |
| 296 | + await checkoutPage.isVisibleShipToDifferentAddress(false) |
| 297 | + |
| 298 | + await checkoutPage.checkButton({ type: "Customer", status: "enabled" }) |
| 299 | + |
| 300 | + await checkoutPage.save("Customer") |
| 301 | + await checkoutPage.checkStep("Customer", "close") |
| 302 | + }) |
| 303 | +}) |
| 304 | + |
266 | 305 | test.describe("with shipping country code lock and different address", () => { |
267 | 306 | test.use({ |
268 | 307 | defaultParams: { |
|
0 commit comments