@shopware-ag/acceptance-test-suite 5.0.1 → 5.2.0

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/dist/index.mjs CHANGED
@@ -385,16 +385,16 @@ const test$c = test$e.extend({
385
385
  ]
386
386
  });
387
387
 
388
- var __defProp$A = Object.defineProperty;
389
- var __defNormalProp$A = (obj, key, value) => key in obj ? __defProp$A(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
390
- var __publicField$A = (obj, key, value) => {
391
- __defNormalProp$A(obj, typeof key !== "symbol" ? key + "" : key, value);
388
+ var __defProp$F = Object.defineProperty;
389
+ var __defNormalProp$F = (obj, key, value) => key in obj ? __defProp$F(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
390
+ var __publicField$F = (obj, key, value) => {
391
+ __defNormalProp$F(obj, typeof key !== "symbol" ? key + "" : key, value);
392
392
  return value;
393
393
  };
394
394
  const _AdminApiContext = class _AdminApiContext {
395
395
  constructor(context, options) {
396
- __publicField$A(this, "context");
397
- __publicField$A(this, "options");
396
+ __publicField$F(this, "context");
397
+ __publicField$F(this, "options");
398
398
  this.context = context;
399
399
  this.options = options;
400
400
  }
@@ -486,7 +486,7 @@ const _AdminApiContext = class _AdminApiContext {
486
486
  return this.context.head(url, options);
487
487
  }
488
488
  };
489
- __publicField$A(_AdminApiContext, "defaultOptions", {
489
+ __publicField$F(_AdminApiContext, "defaultOptions", {
490
490
  app_url: process.env["APP_URL"],
491
491
  client_id: process.env["SHOPWARE_ACCESS_KEY_ID"],
492
492
  client_secret: process.env["SHOPWARE_SECRET_ACCESS_KEY"],
@@ -496,16 +496,16 @@ __publicField$A(_AdminApiContext, "defaultOptions", {
496
496
  });
497
497
  let AdminApiContext = _AdminApiContext;
498
498
 
499
- var __defProp$z = Object.defineProperty;
500
- var __defNormalProp$z = (obj, key, value) => key in obj ? __defProp$z(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
501
- var __publicField$z = (obj, key, value) => {
502
- __defNormalProp$z(obj, typeof key !== "symbol" ? key + "" : key, value);
499
+ var __defProp$E = Object.defineProperty;
500
+ var __defNormalProp$E = (obj, key, value) => key in obj ? __defProp$E(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
501
+ var __publicField$E = (obj, key, value) => {
502
+ __defNormalProp$E(obj, typeof key !== "symbol" ? key + "" : key, value);
503
503
  return value;
504
504
  };
505
505
  const _StoreApiContext = class _StoreApiContext {
506
506
  constructor(context, options) {
507
- __publicField$z(this, "context");
508
- __publicField$z(this, "options");
507
+ __publicField$E(this, "context");
508
+ __publicField$E(this, "options");
509
509
  this.context = context;
510
510
  this.options = options;
511
511
  }
@@ -564,21 +564,21 @@ const _StoreApiContext = class _StoreApiContext {
564
564
  return this.context.head(url, options);
565
565
  }
566
566
  };
567
- __publicField$z(_StoreApiContext, "defaultOptions", {
567
+ __publicField$E(_StoreApiContext, "defaultOptions", {
568
568
  app_url: process.env["APP_URL"],
569
569
  ignoreHTTPSErrors: true
570
570
  });
571
571
  let StoreApiContext = _StoreApiContext;
572
572
 
573
- var __defProp$y = Object.defineProperty;
574
- var __defNormalProp$y = (obj, key, value) => key in obj ? __defProp$y(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
575
- var __publicField$y = (obj, key, value) => {
576
- __defNormalProp$y(obj, typeof key !== "symbol" ? key + "" : key, value);
573
+ var __defProp$D = Object.defineProperty;
574
+ var __defNormalProp$D = (obj, key, value) => key in obj ? __defProp$D(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
575
+ var __publicField$D = (obj, key, value) => {
576
+ __defNormalProp$D(obj, typeof key !== "symbol" ? key + "" : key, value);
577
577
  return value;
578
578
  };
579
579
  class MailpitApiContext {
580
580
  constructor(context) {
581
- __publicField$y(this, "context");
581
+ __publicField$D(this, "context");
582
582
  this.context = context;
583
583
  }
584
584
  /**
@@ -875,17 +875,17 @@ const test$a = test$e.extend({
875
875
  }
876
876
  });
877
877
 
878
- var __defProp$x = Object.defineProperty;
879
- var __defNormalProp$x = (obj, key, value) => key in obj ? __defProp$x(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
880
- var __publicField$x = (obj, key, value) => {
881
- __defNormalProp$x(obj, typeof key !== "symbol" ? key + "" : key, value);
878
+ var __defProp$C = Object.defineProperty;
879
+ var __defNormalProp$C = (obj, key, value) => key in obj ? __defProp$C(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
880
+ var __publicField$C = (obj, key, value) => {
881
+ __defNormalProp$C(obj, typeof key !== "symbol" ? key + "" : key, value);
882
882
  return value;
883
883
  };
884
884
  class Actor {
885
885
  constructor(name, page) {
886
- __publicField$x(this, "page");
887
- __publicField$x(this, "name");
888
- __publicField$x(this, "expects", expect);
886
+ __publicField$C(this, "page");
887
+ __publicField$C(this, "name");
888
+ __publicField$C(this, "expects", expect);
889
889
  this.name = name;
890
890
  this.page = page;
891
891
  }
@@ -934,31 +934,31 @@ function createRandomImage(width = 800, height = 600) {
934
934
  return new Image(width, height, buffer);
935
935
  }
936
936
 
937
- var __defProp$w = Object.defineProperty;
938
- var __defNormalProp$w = (obj, key, value) => key in obj ? __defProp$w(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
939
- var __publicField$w = (obj, key, value) => {
940
- __defNormalProp$w(obj, typeof key !== "symbol" ? key + "" : key, value);
937
+ var __defProp$B = Object.defineProperty;
938
+ var __defNormalProp$B = (obj, key, value) => key in obj ? __defProp$B(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
939
+ var __publicField$B = (obj, key, value) => {
940
+ __defNormalProp$B(obj, typeof key !== "symbol" ? key + "" : key, value);
941
941
  return value;
942
942
  };
943
943
  class TestDataService {
944
944
  constructor(AdminApiClient, IdProvider, options) {
945
- __publicField$w(this, "AdminApiClient");
946
- __publicField$w(this, "IdProvider");
947
- __publicField$w(this, "namePrefix", "Test-");
948
- __publicField$w(this, "nameSuffix", "");
949
- __publicField$w(this, "defaultSalesChannel");
950
- __publicField$w(this, "defaultTaxId");
951
- __publicField$w(this, "defaultCurrencyId");
952
- __publicField$w(this, "defaultCategoryId");
953
- __publicField$w(this, "defaultLanguageId");
954
- __publicField$w(this, "defaultCountryId");
955
- __publicField$w(this, "defaultCustomerGroupId");
945
+ __publicField$B(this, "AdminApiClient");
946
+ __publicField$B(this, "IdProvider");
947
+ __publicField$B(this, "namePrefix", "Test-");
948
+ __publicField$B(this, "nameSuffix", "");
949
+ __publicField$B(this, "defaultSalesChannel");
950
+ __publicField$B(this, "defaultTaxId");
951
+ __publicField$B(this, "defaultCurrencyId");
952
+ __publicField$B(this, "defaultCategoryId");
953
+ __publicField$B(this, "defaultLanguageId");
954
+ __publicField$B(this, "defaultCountryId");
955
+ __publicField$B(this, "defaultCustomerGroupId");
956
956
  /**
957
957
  * Configures if an automated cleanup of the data should be executed.
958
958
  *
959
959
  * @private
960
960
  */
961
- __publicField$w(this, "shouldCleanUp", true);
961
+ __publicField$B(this, "shouldCleanUp", true);
962
962
  /**
963
963
  * Configuration of higher priority entities for the cleanup operation.
964
964
  * These entities will be deleted before others.
@@ -966,19 +966,19 @@ class TestDataService {
966
966
  *
967
967
  * @private
968
968
  */
969
- __publicField$w(this, "highPriorityEntities", ["order", "product", "landing_page"]);
969
+ __publicField$B(this, "highPriorityEntities", ["order", "product", "landing_page"]);
970
970
  /**
971
971
  * A registry of all created records.
972
972
  *
973
973
  * @private
974
974
  */
975
- __publicField$w(this, "createdRecords", []);
975
+ __publicField$B(this, "createdRecords", []);
976
976
  /**
977
977
  * Function that generates combinations from n number of arrays
978
978
  * with m number of elements in them.
979
979
  * @param array
980
980
  */
981
- __publicField$w(this, "combineAll", (array) => {
981
+ __publicField$B(this, "combineAll", (array) => {
982
982
  const result = [];
983
983
  const max = array.length - 1;
984
984
  const helper = (tmpArray, i) => {
@@ -1080,6 +1080,51 @@ class TestDataService {
1080
1080
  const productOverrides = Object.assign({}, priceRange, overrides);
1081
1081
  return this.createBasicProduct(productOverrides, taxId, currencyId);
1082
1082
  }
1083
+ /**
1084
+ * Creates basic variant products based on property group.
1085
+ *
1086
+ * @param parentProduct Parent product of the variants
1087
+ * @param propertyGroups Property group collection which contain options
1088
+ * @param overrides - Specific data overrides that will be applied to the variant data struct.
1089
+ */
1090
+ async createVariantProducts(parentProduct, propertyGroups, overrides = {}) {
1091
+ const productVariantCandidates = [];
1092
+ for (const propertyGroup of propertyGroups) {
1093
+ const propertyGroupOptions = await this.getPropertyGroupOptions(propertyGroup.id);
1094
+ const propertyGroupOptionsCollection = [];
1095
+ for (const propertyGroupOption of propertyGroupOptions) {
1096
+ propertyGroupOptionsCollection.push({ id: propertyGroupOption.id });
1097
+ const productConfiguratorResponse = await this.AdminApiClient.post("product-configurator-setting?_response=detail", {
1098
+ data: {
1099
+ id: this.IdProvider.getIdPair().uuid,
1100
+ productId: parentProduct.id,
1101
+ optionId: propertyGroupOption.id
1102
+ }
1103
+ });
1104
+ expect(productConfiguratorResponse.ok()).toBeTruthy();
1105
+ }
1106
+ productVariantCandidates.push(propertyGroupOptionsCollection);
1107
+ }
1108
+ const productVariantCombinations = this.combineAll(productVariantCandidates);
1109
+ const variantProducts = [];
1110
+ let index = 1;
1111
+ for (const productVariantCombination of productVariantCombinations) {
1112
+ const variantOverrides = {
1113
+ parentId: parentProduct.id,
1114
+ productNumber: parentProduct.productNumber + "." + index,
1115
+ options: productVariantCombination
1116
+ };
1117
+ const overrideCollection = Object.assign({}, overrides, variantOverrides);
1118
+ variantProducts.push(await this.createBasicProduct(overrideCollection));
1119
+ index++;
1120
+ }
1121
+ await this.AdminApiClient.post("_action/indexing/product.indexer?_response=detail", {
1122
+ data: {
1123
+ offset: 0
1124
+ }
1125
+ });
1126
+ return variantProducts;
1127
+ }
1083
1128
  /**
1084
1129
  * Creates a basic manufacturer without images or other special configuration.
1085
1130
  *
@@ -1355,6 +1400,48 @@ class TestDataService {
1355
1400
  this.addCreatedRecord("payment_method", paymentMethod.id);
1356
1401
  return paymentMethod;
1357
1402
  }
1403
+ /**
1404
+ * Creates a payment method with one randomly generated image.
1405
+ *
1406
+ * @param overrides - Specific data overrides that will be applied to the payment method data struct.
1407
+ */
1408
+ async createPaymentMethodWithImage(overrides = {}) {
1409
+ const paymentMethod = await this.createBasicPaymentMethod(overrides);
1410
+ const media = await this.createMediaPNG();
1411
+ await this.assignPaymentMethodMedia(paymentMethod.id, media.id);
1412
+ return paymentMethod;
1413
+ }
1414
+ /**
1415
+ * Creates a new basic shipping method with random delivery time.
1416
+ *
1417
+ * @param overrides - Specific data overrides that will be applied to the shipping method data struct.
1418
+ */
1419
+ async createBasicShippingMethod(overrides = {}) {
1420
+ const deliveryTime = await this.getAllDeliveryTimeResources();
1421
+ overrides.availabilityRuleId ?? (overrides.availabilityRuleId = (await this.getRule("Always valid (Default)")).id);
1422
+ const basicShippingMethod = this.getBasicShippingMethodStruct(
1423
+ deliveryTime[0].id,
1424
+ overrides
1425
+ );
1426
+ const shippingMethodResponse = await this.AdminApiClient.post("shipping-method?_response=detail", {
1427
+ data: basicShippingMethod
1428
+ });
1429
+ expect(shippingMethodResponse.ok()).toBeTruthy();
1430
+ const { data: shippingMethod } = await shippingMethodResponse.json();
1431
+ this.addCreatedRecord("shipping_method", shippingMethod.id);
1432
+ return shippingMethod;
1433
+ }
1434
+ /**
1435
+ * Creates a shipping method with one randomly generated image.
1436
+ *
1437
+ * @param overrides - Specific data overrides that will be applied to the shipping method data struct.
1438
+ */
1439
+ async createShippingMethodWithImage(overrides = {}) {
1440
+ const shippingMethod = await this.createBasicShippingMethod(overrides);
1441
+ const media = await this.createMediaPNG();
1442
+ await this.assignShippingMethodMedia(shippingMethod.id, media.id);
1443
+ return shippingMethod;
1444
+ }
1358
1445
  /**
1359
1446
  * Creates a new basic rule with the condition cart amount >= 1.
1360
1447
  *
@@ -1387,107 +1474,35 @@ class TestDataService {
1387
1474
  return layout;
1388
1475
  }
1389
1476
  /**
1390
- * Creates a payment method with one randomly generated image.
1391
- *
1392
- * @param overrides - Specific data overrides that will be applied to the payment method data struct.
1393
- */
1394
- async createPaymentMethodWithImage(overrides = {}) {
1395
- const paymentMethod = await this.createBasicPaymentMethod(overrides);
1396
- const media = await this.createMediaPNG();
1397
- await this.assignPaymentMethodMedia(paymentMethod.id, media.id);
1398
- return paymentMethod;
1399
- }
1400
- /**
1401
- * Creates basic variant products based on property group.
1402
- *
1403
- * @param parentProduct Parent product of the variants
1404
- * @param propertyGroups Property group collection which contain options
1405
- * @param overrides - Specific data overrides that will be applied to the variant data struct.
1406
- */
1407
- async createVariantProducts(parentProduct, propertyGroups, overrides = {}) {
1408
- const productVariantCandidates = [];
1409
- for (const propertyGroup of propertyGroups) {
1410
- const propertyGroupOptions = await this.getPropertyGroupOptions(propertyGroup.id);
1411
- const propertyGroupOptionsCollection = [];
1412
- for (const propertyGroupOption of propertyGroupOptions) {
1413
- propertyGroupOptionsCollection.push({ id: propertyGroupOption.id });
1414
- const productConfiguratorResponse = await this.AdminApiClient.post("product-configurator-setting?_response=detail", {
1415
- data: {
1416
- id: this.IdProvider.getIdPair().uuid,
1417
- productId: parentProduct.id,
1418
- optionId: propertyGroupOption.id
1419
- }
1420
- });
1421
- expect(productConfiguratorResponse.ok()).toBeTruthy();
1422
- }
1423
- productVariantCandidates.push(propertyGroupOptionsCollection);
1424
- }
1425
- const productVariantCombinations = this.combineAll(productVariantCandidates);
1426
- const variantProducts = [];
1427
- let index = 1;
1428
- for (const productVariantCombination of productVariantCombinations) {
1429
- const variantOverrides = {
1430
- parentId: parentProduct.id,
1431
- productNumber: parentProduct.productNumber + "." + index,
1432
- options: productVariantCombination
1433
- };
1434
- const overrideCollection = Object.assign({}, overrides, variantOverrides);
1435
- variantProducts.push(await this.createBasicProduct(overrideCollection));
1436
- index++;
1437
- }
1438
- await this.AdminApiClient.post("_action/indexing/product.indexer?_response=detail", {
1439
- data: {
1440
- offset: 0
1441
- }
1442
- });
1443
- return variantProducts;
1444
- }
1445
- /**
1446
- * Creates a shipping method with one randomly generated image.
1477
+ * Creates a random country
1447
1478
  *
1448
- * @param overrides - Specific data overrides that will be applied to the shipping method data struct.
1479
+ * @param overrides - Specific data overrides that will be applied to the country data struct.
1449
1480
  */
1450
- async createShippingMethodWithImage(overrides = {}) {
1451
- const shippingMethod = await this.createBasicShippingMethod(overrides);
1452
- const media = await this.createMediaPNG();
1453
- await this.assignShippingMethodMedia(shippingMethod.id, media.id);
1454
- return shippingMethod;
1455
- }
1456
- /**
1457
- * Creates a new basic shipping method with random delivery time.
1458
- *
1459
- * @param overrides - Specific data overrides that will be applied to the shipping method data struct.
1460
- */
1461
- async createBasicShippingMethod(overrides = {}) {
1462
- const deliveryTime = await this.getAllDeliveryTimeResources();
1463
- overrides.availabilityRuleId ?? (overrides.availabilityRuleId = (await this.getRule("Always valid (Default)")).id);
1464
- const basicShippingMethod = this.getBasicShippingMethodStruct(
1465
- deliveryTime[0].id,
1466
- overrides
1467
- );
1468
- const shippingMethodResponse = await this.AdminApiClient.post("shipping-method?_response=detail", {
1469
- data: basicShippingMethod
1481
+ async createCountry(overrides = {}) {
1482
+ const basicCountry = this.getCountryStruct(overrides);
1483
+ const countryResponse = await this.AdminApiClient.post("country?_response=detail", {
1484
+ data: basicCountry
1470
1485
  });
1471
- expect(shippingMethodResponse.ok()).toBeTruthy();
1472
- const { data: shippingMethod } = await shippingMethodResponse.json();
1473
- this.addCreatedRecord("shipping_method", shippingMethod.id);
1474
- return shippingMethod;
1486
+ expect(countryResponse.ok()).toBeTruthy();
1487
+ const { data: country } = await countryResponse.json();
1488
+ this.addCreatedRecord("country", country.id);
1489
+ return country;
1475
1490
  }
1476
1491
  /**
1477
- * Assigns a media resource to a payment method as a logo.
1492
+ * Creates a random currency with default rounding of 2 decimals
1478
1493
  *
1479
- * @param paymentMethodId - The uuid of the payment method.
1480
- * @param mediaId - The uuid of the media resource.
1494
+ * @param roundingDecimals - Decimals of the rounding shown in Storefront, default value 2
1495
+ * @param overrides - Specific data overrides that will be applied to the currency data struct.
1481
1496
  */
1482
- async assignPaymentMethodMedia(paymentMethodId, mediaId) {
1483
- const paymentMethodResponse = await this.AdminApiClient.patch(`payment-method/${paymentMethodId}?_response=basic`, {
1484
- data: {
1485
- mediaId
1486
- }
1497
+ async createCurrency(overrides = {}, roundingDecimals = 2) {
1498
+ const basicCurrency = this.getCurrencyStruct(overrides, roundingDecimals);
1499
+ const currencyResponse = await this.AdminApiClient.post("currency?_response=detail", {
1500
+ data: basicCurrency
1487
1501
  });
1488
- expect(paymentMethodResponse.ok()).toBeTruthy();
1489
- const { data: paymentMethodMedia } = await paymentMethodResponse.json();
1490
- return paymentMethodMedia;
1502
+ expect(currencyResponse.ok()).toBeTruthy();
1503
+ const { data: currency } = await currencyResponse.json();
1504
+ this.addCreatedRecord("currency", currency.id);
1505
+ return currency;
1491
1506
  }
1492
1507
  /**
1493
1508
  * Assigns a media resource as the download of a digital product.
@@ -1532,33 +1547,54 @@ class TestDataService {
1532
1547
  return productMedia;
1533
1548
  }
1534
1549
  /**
1535
- * Assigns a media resource to a manufacturer as a logo.
1550
+ * Assigns a manufacturer to a product.
1536
1551
  *
1552
+ * @param productId - The uuid of the product.
1537
1553
  * @param manufacturerId - The uuid of the manufacturer.
1538
- * @param mediaId - The uuid of the media resource.
1539
1554
  */
1540
- async assignManufacturerMedia(manufacturerId, mediaId) {
1541
- const mediaResponse = await this.AdminApiClient.patch(`product-manufacturer/${manufacturerId}?_response=basic`, {
1555
+ async assignProductManufacturer(productId, manufacturerId) {
1556
+ await this.AdminApiClient.patch(`product/${productId}?_response=basic`, {
1542
1557
  data: {
1543
- mediaId
1558
+ manufacturerId
1544
1559
  }
1545
1560
  });
1546
- expect(mediaResponse.ok()).toBeTruthy();
1547
- const { data: manufacturerMedia } = await mediaResponse.json();
1548
- return manufacturerMedia;
1549
1561
  }
1550
1562
  /**
1551
- * Assigns a manufacturer to a product.
1563
+ * Assigns a country to a currency with default roundings of 2.
1552
1564
  *
1553
- * @param manufacturerId - The uuid of the manufacturer.
1554
- * @param productId - The uuid of the product.
1565
+ * @param currencyId - The uuid of currency.
1566
+ * @param countryId - The uuid of country.
1567
+ * @param roundingDecimals - The roundings of item and total values in storefront, default 2 decimals
1555
1568
  */
1556
- async assignManufacturerProduct(manufacturerId, productId) {
1557
- await this.AdminApiClient.patch(`product/${productId}?_response=basic`, {
1569
+ async assignCurrencyCountryRounding(currencyId, countryId, roundingDecimals = 2) {
1570
+ const syncCurrencyCountryRoundingResponse = await this.AdminApiClient.post("./_action/sync", {
1558
1571
  data: {
1559
- manufacturerId
1572
+ "write-currency-country-rounding": {
1573
+ entity: "currency_country_rounding",
1574
+ action: "upsert",
1575
+ payload: [
1576
+ {
1577
+ id: this.IdProvider.getIdPair().uuid,
1578
+ currencyId,
1579
+ countryId,
1580
+ itemRounding: {
1581
+ decimals: roundingDecimals,
1582
+ interval: 0.01,
1583
+ roundForNet: true
1584
+ },
1585
+ totalRounding: {
1586
+ decimals: roundingDecimals,
1587
+ interval: 0.01,
1588
+ roundForNet: true
1589
+ }
1590
+ }
1591
+ ]
1592
+ }
1560
1593
  }
1561
1594
  });
1595
+ expect(syncCurrencyCountryRoundingResponse.ok()).toBeTruthy();
1596
+ const { data: currencyCountry } = await syncCurrencyCountryRoundingResponse.json();
1597
+ return currencyCountry;
1562
1598
  }
1563
1599
  /**
1564
1600
  * Assigns a product to a category.
@@ -1590,6 +1626,115 @@ class TestDataService {
1590
1626
  }
1591
1627
  });
1592
1628
  }
1629
+ /**
1630
+ * Assigns a media resource to a manufacturer as a logo.
1631
+ *
1632
+ * @param manufacturerId - The uuid of the manufacturer.
1633
+ * @param mediaId - The uuid of the media resource.
1634
+ */
1635
+ async assignManufacturerMedia(manufacturerId, mediaId) {
1636
+ const mediaResponse = await this.AdminApiClient.patch(`product-manufacturer/${manufacturerId}?_response=basic`, {
1637
+ data: {
1638
+ mediaId
1639
+ }
1640
+ });
1641
+ expect(mediaResponse.ok()).toBeTruthy();
1642
+ const { data: manufacturerMedia } = await mediaResponse.json();
1643
+ return manufacturerMedia;
1644
+ }
1645
+ /**
1646
+ * Assigns a manufacturer to a product.
1647
+ *
1648
+ * @deprecated - Use `assignProductManufacturer` instead.
1649
+ *
1650
+ * @param manufacturerId - The uuid of the manufacturer.
1651
+ * @param productId - The uuid of the product.
1652
+ */
1653
+ async assignManufacturerProduct(manufacturerId, productId) {
1654
+ await this.assignProductManufacturer(productId, manufacturerId);
1655
+ }
1656
+ /**
1657
+ * Assigns a currency to a sales channel.
1658
+ *
1659
+ * @param salesChannelId - The uuid of the sales channel.
1660
+ * @param currencyId - The uuid of the currency.
1661
+ */
1662
+ async assignSalesChannelCurrency(salesChannelId, currencyId) {
1663
+ const syncSalesChannelResponse = await this.AdminApiClient.post("./_action/sync", {
1664
+ data: {
1665
+ "write-sales-channel": {
1666
+ entity: "sales_channel",
1667
+ action: "upsert",
1668
+ payload: [
1669
+ {
1670
+ id: salesChannelId,
1671
+ currencies: [{ id: currencyId }]
1672
+ }
1673
+ ]
1674
+ }
1675
+ }
1676
+ });
1677
+ expect(syncSalesChannelResponse.ok()).toBeTruthy();
1678
+ const { data: salesChannel } = await syncSalesChannelResponse.json();
1679
+ return salesChannel;
1680
+ }
1681
+ /**
1682
+ * Assigns a country to a sales channel.
1683
+ *
1684
+ * @param salesChannelId - The uuid of the sales channel.
1685
+ * @param countryId - The uuid of the country.
1686
+ */
1687
+ async assignSalesChannelCountry(salesChannelId, countryId) {
1688
+ const syncSalesChannelResponse = await this.AdminApiClient.post("./_action/sync", {
1689
+ data: {
1690
+ "write-sales-channel": {
1691
+ entity: "sales_channel",
1692
+ action: "upsert",
1693
+ payload: [
1694
+ {
1695
+ id: salesChannelId,
1696
+ countries: [{ id: countryId }]
1697
+ }
1698
+ ]
1699
+ }
1700
+ }
1701
+ });
1702
+ expect(syncSalesChannelResponse.ok()).toBeTruthy();
1703
+ const { data: salesChannel } = await syncSalesChannelResponse.json();
1704
+ return salesChannel;
1705
+ }
1706
+ /**
1707
+ * Assigns a media resource to a payment method as a logo.
1708
+ *
1709
+ * @param paymentMethodId - The uuid of the payment method.
1710
+ * @param mediaId - The uuid of the media resource.
1711
+ */
1712
+ async assignPaymentMethodMedia(paymentMethodId, mediaId) {
1713
+ const paymentMethodResponse = await this.AdminApiClient.patch(`payment-method/${paymentMethodId}?_response=basic`, {
1714
+ data: {
1715
+ mediaId
1716
+ }
1717
+ });
1718
+ expect(paymentMethodResponse.ok()).toBeTruthy();
1719
+ const { data: paymentMethodMedia } = await paymentMethodResponse.json();
1720
+ return paymentMethodMedia;
1721
+ }
1722
+ /**
1723
+ * Assigns a media resource to a shipping method as a logo.
1724
+ *
1725
+ * @param shippingMethodId - The uuid of the shipping method.
1726
+ * @param mediaId - The uuid of the media resource.
1727
+ */
1728
+ async assignShippingMethodMedia(shippingMethodId, mediaId) {
1729
+ const shippingMethodResponse = await this.AdminApiClient.patch(`shipping-method/${shippingMethodId}?_response=basic`, {
1730
+ data: {
1731
+ mediaId
1732
+ }
1733
+ });
1734
+ expect(shippingMethodResponse.ok()).toBeTruthy();
1735
+ const { data: shippingMethodMedia } = await shippingMethodResponse.json();
1736
+ return shippingMethodMedia;
1737
+ }
1593
1738
  /**
1594
1739
  * Retrieves a currency based on its ISO code.
1595
1740
  *
@@ -1650,22 +1795,6 @@ class TestDataService {
1650
1795
  const { data: result } = await response.json();
1651
1796
  return result[0];
1652
1797
  }
1653
- /**
1654
- * Assigns a media resource to a shipping method as a logo.
1655
- *
1656
- * @param shippingMethodId - The uuid of the shipping method.
1657
- * @param mediaId - The uuid of the media resource.
1658
- */
1659
- async assignShippingMethodMedia(shippingMethodId, mediaId) {
1660
- const shippingMethodResponse = await this.AdminApiClient.patch(`shipping-method/${shippingMethodId}?_response=basic`, {
1661
- data: {
1662
- mediaId
1663
- }
1664
- });
1665
- expect(shippingMethodResponse.ok()).toBeTruthy();
1666
- const { data: shippingMethodMedia } = await shippingMethodResponse.json();
1667
- return shippingMethodMedia;
1668
- }
1669
1798
  /**
1670
1799
  * Retrieves all delivery time resources.
1671
1800
  */
@@ -1873,6 +2002,12 @@ class TestDataService {
1873
2002
  data: deleteOperations
1874
2003
  });
1875
2004
  }
2005
+ isProduct(item) {
2006
+ return item.productNumber !== void 0;
2007
+ }
2008
+ isPromotion(item) {
2009
+ return item.code !== void 0;
2010
+ }
1876
2011
  /**
1877
2012
  * Convert a JS date object into a date-time compatible string.
1878
2013
  *
@@ -1881,6 +2016,60 @@ class TestDataService {
1881
2016
  convertDateTime(date) {
1882
2017
  return date.toISOString().slice(0, 19).replace("T", " ");
1883
2018
  }
2019
+ /**
2020
+ * Retrieves a country Id based on its iso2 code.
2021
+ *
2022
+ * @param iso2 - The iso2 code of the country, for example "DE".
2023
+ */
2024
+ async getCountryId(iso2) {
2025
+ const countryResponse = await this.AdminApiClient.post("search/country", {
2026
+ data: {
2027
+ limit: 1,
2028
+ filter: [{
2029
+ type: "equals",
2030
+ field: "iso",
2031
+ value: iso2
2032
+ }]
2033
+ }
2034
+ });
2035
+ const { data: result } = await countryResponse.json();
2036
+ return result[0];
2037
+ }
2038
+ getCountryStruct(overrides = {}) {
2039
+ const { uuid: countryUuid, id: countryId } = this.IdProvider.getIdPair();
2040
+ const basicCountry = {
2041
+ id: countryUuid,
2042
+ name: "Country-" + countryId,
2043
+ iso: "" + countryId.substring(0, 2),
2044
+ iso3: "" + countryId.substring(0, 3),
2045
+ active: true,
2046
+ shippingAvailable: true
2047
+ };
2048
+ return Object.assign({}, basicCountry, overrides);
2049
+ }
2050
+ getCurrencyStruct(overrides = {}, roundingDecimals) {
2051
+ const { uuid: currencyUuid, id: currencyId } = this.IdProvider.getIdPair();
2052
+ const basicCurrency = {
2053
+ id: currencyUuid,
2054
+ name: "Currency-" + currencyId,
2055
+ shortName: "CUR" + currencyId,
2056
+ isoCode: "" + currencyId.substring(0, 3),
2057
+ symbol: "C$",
2058
+ factor: 2.4,
2059
+ itemRounding: {
2060
+ decimals: roundingDecimals,
2061
+ interval: 0.01,
2062
+ roundForNet: true
2063
+ },
2064
+ totalRounding: {
2065
+ decimals: roundingDecimals,
2066
+ interval: 0.01,
2067
+ roundForNet: true
2068
+ },
2069
+ taxFreeFrom: 0
2070
+ };
2071
+ return Object.assign({}, basicCurrency, overrides);
2072
+ }
1884
2073
  getBasicProductStruct(taxId = this.defaultTaxId, currencyId = this.defaultCurrencyId, overrides = {}) {
1885
2074
  const { id: productId, uuid: productUuid } = this.IdProvider.getIdPair();
1886
2075
  const productName = `${this.namePrefix}Product-${productId}${this.nameSuffix}`;
@@ -2139,12 +2328,6 @@ class TestDataService {
2139
2328
  };
2140
2329
  return Object.assign({}, basicShippingMethod, overrides);
2141
2330
  }
2142
- isProduct(item) {
2143
- return item.productNumber !== void 0;
2144
- }
2145
- isPromotion(item) {
2146
- return item.code !== void 0;
2147
- }
2148
2331
  getBasicOrderStruct(lineItems, languageId, currency, paymentMethod, shippingMethod, orderState, deliveryState, transactionState, customer, customerAddress, salesChannelId = this.defaultSalesChannel.id, overrides = {}) {
2149
2332
  const date = /* @__PURE__ */ new Date();
2150
2333
  const orderDateTime = this.convertDateTime(date);
@@ -2430,16 +2613,16 @@ const test$8 = test$e.extend({
2430
2613
  }
2431
2614
  });
2432
2615
 
2433
- var __defProp$v = Object.defineProperty;
2434
- var __defNormalProp$v = (obj, key, value) => key in obj ? __defProp$v(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2435
- var __publicField$v = (obj, key, value) => {
2436
- __defNormalProp$v(obj, typeof key !== "symbol" ? key + "" : key, value);
2616
+ var __defProp$A = Object.defineProperty;
2617
+ var __defNormalProp$A = (obj, key, value) => key in obj ? __defProp$A(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2618
+ var __publicField$A = (obj, key, value) => {
2619
+ __defNormalProp$A(obj, typeof key !== "symbol" ? key + "" : key, value);
2437
2620
  return value;
2438
2621
  };
2439
2622
  class IdProvider {
2440
2623
  constructor(workerIndex, seed) {
2441
- __publicField$v(this, "workerIndex");
2442
- __publicField$v(this, "seed");
2624
+ __publicField$A(this, "workerIndex");
2625
+ __publicField$A(this, "seed");
2443
2626
  this.workerIndex = workerIndex;
2444
2627
  this.seed = seed;
2445
2628
  }
@@ -2513,45 +2696,72 @@ const test$7 = test$e.extend({
2513
2696
  ]
2514
2697
  });
2515
2698
 
2516
- var __defProp$u = Object.defineProperty;
2517
- var __defNormalProp$u = (obj, key, value) => key in obj ? __defProp$u(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2518
- var __publicField$u = (obj, key, value) => {
2519
- __defNormalProp$u(obj, typeof key !== "symbol" ? key + "" : key, value);
2699
+ var __defProp$z = Object.defineProperty;
2700
+ var __defNormalProp$z = (obj, key, value) => key in obj ? __defProp$z(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2701
+ var __publicField$z = (obj, key, value) => {
2702
+ __defNormalProp$z(obj, typeof key !== "symbol" ? key + "" : key, value);
2520
2703
  return value;
2521
2704
  };
2522
2705
  class Home {
2523
2706
  constructor(page) {
2524
2707
  this.page = page;
2525
- __publicField$u(this, "productImages");
2526
- __publicField$u(this, "productListItems");
2708
+ __publicField$z(this, "productImages");
2709
+ __publicField$z(this, "productListItems");
2710
+ __publicField$z(this, "languagesDropdown");
2711
+ __publicField$z(this, "currenciesDropdown");
2527
2712
  this.productImages = page.locator(".product-image-link");
2528
2713
  this.productListItems = page.getByRole("listitem");
2714
+ this.languagesDropdown = page.getByLabel("Shop settings").locator(".languages-menu");
2715
+ this.currenciesDropdown = page.getByLabel("Shop settings").locator(".currencies-menu");
2716
+ }
2717
+ async getListingItemByProductId(productId) {
2718
+ const listingItem = this.page.getByRole("listitem").filter({ has: this.page.locator(`[value="${productId}"]`) });
2719
+ const productImage = listingItem.locator(".product-image-link");
2720
+ const productRating = listingItem.locator(".product-rating");
2721
+ const productVariantCharacteristics = listingItem.locator(".product-variant-characteristics");
2722
+ const productDescription = listingItem.locator(".product-description");
2723
+ const productPriceUnit = listingItem.locator(".product-price-unit");
2724
+ const productCheapestPrice = listingItem.locator(".product-cheapest-price");
2725
+ const productPrice = listingItem.locator(".product-price");
2726
+ const productName = listingItem.locator(".product-name");
2727
+ const productAddToShoppingCart = listingItem.getByRole("button", { name: "Add to shopping cart" });
2728
+ return {
2729
+ productImage,
2730
+ productRating,
2731
+ productVariantCharacteristics,
2732
+ productDescription,
2733
+ productPriceUnit,
2734
+ productCheapestPrice,
2735
+ productPrice,
2736
+ productName,
2737
+ productAddToShoppingCart
2738
+ };
2529
2739
  }
2530
2740
  url() {
2531
2741
  return "./";
2532
2742
  }
2533
2743
  }
2534
2744
 
2535
- var __defProp$t = Object.defineProperty;
2536
- var __defNormalProp$t = (obj, key, value) => key in obj ? __defProp$t(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2537
- var __publicField$t = (obj, key, value) => {
2538
- __defNormalProp$t(obj, typeof key !== "symbol" ? key + "" : key, value);
2745
+ var __defProp$y = Object.defineProperty;
2746
+ var __defNormalProp$y = (obj, key, value) => key in obj ? __defProp$y(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2747
+ var __publicField$y = (obj, key, value) => {
2748
+ __defNormalProp$y(obj, typeof key !== "symbol" ? key + "" : key, value);
2539
2749
  return value;
2540
2750
  };
2541
2751
  let ProductDetail$1 = class ProductDetail {
2542
2752
  constructor(page) {
2543
2753
  this.page = page;
2544
- __publicField$t(this, "addToCartButton");
2545
- __publicField$t(this, "quantitySelect");
2546
- __publicField$t(this, "productSingleImage");
2547
- __publicField$t(this, "productSinglePrice");
2548
- __publicField$t(this, "productPriceRangesRow");
2549
- __publicField$t(this, "offCanvasCartTitle");
2550
- __publicField$t(this, "offCanvasCart");
2551
- __publicField$t(this, "offCanvasCartGoToCheckoutButton");
2552
- __publicField$t(this, "offCanvasLineItemImages");
2553
- __publicField$t(this, "offCanvasSummaryTotalPrice");
2554
- __publicField$t(this, "offCanvas");
2754
+ __publicField$y(this, "addToCartButton");
2755
+ __publicField$y(this, "quantitySelect");
2756
+ __publicField$y(this, "productSingleImage");
2757
+ __publicField$y(this, "productSinglePrice");
2758
+ __publicField$y(this, "productPriceRangesRow");
2759
+ __publicField$y(this, "offCanvasCartTitle");
2760
+ __publicField$y(this, "offCanvasCart");
2761
+ __publicField$y(this, "offCanvasCartGoToCheckoutButton");
2762
+ __publicField$y(this, "offCanvasLineItemImages");
2763
+ __publicField$y(this, "offCanvasSummaryTotalPrice");
2764
+ __publicField$y(this, "offCanvas");
2555
2765
  this.addToCartButton = page.getByRole("button", { name: "Add to shopping cart" });
2556
2766
  this.quantitySelect = page.getByLabel("Quantity", { exact: true });
2557
2767
  this.productSingleImage = page.locator(".gallery-slider-single-image");
@@ -2573,18 +2783,18 @@ let ProductDetail$1 = class ProductDetail {
2573
2783
  }
2574
2784
  };
2575
2785
 
2576
- var __defProp$s = Object.defineProperty;
2577
- var __defNormalProp$s = (obj, key, value) => key in obj ? __defProp$s(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2578
- var __publicField$s = (obj, key, value) => {
2579
- __defNormalProp$s(obj, typeof key !== "symbol" ? key + "" : key, value);
2786
+ var __defProp$x = Object.defineProperty;
2787
+ var __defNormalProp$x = (obj, key, value) => key in obj ? __defProp$x(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2788
+ var __publicField$x = (obj, key, value) => {
2789
+ __defNormalProp$x(obj, typeof key !== "symbol" ? key + "" : key, value);
2580
2790
  return value;
2581
2791
  };
2582
2792
  class Category {
2583
2793
  constructor(page) {
2584
2794
  this.page = page;
2585
- __publicField$s(this, "sortingSelect");
2586
- __publicField$s(this, "firstProductBuyButton");
2587
- __publicField$s(this, "noProductsFoundAlert");
2795
+ __publicField$x(this, "sortingSelect");
2796
+ __publicField$x(this, "firstProductBuyButton");
2797
+ __publicField$x(this, "noProductsFoundAlert");
2588
2798
  this.sortingSelect = page.getByLabel("Sorting");
2589
2799
  this.firstProductBuyButton = page.getByRole("button", { name: "Add to shopping cart" }).first();
2590
2800
  this.noProductsFoundAlert = page.getByText("No products found.");
@@ -2594,24 +2804,24 @@ class Category {
2594
2804
  }
2595
2805
  }
2596
2806
 
2597
- var __defProp$r = Object.defineProperty;
2598
- var __defNormalProp$r = (obj, key, value) => key in obj ? __defProp$r(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2599
- var __publicField$r = (obj, key, value) => {
2600
- __defNormalProp$r(obj, typeof key !== "symbol" ? key + "" : key, value);
2807
+ var __defProp$w = Object.defineProperty;
2808
+ var __defNormalProp$w = (obj, key, value) => key in obj ? __defProp$w(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2809
+ var __publicField$w = (obj, key, value) => {
2810
+ __defNormalProp$w(obj, typeof key !== "symbol" ? key + "" : key, value);
2601
2811
  return value;
2602
2812
  };
2603
2813
  class CheckoutCart {
2604
2814
  constructor(page) {
2605
2815
  this.page = page;
2606
- __publicField$r(this, "headline");
2607
- __publicField$r(this, "goToCheckoutButton");
2608
- __publicField$r(this, "enterPromoInput");
2609
- __publicField$r(this, "grandTotalPrice");
2610
- __publicField$r(this, "emptyCartAlert");
2611
- __publicField$r(this, "stockReachedAlert");
2612
- __publicField$r(this, "cartLineItemImages");
2613
- __publicField$r(this, "unitPriceInfo");
2614
- __publicField$r(this, "cartQuantityNumber");
2816
+ __publicField$w(this, "headline");
2817
+ __publicField$w(this, "goToCheckoutButton");
2818
+ __publicField$w(this, "enterPromoInput");
2819
+ __publicField$w(this, "grandTotalPrice");
2820
+ __publicField$w(this, "emptyCartAlert");
2821
+ __publicField$w(this, "stockReachedAlert");
2822
+ __publicField$w(this, "cartLineItemImages");
2823
+ __publicField$w(this, "unitPriceInfo");
2824
+ __publicField$w(this, "cartQuantityNumber");
2615
2825
  this.headline = page.getByRole("heading", { name: "Shopping cart" });
2616
2826
  this.goToCheckoutButton = page.getByRole("link", { name: "Go to checkout" });
2617
2827
  this.enterPromoInput = page.getByLabel("Promo code");
@@ -2652,25 +2862,25 @@ class CheckoutCart {
2652
2862
  }
2653
2863
  }
2654
2864
 
2655
- var __defProp$q = Object.defineProperty;
2656
- var __defNormalProp$q = (obj, key, value) => key in obj ? __defProp$q(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2657
- var __publicField$q = (obj, key, value) => {
2658
- __defNormalProp$q(obj, typeof key !== "symbol" ? key + "" : key, value);
2865
+ var __defProp$v = Object.defineProperty;
2866
+ var __defNormalProp$v = (obj, key, value) => key in obj ? __defProp$v(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2867
+ var __publicField$v = (obj, key, value) => {
2868
+ __defNormalProp$v(obj, typeof key !== "symbol" ? key + "" : key, value);
2659
2869
  return value;
2660
2870
  };
2661
2871
  class OffCanvasCart {
2662
2872
  constructor(page) {
2663
2873
  this.page = page;
2664
- __publicField$q(this, "headline");
2665
- __publicField$q(this, "itemCount");
2666
- __publicField$q(this, "goToCheckoutButton");
2667
- __publicField$q(this, "goToCartButton");
2668
- __publicField$q(this, "continueShoppingButton");
2669
- __publicField$q(this, "enterPromoInput");
2670
- __publicField$q(this, "submitDiscountButton");
2671
- __publicField$q(this, "subTotalPrice");
2672
- __publicField$q(this, "shippingCosts");
2673
- __publicField$q(this, "cartQuantityNumber");
2874
+ __publicField$v(this, "headline");
2875
+ __publicField$v(this, "itemCount");
2876
+ __publicField$v(this, "goToCheckoutButton");
2877
+ __publicField$v(this, "goToCartButton");
2878
+ __publicField$v(this, "continueShoppingButton");
2879
+ __publicField$v(this, "enterPromoInput");
2880
+ __publicField$v(this, "submitDiscountButton");
2881
+ __publicField$v(this, "subTotalPrice");
2882
+ __publicField$v(this, "shippingCosts");
2883
+ __publicField$v(this, "cartQuantityNumber");
2674
2884
  this.headline = page.getByRole("heading", { name: "Shopping cart" });
2675
2885
  this.itemCount = page.locator(".offcanvas-cart-header-count");
2676
2886
  this.goToCheckoutButton = page.getByRole("link", { name: "Go to checkout" });
@@ -2712,39 +2922,41 @@ class OffCanvasCart {
2712
2922
  }
2713
2923
  }
2714
2924
 
2715
- var __defProp$p = Object.defineProperty;
2716
- var __defNormalProp$p = (obj, key, value) => key in obj ? __defProp$p(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2717
- var __publicField$p = (obj, key, value) => {
2718
- __defNormalProp$p(obj, typeof key !== "symbol" ? key + "" : key, value);
2925
+ var __defProp$u = Object.defineProperty;
2926
+ var __defNormalProp$u = (obj, key, value) => key in obj ? __defProp$u(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2927
+ var __publicField$u = (obj, key, value) => {
2928
+ __defNormalProp$u(obj, typeof key !== "symbol" ? key + "" : key, value);
2719
2929
  return value;
2720
2930
  };
2721
2931
  class CheckoutConfirm {
2722
2932
  constructor(page) {
2723
2933
  this.page = page;
2724
- __publicField$p(this, "headline");
2725
- __publicField$p(this, "termsAndConditionsCheckbox");
2726
- __publicField$p(this, "immediateAccessToDigitalProductCheckbox");
2727
- __publicField$p(this, "grandTotalPrice");
2728
- __publicField$p(this, "submitOrderButton");
2934
+ __publicField$u(this, "headline");
2935
+ __publicField$u(this, "termsAndConditionsCheckbox");
2936
+ __publicField$u(this, "immediateAccessToDigitalProductCheckbox");
2937
+ __publicField$u(this, "grandTotalPrice");
2938
+ __publicField$u(this, "taxPrice");
2939
+ __publicField$u(this, "submitOrderButton");
2729
2940
  /**
2730
2941
  * Payment options
2731
2942
  */
2732
- __publicField$p(this, "paymentCashOnDelivery");
2733
- __publicField$p(this, "paymentPaidInAdvance");
2734
- __publicField$p(this, "paymentInvoice");
2943
+ __publicField$u(this, "paymentCashOnDelivery");
2944
+ __publicField$u(this, "paymentPaidInAdvance");
2945
+ __publicField$u(this, "paymentInvoice");
2735
2946
  /**
2736
2947
  * Shipping options
2737
2948
  */
2738
- __publicField$p(this, "shippingStandard");
2739
- __publicField$p(this, "shippingExpress");
2949
+ __publicField$u(this, "shippingStandard");
2950
+ __publicField$u(this, "shippingExpress");
2740
2951
  /**
2741
2952
  * Product details
2742
2953
  */
2743
- __publicField$p(this, "cartLineItemImages");
2954
+ __publicField$u(this, "cartLineItemImages");
2744
2955
  this.headline = page.getByRole("heading", { name: "Complete order" });
2745
2956
  this.termsAndConditionsCheckbox = page.getByLabel("I have read and accepted the general terms and conditions.");
2746
2957
  this.immediateAccessToDigitalProductCheckbox = page.getByLabel("I want immediate access to the digital content and I acknowledge that thereby I waive my right to cancel.");
2747
2958
  this.grandTotalPrice = page.locator(`dt:has-text('Grand total') + dd`);
2959
+ this.taxPrice = page.locator(`dt:text-matches('plus [0-9]\\+\\?% VAT') + dd`);
2748
2960
  this.submitOrderButton = page.getByRole("button", { name: "Submit order" });
2749
2961
  this.paymentCashOnDelivery = page.getByLabel("Cash on delivery");
2750
2962
  this.paymentPaidInAdvance = page.getByLabel("Paid in advance");
@@ -2758,23 +2970,25 @@ class CheckoutConfirm {
2758
2970
  }
2759
2971
  }
2760
2972
 
2761
- var __defProp$o = Object.defineProperty;
2762
- var __defNormalProp$o = (obj, key, value) => key in obj ? __defProp$o(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2763
- var __publicField$o = (obj, key, value) => {
2764
- __defNormalProp$o(obj, typeof key !== "symbol" ? key + "" : key, value);
2973
+ var __defProp$t = Object.defineProperty;
2974
+ var __defNormalProp$t = (obj, key, value) => key in obj ? __defProp$t(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2975
+ var __publicField$t = (obj, key, value) => {
2976
+ __defNormalProp$t(obj, typeof key !== "symbol" ? key + "" : key, value);
2765
2977
  return value;
2766
2978
  };
2767
2979
  class CheckoutFinish {
2768
2980
  constructor(page) {
2769
2981
  this.page = page;
2770
- __publicField$o(this, "headline");
2771
- __publicField$o(this, "orderNumberText");
2772
- __publicField$o(this, "grandTotalPrice");
2773
- __publicField$o(this, "cartLineItemImages");
2774
- __publicField$o(this, "orderNumberRegex", /Your order number: #(\d+)/);
2982
+ __publicField$t(this, "headline");
2983
+ __publicField$t(this, "orderNumberText");
2984
+ __publicField$t(this, "grandTotalPrice");
2985
+ __publicField$t(this, "taxPrice");
2986
+ __publicField$t(this, "cartLineItemImages");
2987
+ __publicField$t(this, "orderNumberRegex", /Your order number: #(\d+)/);
2775
2988
  this.headline = page.getByRole("heading", { name: "Thank you for your order" });
2776
2989
  this.orderNumberText = page.getByText(this.orderNumberRegex);
2777
2990
  this.grandTotalPrice = page.locator('dt:has-text("Grand total") + dd');
2991
+ this.taxPrice = page.locator(`dt:text-matches('plus [0-9]\\+\\?% VAT') + dd`);
2778
2992
  this.cartLineItemImages = page.locator(".line-item-img-link");
2779
2993
  }
2780
2994
  url() {
@@ -2799,16 +3013,16 @@ class CheckoutFinish {
2799
3013
  }
2800
3014
  }
2801
3015
 
2802
- var __defProp$n = Object.defineProperty;
2803
- var __defNormalProp$n = (obj, key, value) => key in obj ? __defProp$n(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2804
- var __publicField$n = (obj, key, value) => {
2805
- __defNormalProp$n(obj, typeof key !== "symbol" ? key + "" : key, value);
3016
+ var __defProp$s = Object.defineProperty;
3017
+ var __defNormalProp$s = (obj, key, value) => key in obj ? __defProp$s(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3018
+ var __publicField$s = (obj, key, value) => {
3019
+ __defNormalProp$s(obj, typeof key !== "symbol" ? key + "" : key, value);
2806
3020
  return value;
2807
3021
  };
2808
3022
  class CheckoutRegister {
2809
3023
  constructor(page) {
2810
3024
  this.page = page;
2811
- __publicField$n(this, "cartLineItemImages");
3025
+ __publicField$s(this, "cartLineItemImages");
2812
3026
  this.cartLineItemImages = page.locator(".line-item-img-link");
2813
3027
  }
2814
3028
  url() {
@@ -2816,22 +3030,22 @@ class CheckoutRegister {
2816
3030
  }
2817
3031
  }
2818
3032
 
2819
- var __defProp$m = Object.defineProperty;
2820
- var __defNormalProp$m = (obj, key, value) => key in obj ? __defProp$m(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2821
- var __publicField$m = (obj, key, value) => {
2822
- __defNormalProp$m(obj, typeof key !== "symbol" ? key + "" : key, value);
3033
+ var __defProp$r = Object.defineProperty;
3034
+ var __defNormalProp$r = (obj, key, value) => key in obj ? __defProp$r(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3035
+ var __publicField$r = (obj, key, value) => {
3036
+ __defNormalProp$r(obj, typeof key !== "symbol" ? key + "" : key, value);
2823
3037
  return value;
2824
3038
  };
2825
3039
  class Account {
2826
3040
  constructor(page) {
2827
3041
  this.page = page;
2828
- __publicField$m(this, "headline");
2829
- __publicField$m(this, "personalDataCardTitle");
2830
- __publicField$m(this, "paymentMethodCardTitle");
2831
- __publicField$m(this, "billingAddressCardTitle");
2832
- __publicField$m(this, "shippingAddressCardTitle");
2833
- __publicField$m(this, "newsletterCheckbox");
2834
- __publicField$m(this, "newsletterRegistrationSuccessMessage");
3042
+ __publicField$r(this, "headline");
3043
+ __publicField$r(this, "personalDataCardTitle");
3044
+ __publicField$r(this, "paymentMethodCardTitle");
3045
+ __publicField$r(this, "billingAddressCardTitle");
3046
+ __publicField$r(this, "shippingAddressCardTitle");
3047
+ __publicField$r(this, "newsletterCheckbox");
3048
+ __publicField$r(this, "newsletterRegistrationSuccessMessage");
2835
3049
  this.headline = page.getByRole("heading", { name: "Overview" });
2836
3050
  this.personalDataCardTitle = page.getByRole("heading", { name: "Personal data" });
2837
3051
  this.paymentMethodCardTitle = page.getByRole("heading", { name: "Default payment method" });
@@ -2845,32 +3059,32 @@ class Account {
2845
3059
  }
2846
3060
  }
2847
3061
 
2848
- var __defProp$l = Object.defineProperty;
2849
- var __defNormalProp$l = (obj, key, value) => key in obj ? __defProp$l(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2850
- var __publicField$l = (obj, key, value) => {
2851
- __defNormalProp$l(obj, typeof key !== "symbol" ? key + "" : key, value);
3062
+ var __defProp$q = Object.defineProperty;
3063
+ var __defNormalProp$q = (obj, key, value) => key in obj ? __defProp$q(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3064
+ var __publicField$q = (obj, key, value) => {
3065
+ __defNormalProp$q(obj, typeof key !== "symbol" ? key + "" : key, value);
2852
3066
  return value;
2853
3067
  };
2854
3068
  class AccountLogin {
2855
3069
  constructor(page) {
2856
3070
  this.page = page;
2857
- __publicField$l(this, "emailInput");
2858
- __publicField$l(this, "passwordInput");
2859
- __publicField$l(this, "loginButton");
2860
- __publicField$l(this, "logoutLink");
2861
- __publicField$l(this, "successAlert");
3071
+ __publicField$q(this, "emailInput");
3072
+ __publicField$q(this, "passwordInput");
3073
+ __publicField$q(this, "loginButton");
3074
+ __publicField$q(this, "logoutLink");
3075
+ __publicField$q(this, "successAlert");
2862
3076
  // Inputs for registration
2863
- __publicField$l(this, "personalFormArea");
2864
- __publicField$l(this, "billingAddressFormArea");
2865
- __publicField$l(this, "firstNameInput");
2866
- __publicField$l(this, "lastNameInput");
2867
- __publicField$l(this, "registerEmailInput");
2868
- __publicField$l(this, "registerPasswordInput");
2869
- __publicField$l(this, "streetAddressInput");
2870
- __publicField$l(this, "cityInput");
2871
- __publicField$l(this, "countryInput");
2872
- __publicField$l(this, "postalCodeInput");
2873
- __publicField$l(this, "registerButton");
3077
+ __publicField$q(this, "personalFormArea");
3078
+ __publicField$q(this, "billingAddressFormArea");
3079
+ __publicField$q(this, "firstNameInput");
3080
+ __publicField$q(this, "lastNameInput");
3081
+ __publicField$q(this, "registerEmailInput");
3082
+ __publicField$q(this, "registerPasswordInput");
3083
+ __publicField$q(this, "streetAddressInput");
3084
+ __publicField$q(this, "cityInput");
3085
+ __publicField$q(this, "countryInput");
3086
+ __publicField$q(this, "postalCodeInput");
3087
+ __publicField$q(this, "registerButton");
2874
3088
  this.emailInput = page.getByLabel("Your email address");
2875
3089
  this.passwordInput = page.getByLabel("Your password");
2876
3090
  this.loginButton = page.getByRole("button", { name: "Log in" });
@@ -2894,29 +3108,29 @@ class AccountLogin {
2894
3108
  }
2895
3109
  }
2896
3110
 
2897
- var __defProp$k = Object.defineProperty;
2898
- var __defNormalProp$k = (obj, key, value) => key in obj ? __defProp$k(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2899
- var __publicField$k = (obj, key, value) => {
2900
- __defNormalProp$k(obj, typeof key !== "symbol" ? key + "" : key, value);
3111
+ var __defProp$p = Object.defineProperty;
3112
+ var __defNormalProp$p = (obj, key, value) => key in obj ? __defProp$p(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3113
+ var __publicField$p = (obj, key, value) => {
3114
+ __defNormalProp$p(obj, typeof key !== "symbol" ? key + "" : key, value);
2901
3115
  return value;
2902
3116
  };
2903
3117
  class AccountProfile {
2904
3118
  constructor(page) {
2905
3119
  this.page = page;
2906
- __publicField$k(this, "salutationSelect");
2907
- __publicField$k(this, "firstNameInput");
2908
- __publicField$k(this, "lastNameInput");
2909
- __publicField$k(this, "saveProfileButton");
2910
- __publicField$k(this, "changeEmailButton");
2911
- __publicField$k(this, "emailAddressInput");
2912
- __publicField$k(this, "emailAddressConfirmInput");
2913
- __publicField$k(this, "emailConfirmPasswordInput");
2914
- __publicField$k(this, "saveEmailAddressButton");
2915
- __publicField$k(this, "changePasswordButton");
2916
- __publicField$k(this, "newPasswordInput");
2917
- __publicField$k(this, "newPasswordConfirmInput");
2918
- __publicField$k(this, "currentPasswordInput");
2919
- __publicField$k(this, "saveNewPasswordButton");
3120
+ __publicField$p(this, "salutationSelect");
3121
+ __publicField$p(this, "firstNameInput");
3122
+ __publicField$p(this, "lastNameInput");
3123
+ __publicField$p(this, "saveProfileButton");
3124
+ __publicField$p(this, "changeEmailButton");
3125
+ __publicField$p(this, "emailAddressInput");
3126
+ __publicField$p(this, "emailAddressConfirmInput");
3127
+ __publicField$p(this, "emailConfirmPasswordInput");
3128
+ __publicField$p(this, "saveEmailAddressButton");
3129
+ __publicField$p(this, "changePasswordButton");
3130
+ __publicField$p(this, "newPasswordInput");
3131
+ __publicField$p(this, "newPasswordConfirmInput");
3132
+ __publicField$p(this, "currentPasswordInput");
3133
+ __publicField$p(this, "saveNewPasswordButton");
2920
3134
  this.salutationSelect = page.getByLabel("Salutation");
2921
3135
  this.firstNameInput = page.getByPlaceholder("Enter first name...");
2922
3136
  this.lastNameInput = page.getByPlaceholder("Enter last name...");
@@ -2937,18 +3151,18 @@ class AccountProfile {
2937
3151
  }
2938
3152
  }
2939
3153
 
2940
- var __defProp$j = Object.defineProperty;
2941
- var __defNormalProp$j = (obj, key, value) => key in obj ? __defProp$j(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2942
- var __publicField$j = (obj, key, value) => {
2943
- __defNormalProp$j(obj, typeof key !== "symbol" ? key + "" : key, value);
3154
+ var __defProp$o = Object.defineProperty;
3155
+ var __defNormalProp$o = (obj, key, value) => key in obj ? __defProp$o(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3156
+ var __publicField$o = (obj, key, value) => {
3157
+ __defNormalProp$o(obj, typeof key !== "symbol" ? key + "" : key, value);
2944
3158
  return value;
2945
3159
  };
2946
3160
  class AccountOrder {
2947
3161
  constructor(page) {
2948
3162
  this.page = page;
2949
- __publicField$j(this, "cartLineItemImages");
2950
- __publicField$j(this, "orderExpandButton");
2951
- __publicField$j(this, "digitalProductDownloadButton");
3163
+ __publicField$o(this, "cartLineItemImages");
3164
+ __publicField$o(this, "orderExpandButton");
3165
+ __publicField$o(this, "digitalProductDownloadButton");
2952
3166
  this.orderExpandButton = page.getByRole("button", { name: /Expand|Show details/ }).first();
2953
3167
  this.cartLineItemImages = page.locator(".line-item-img-link");
2954
3168
  this.digitalProductDownloadButton = page.getByRole("link", { name: "Download" }).first();
@@ -2958,20 +3172,20 @@ class AccountOrder {
2958
3172
  }
2959
3173
  }
2960
3174
 
2961
- var __defProp$i = Object.defineProperty;
2962
- var __defNormalProp$i = (obj, key, value) => key in obj ? __defProp$i(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2963
- var __publicField$i = (obj, key, value) => {
2964
- __defNormalProp$i(obj, typeof key !== "symbol" ? key + "" : key, value);
3175
+ var __defProp$n = Object.defineProperty;
3176
+ var __defNormalProp$n = (obj, key, value) => key in obj ? __defProp$n(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3177
+ var __publicField$n = (obj, key, value) => {
3178
+ __defNormalProp$n(obj, typeof key !== "symbol" ? key + "" : key, value);
2965
3179
  return value;
2966
3180
  };
2967
3181
  class AccountAddresses {
2968
3182
  constructor(page) {
2969
3183
  this.page = page;
2970
- __publicField$i(this, "addNewAddressButton");
2971
- __publicField$i(this, "editBillingAddressButton");
2972
- __publicField$i(this, "editShippingAddressButton");
2973
- __publicField$i(this, "useDefaultBillingAddressButton");
2974
- __publicField$i(this, "useDefaultShippingAddressButton");
3184
+ __publicField$n(this, "addNewAddressButton");
3185
+ __publicField$n(this, "editBillingAddressButton");
3186
+ __publicField$n(this, "editShippingAddressButton");
3187
+ __publicField$n(this, "useDefaultBillingAddressButton");
3188
+ __publicField$n(this, "useDefaultShippingAddressButton");
2975
3189
  this.addNewAddressButton = page.getByRole("link", { name: /Add (new )?address/ });
2976
3190
  this.editBillingAddressButton = page.getByRole("link", { name: "Edit address" }).first();
2977
3191
  this.editShippingAddressButton = page.getByRole("link", { name: "Edit address" }).nth(1);
@@ -2983,19 +3197,19 @@ class AccountAddresses {
2983
3197
  }
2984
3198
  }
2985
3199
 
2986
- var __defProp$h = Object.defineProperty;
2987
- var __defNormalProp$h = (obj, key, value) => key in obj ? __defProp$h(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2988
- var __publicField$h = (obj, key, value) => {
2989
- __defNormalProp$h(obj, typeof key !== "symbol" ? key + "" : key, value);
3200
+ var __defProp$m = Object.defineProperty;
3201
+ var __defNormalProp$m = (obj, key, value) => key in obj ? __defProp$m(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3202
+ var __publicField$m = (obj, key, value) => {
3203
+ __defNormalProp$m(obj, typeof key !== "symbol" ? key + "" : key, value);
2990
3204
  return value;
2991
3205
  };
2992
3206
  class AccountPayment {
2993
3207
  constructor(page) {
2994
3208
  this.page = page;
2995
- __publicField$h(this, "cashOnDeliveryOption");
2996
- __publicField$h(this, "paidInAdvanceOption");
2997
- __publicField$h(this, "invoiceOption");
2998
- __publicField$h(this, "changeDefaultPaymentButton");
3209
+ __publicField$m(this, "cashOnDeliveryOption");
3210
+ __publicField$m(this, "paidInAdvanceOption");
3211
+ __publicField$m(this, "invoiceOption");
3212
+ __publicField$m(this, "changeDefaultPaymentButton");
2999
3213
  this.cashOnDeliveryOption = page.getByLabel("Cash on delivery");
3000
3214
  this.paidInAdvanceOption = page.getByLabel("Paid in advance");
3001
3215
  this.invoiceOption = page.getByLabel("Invoice");
@@ -3006,17 +3220,17 @@ class AccountPayment {
3006
3220
  }
3007
3221
  }
3008
3222
 
3009
- var __defProp$g = Object.defineProperty;
3010
- var __defNormalProp$g = (obj, key, value) => key in obj ? __defProp$g(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3011
- var __publicField$g = (obj, key, value) => {
3012
- __defNormalProp$g(obj, typeof key !== "symbol" ? key + "" : key, value);
3223
+ var __defProp$l = Object.defineProperty;
3224
+ var __defNormalProp$l = (obj, key, value) => key in obj ? __defProp$l(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3225
+ var __publicField$l = (obj, key, value) => {
3226
+ __defNormalProp$l(obj, typeof key !== "symbol" ? key + "" : key, value);
3013
3227
  return value;
3014
3228
  };
3015
3229
  class Search {
3016
3230
  constructor(page) {
3017
3231
  this.page = page;
3018
- __publicField$g(this, "headline");
3019
- __publicField$g(this, "productImages");
3232
+ __publicField$l(this, "headline");
3233
+ __publicField$l(this, "productImages");
3020
3234
  this.headline = page.locator("h1.search-headline");
3021
3235
  this.productImages = page.locator(".product-image-link");
3022
3236
  }
@@ -3024,17 +3238,17 @@ class Search {
3024
3238
  return `search?search=${searchTerm}`;
3025
3239
  }
3026
3240
  }
3027
-
3028
- var __defProp$f = Object.defineProperty;
3029
- var __defNormalProp$f = (obj, key, value) => key in obj ? __defProp$f(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3030
- var __publicField$f = (obj, key, value) => {
3031
- __defNormalProp$f(obj, typeof key !== "symbol" ? key + "" : key, value);
3241
+
3242
+ var __defProp$k = Object.defineProperty;
3243
+ var __defNormalProp$k = (obj, key, value) => key in obj ? __defProp$k(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3244
+ var __publicField$k = (obj, key, value) => {
3245
+ __defNormalProp$k(obj, typeof key !== "symbol" ? key + "" : key, value);
3032
3246
  return value;
3033
3247
  };
3034
3248
  class SearchSuggest {
3035
3249
  constructor(page) {
3036
3250
  this.page = page;
3037
- __publicField$f(this, "searchSuggestLineItemImages");
3251
+ __publicField$k(this, "searchSuggestLineItemImages");
3038
3252
  this.searchSuggestLineItemImages = page.locator(".search-suggest-product-image-container");
3039
3253
  }
3040
3254
  url(searchTerm) {
@@ -3111,10 +3325,10 @@ const test$6 = test$e.extend({
3111
3325
  }
3112
3326
  });
3113
3327
 
3114
- var __defProp$e = Object.defineProperty;
3115
- var __defNormalProp$e = (obj, key, value) => key in obj ? __defProp$e(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3116
- var __publicField$e = (obj, key, value) => {
3117
- __defNormalProp$e(obj, typeof key !== "symbol" ? key + "" : key, value);
3328
+ var __defProp$j = Object.defineProperty;
3329
+ var __defNormalProp$j = (obj, key, value) => key in obj ? __defProp$j(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3330
+ var __publicField$j = (obj, key, value) => {
3331
+ __defNormalProp$j(obj, typeof key !== "symbol" ? key + "" : key, value);
3118
3332
  return value;
3119
3333
  };
3120
3334
  class ProductDetail {
@@ -3123,39 +3337,44 @@ class ProductDetail {
3123
3337
  /**
3124
3338
  * Save interactions
3125
3339
  */
3126
- __publicField$e(this, "savePhysicalProductButton");
3127
- __publicField$e(this, "saveButtonLoadingSpinner");
3128
- __publicField$e(this, "saveButtonCheckMark");
3340
+ __publicField$j(this, "savePhysicalProductButton");
3341
+ __publicField$j(this, "saveButtonLoadingSpinner");
3342
+ __publicField$j(this, "saveButtonCheckMark");
3129
3343
  /**
3130
3344
  * Media Upload interactions
3131
3345
  */
3132
- __publicField$e(this, "uploadMediaButton");
3133
- __publicField$e(this, "coverImage");
3134
- __publicField$e(this, "productImage");
3346
+ __publicField$j(this, "uploadMediaButton");
3347
+ __publicField$j(this, "coverImage");
3348
+ __publicField$j(this, "productImage");
3135
3349
  /**
3136
3350
  * Tabs
3137
3351
  */
3138
- __publicField$e(this, "variantsTabLink");
3352
+ __publicField$j(this, "variantsTabLink");
3353
+ __publicField$j(this, "specificationsTabLink");
3139
3354
  /**
3140
3355
  * Variants Generation
3141
3356
  */
3142
- __publicField$e(this, "generateVariantsButton");
3143
- __publicField$e(this, "variantsModal");
3144
- __publicField$e(this, "variantsModalHeadline");
3145
- __publicField$e(this, "variantsNextButton");
3146
- __publicField$e(this, "variantsSaveButton");
3357
+ __publicField$j(this, "generateVariantsButton");
3358
+ __publicField$j(this, "variantsModal");
3359
+ __publicField$j(this, "variantsModalHeadline");
3360
+ __publicField$j(this, "variantsNextButton");
3361
+ __publicField$j(this, "variantsSaveButton");
3147
3362
  /**
3148
3363
  * Property Selection
3149
3364
  */
3150
- __publicField$e(this, "propertyGroupColor");
3151
- __publicField$e(this, "propertyGroupSize");
3152
- __publicField$e(this, "propertyOptionGrid");
3153
- __publicField$e(this, "propertyOptionColorBlue");
3154
- __publicField$e(this, "propertyOptionColorRed");
3155
- __publicField$e(this, "propertyOptionColorGreen");
3156
- __publicField$e(this, "propertyOptionSizeSmall");
3157
- __publicField$e(this, "propertyOptionSizeMedium");
3158
- __publicField$e(this, "propertyOptionSizeLarge");
3365
+ __publicField$j(this, "propertyGroupColor");
3366
+ __publicField$j(this, "propertyGroupSize");
3367
+ __publicField$j(this, "propertyOptionGrid");
3368
+ __publicField$j(this, "propertyOptionColorBlue");
3369
+ __publicField$j(this, "propertyOptionColorRed");
3370
+ __publicField$j(this, "propertyOptionColorGreen");
3371
+ __publicField$j(this, "propertyOptionSizeSmall");
3372
+ __publicField$j(this, "propertyOptionSizeMedium");
3373
+ __publicField$j(this, "propertyOptionSizeLarge");
3374
+ /**
3375
+ * Cards
3376
+ */
3377
+ __publicField$j(this, "customFieldCard");
3159
3378
  this.savePhysicalProductButton = page.getByRole("button", { name: "Save" });
3160
3379
  this.saveButtonCheckMark = page.locator(".icon--regular-checkmark-xs");
3161
3380
  this.saveButtonLoadingSpinner = page.locator("sw-loader");
@@ -3177,24 +3396,35 @@ class ProductDetail {
3177
3396
  this.propertyOptionSizeSmall = this.propertyOptionGrid.getByLabel("Small");
3178
3397
  this.propertyOptionSizeMedium = this.propertyOptionGrid.getByLabel("Medium");
3179
3398
  this.propertyOptionSizeLarge = this.propertyOptionGrid.getByLabel("Large");
3399
+ this.specificationsTabLink = page.getByRole("link", { name: "Specifications" });
3400
+ this.customFieldCard = page.locator(".sw-card").getByText("Custom fields");
3401
+ }
3402
+ async getCustomFieldSetCardContentByName(customFieldSetName) {
3403
+ const customFieldCard = this.page.locator(".sw-card").filter({ hasText: "Custom fields" });
3404
+ const customFieldSetTab = customFieldCard.getByText(customFieldSetName);
3405
+ const customFieldSetTabCustomContent = customFieldCard.locator(`.sw-custom-field-set-renderer-tab-content__${customFieldSetName}`);
3406
+ return {
3407
+ customFieldSetTab,
3408
+ customFieldSetTabCustomContent
3409
+ };
3180
3410
  }
3181
3411
  url(productId) {
3182
3412
  return `#/sw/product/detail/${productId}/base`;
3183
3413
  }
3184
3414
  }
3185
3415
 
3186
- var __defProp$d = Object.defineProperty;
3187
- var __defNormalProp$d = (obj, key, value) => key in obj ? __defProp$d(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3188
- var __publicField$d = (obj, key, value) => {
3189
- __defNormalProp$d(obj, typeof key !== "symbol" ? key + "" : key, value);
3416
+ var __defProp$i = Object.defineProperty;
3417
+ var __defNormalProp$i = (obj, key, value) => key in obj ? __defProp$i(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3418
+ var __publicField$i = (obj, key, value) => {
3419
+ __defNormalProp$i(obj, typeof key !== "symbol" ? key + "" : key, value);
3190
3420
  return value;
3191
3421
  };
3192
3422
  class OrderDetail {
3193
3423
  constructor(page) {
3194
3424
  this.page = page;
3195
- __publicField$d(this, "saveButton");
3196
- __publicField$d(this, "dataGridContextButton");
3197
- __publicField$d(this, "orderTag");
3425
+ __publicField$i(this, "saveButton");
3426
+ __publicField$i(this, "dataGridContextButton");
3427
+ __publicField$i(this, "orderTag");
3198
3428
  this.saveButton = page.locator(".sw-order-detail__smart-bar-save-button");
3199
3429
  this.dataGridContextButton = page.locator(".sw-data-grid__actions-menu").and(page.getByRole("button"));
3200
3430
  this.orderTag = page.locator(".sw-select-selection-list__item");
@@ -3204,74 +3434,89 @@ class OrderDetail {
3204
3434
  }
3205
3435
  }
3206
3436
 
3207
- var __defProp$c = Object.defineProperty;
3208
- var __defNormalProp$c = (obj, key, value) => key in obj ? __defProp$c(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3209
- var __publicField$c = (obj, key, value) => {
3210
- __defNormalProp$c(obj, typeof key !== "symbol" ? key + "" : key, value);
3437
+ var __defProp$h = Object.defineProperty;
3438
+ var __defNormalProp$h = (obj, key, value) => key in obj ? __defProp$h(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3439
+ var __publicField$h = (obj, key, value) => {
3440
+ __defNormalProp$h(obj, typeof key !== "symbol" ? key + "" : key, value);
3211
3441
  return value;
3212
3442
  };
3213
3443
  class CustomerDetail {
3214
3444
  constructor(page) {
3215
3445
  this.page = page;
3216
- __publicField$c(this, "editButton");
3217
- __publicField$c(this, "generalTab");
3218
- __publicField$c(this, "accountCard");
3446
+ __publicField$h(this, "editButton");
3447
+ __publicField$h(this, "generalTab");
3448
+ __publicField$h(this, "accountCard");
3449
+ __publicField$h(this, "customFieldCard");
3450
+ __publicField$h(this, "customFieldSetTabs");
3451
+ __publicField$h(this, "customFieldSetTabCustomContent");
3219
3452
  this.editButton = page.getByRole("button", { name: "Edit" });
3220
3453
  this.generalTab = page.getByRole("link", { name: "General" });
3221
3454
  this.accountCard = page.locator(".sw-customer-card");
3455
+ this.customFieldCard = page.locator(".sw-card").getByText("Custom fields");
3456
+ this.customFieldSetTabs = this.customFieldCard.locator(".sw-tabs-item");
3457
+ this.customFieldSetTabCustomContent = this.customFieldCard.locator(".sw-tabs__custom-content");
3458
+ }
3459
+ async getCustomFieldSetCardContentByName(customFieldSetName) {
3460
+ const customFieldCard = this.page.locator(".sw-card").filter({ hasText: "Custom fields" });
3461
+ const customFieldSetTab = customFieldCard.getByText(customFieldSetName);
3462
+ const customFieldSetTabCustomContent = customFieldCard.locator(`.sw-custom-field-set-renderer-tab-content__${customFieldSetName}`);
3463
+ return {
3464
+ customFieldSetTab,
3465
+ customFieldSetTabCustomContent
3466
+ };
3222
3467
  }
3223
3468
  url(customerId) {
3224
3469
  return `#/sw/customer/detail/${customerId}/base`;
3225
3470
  }
3226
3471
  }
3227
3472
 
3228
- var __defProp$b = Object.defineProperty;
3229
- var __defNormalProp$b = (obj, key, value) => key in obj ? __defProp$b(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3230
- var __publicField$b = (obj, key, value) => {
3231
- __defNormalProp$b(obj, typeof key !== "symbol" ? key + "" : key, value);
3473
+ var __defProp$g = Object.defineProperty;
3474
+ var __defNormalProp$g = (obj, key, value) => key in obj ? __defProp$g(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3475
+ var __publicField$g = (obj, key, value) => {
3476
+ __defNormalProp$g(obj, typeof key !== "symbol" ? key + "" : key, value);
3232
3477
  return value;
3233
3478
  };
3234
3479
  class FirstRunWizard {
3235
3480
  constructor(page) {
3236
3481
  this.page = page;
3237
- __publicField$b(this, "nextButton");
3238
- __publicField$b(this, "configureLaterButton");
3239
- __publicField$b(this, "skipButton");
3240
- __publicField$b(this, "finishButton");
3241
- __publicField$b(this, "backButton");
3242
- __publicField$b(this, "smtpServerButton");
3243
- __publicField$b(this, "dataImportHeader");
3244
- __publicField$b(this, "installLanguagePackButton");
3245
- __publicField$b(this, "installDemoDataButton");
3246
- __publicField$b(this, "installMigrationAssistantButton");
3247
- __publicField$b(this, "defaultValuesHeader");
3248
- __publicField$b(this, "mailerConfigurationHeader");
3249
- __publicField$b(this, "payPalSetupHeader");
3250
- __publicField$b(this, "extensionsHeader");
3251
- __publicField$b(this, "shopwareAccountHeader");
3252
- __publicField$b(this, "shopwareStoreHeader");
3253
- __publicField$b(this, "doneHeader");
3254
- __publicField$b(this, "frwSuccessText");
3255
- __publicField$b(this, "welcomeText");
3256
- __publicField$b(this, "pluginCardInfo");
3257
- __publicField$b(this, "dataImportCard");
3258
- __publicField$b(this, "salesChannelSelectionList");
3259
- __publicField$b(this, "salesChannelSelectionMultiSelect");
3260
- __publicField$b(this, "smtpServerTitle");
3261
- __publicField$b(this, "smtpServerFields");
3262
- __publicField$b(this, "payPalPaymethods");
3263
- __publicField$b(this, "payPalInfoCard");
3264
- __publicField$b(this, "emailAddressInputField");
3265
- __publicField$b(this, "passwordInputField");
3266
- __publicField$b(this, "forgotPasswordLink");
3267
- __publicField$b(this, "extensionStoreHeading");
3268
- __publicField$b(this, "documentationLink");
3269
- __publicField$b(this, "forumLink");
3270
- __publicField$b(this, "roadmapLink");
3271
- __publicField$b(this, "germanRegionSelector");
3272
- __publicField$b(this, "toolsSelector");
3273
- __publicField$b(this, "recommendationHeader");
3274
- __publicField$b(this, "toolsRecommendedPlugin");
3482
+ __publicField$g(this, "nextButton");
3483
+ __publicField$g(this, "configureLaterButton");
3484
+ __publicField$g(this, "skipButton");
3485
+ __publicField$g(this, "finishButton");
3486
+ __publicField$g(this, "backButton");
3487
+ __publicField$g(this, "smtpServerButton");
3488
+ __publicField$g(this, "dataImportHeader");
3489
+ __publicField$g(this, "installLanguagePackButton");
3490
+ __publicField$g(this, "installDemoDataButton");
3491
+ __publicField$g(this, "installMigrationAssistantButton");
3492
+ __publicField$g(this, "defaultValuesHeader");
3493
+ __publicField$g(this, "mailerConfigurationHeader");
3494
+ __publicField$g(this, "payPalSetupHeader");
3495
+ __publicField$g(this, "extensionsHeader");
3496
+ __publicField$g(this, "shopwareAccountHeader");
3497
+ __publicField$g(this, "shopwareStoreHeader");
3498
+ __publicField$g(this, "doneHeader");
3499
+ __publicField$g(this, "frwSuccessText");
3500
+ __publicField$g(this, "welcomeText");
3501
+ __publicField$g(this, "pluginCardInfo");
3502
+ __publicField$g(this, "dataImportCard");
3503
+ __publicField$g(this, "salesChannelSelectionList");
3504
+ __publicField$g(this, "salesChannelSelectionMultiSelect");
3505
+ __publicField$g(this, "smtpServerTitle");
3506
+ __publicField$g(this, "smtpServerFields");
3507
+ __publicField$g(this, "payPalPaymethods");
3508
+ __publicField$g(this, "payPalInfoCard");
3509
+ __publicField$g(this, "emailAddressInputField");
3510
+ __publicField$g(this, "passwordInputField");
3511
+ __publicField$g(this, "forgotPasswordLink");
3512
+ __publicField$g(this, "extensionStoreHeading");
3513
+ __publicField$g(this, "documentationLink");
3514
+ __publicField$g(this, "forumLink");
3515
+ __publicField$g(this, "roadmapLink");
3516
+ __publicField$g(this, "germanRegionSelector");
3517
+ __publicField$g(this, "toolsSelector");
3518
+ __publicField$g(this, "recommendationHeader");
3519
+ __publicField$g(this, "toolsRecommendedPlugin");
3275
3520
  this.nextButton = page.getByText("Next", { exact: true });
3276
3521
  this.configureLaterButton = page.getByText("Configure later", { exact: true });
3277
3522
  this.skipButton = page.getByText("Skip", { exact: true });
@@ -3316,17 +3561,17 @@ class FirstRunWizard {
3316
3561
  }
3317
3562
  }
3318
3563
 
3319
- var __defProp$a = Object.defineProperty;
3320
- var __defNormalProp$a = (obj, key, value) => key in obj ? __defProp$a(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3321
- var __publicField$a = (obj, key, value) => {
3322
- __defNormalProp$a(obj, typeof key !== "symbol" ? key + "" : key, value);
3564
+ var __defProp$f = Object.defineProperty;
3565
+ var __defNormalProp$f = (obj, key, value) => key in obj ? __defProp$f(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3566
+ var __publicField$f = (obj, key, value) => {
3567
+ __defNormalProp$f(obj, typeof key !== "symbol" ? key + "" : key, value);
3323
3568
  return value;
3324
3569
  };
3325
3570
  class FlowBuilderCreate {
3326
3571
  constructor(page) {
3327
3572
  this.page = page;
3328
- __publicField$a(this, "saveButton");
3329
- __publicField$a(this, "header");
3573
+ __publicField$f(this, "saveButton");
3574
+ __publicField$f(this, "header");
3330
3575
  this.saveButton = page.locator(".sw-flow-detail__save");
3331
3576
  this.header = page.locator("h2");
3332
3577
  }
@@ -3335,28 +3580,28 @@ class FlowBuilderCreate {
3335
3580
  }
3336
3581
  }
3337
3582
 
3338
- var __defProp$9 = Object.defineProperty;
3339
- var __defNormalProp$9 = (obj, key, value) => key in obj ? __defProp$9(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3340
- var __publicField$9 = (obj, key, value) => {
3341
- __defNormalProp$9(obj, typeof key !== "symbol" ? key + "" : key, value);
3583
+ var __defProp$e = Object.defineProperty;
3584
+ var __defNormalProp$e = (obj, key, value) => key in obj ? __defProp$e(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3585
+ var __publicField$e = (obj, key, value) => {
3586
+ __defNormalProp$e(obj, typeof key !== "symbol" ? key + "" : key, value);
3342
3587
  return value;
3343
3588
  };
3344
3589
  class FlowBuilderListing {
3345
3590
  constructor(page) {
3346
3591
  this.page = page;
3347
- __publicField$9(this, "createFlowButton");
3348
- __publicField$9(this, "firstFlowName");
3349
- __publicField$9(this, "firstFlowContextButton");
3350
- __publicField$9(this, "flowContextMenu");
3351
- __publicField$9(this, "contextMenuDownload");
3352
- __publicField$9(this, "contextMenuDuplicate");
3353
- __publicField$9(this, "contextMenuEdit");
3354
- __publicField$9(this, "contextMenuDelete");
3355
- __publicField$9(this, "flowDownloadModal");
3356
- __publicField$9(this, "downloadFlowButton");
3357
- __publicField$9(this, "flowDeleteButton");
3358
- __publicField$9(this, "successAlert");
3359
- __publicField$9(this, "successAlertMessage");
3592
+ __publicField$e(this, "createFlowButton");
3593
+ __publicField$e(this, "firstFlowName");
3594
+ __publicField$e(this, "firstFlowContextButton");
3595
+ __publicField$e(this, "flowContextMenu");
3596
+ __publicField$e(this, "contextMenuDownload");
3597
+ __publicField$e(this, "contextMenuDuplicate");
3598
+ __publicField$e(this, "contextMenuEdit");
3599
+ __publicField$e(this, "contextMenuDelete");
3600
+ __publicField$e(this, "flowDownloadModal");
3601
+ __publicField$e(this, "downloadFlowButton");
3602
+ __publicField$e(this, "flowDeleteButton");
3603
+ __publicField$e(this, "successAlert");
3604
+ __publicField$e(this, "successAlertMessage");
3360
3605
  this.createFlowButton = page.locator(".sw-flow-list__create");
3361
3606
  this.firstFlowName = page.locator(".sw-data-grid__cell--name a").first();
3362
3607
  this.firstFlowContextButton = page.locator(".sw-data-grid__actions-menu").first();
@@ -3393,18 +3638,18 @@ class FlowBuilderListing {
3393
3638
  }
3394
3639
  }
3395
3640
 
3396
- var __defProp$8 = Object.defineProperty;
3397
- var __defNormalProp$8 = (obj, key, value) => key in obj ? __defProp$8(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3398
- var __publicField$8 = (obj, key, value) => {
3399
- __defNormalProp$8(obj, typeof key !== "symbol" ? key + "" : key, value);
3641
+ var __defProp$d = Object.defineProperty;
3642
+ var __defNormalProp$d = (obj, key, value) => key in obj ? __defProp$d(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3643
+ var __publicField$d = (obj, key, value) => {
3644
+ __defNormalProp$d(obj, typeof key !== "symbol" ? key + "" : key, value);
3400
3645
  return value;
3401
3646
  };
3402
3647
  class FlowBuilderDetail {
3403
3648
  constructor(page) {
3404
3649
  this.page = page;
3405
- __publicField$8(this, "saveButton");
3406
- __publicField$8(this, "generalTab");
3407
- __publicField$8(this, "flowTab");
3650
+ __publicField$d(this, "saveButton");
3651
+ __publicField$d(this, "generalTab");
3652
+ __publicField$d(this, "flowTab");
3408
3653
  this.saveButton = page.locator(".sw-flow-detail__save");
3409
3654
  this.generalTab = page.locator(".sw-flow-detail__tab-general");
3410
3655
  this.flowTab = page.locator(".sw-flow-detail__tab-flow");
@@ -3414,20 +3659,20 @@ class FlowBuilderDetail {
3414
3659
  }
3415
3660
  }
3416
3661
 
3417
- var __defProp$7 = Object.defineProperty;
3418
- var __defNormalProp$7 = (obj, key, value) => key in obj ? __defProp$7(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3419
- var __publicField$7 = (obj, key, value) => {
3420
- __defNormalProp$7(obj, typeof key !== "symbol" ? key + "" : key, value);
3662
+ var __defProp$c = Object.defineProperty;
3663
+ var __defNormalProp$c = (obj, key, value) => key in obj ? __defProp$c(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3664
+ var __publicField$c = (obj, key, value) => {
3665
+ __defNormalProp$c(obj, typeof key !== "symbol" ? key + "" : key, value);
3421
3666
  return value;
3422
3667
  };
3423
3668
  class DataSharing {
3424
3669
  constructor(page) {
3425
3670
  this.page = page;
3426
- __publicField$7(this, "dataConsentHeadline");
3427
- __publicField$7(this, "dataSharingSuccessMessageLabel");
3428
- __publicField$7(this, "dataSharingAgreeButton");
3429
- __publicField$7(this, "dataSharingDisableButton");
3430
- __publicField$7(this, "dataSharingTermsAgreementLabel");
3671
+ __publicField$c(this, "dataConsentHeadline");
3672
+ __publicField$c(this, "dataSharingSuccessMessageLabel");
3673
+ __publicField$c(this, "dataSharingAgreeButton");
3674
+ __publicField$c(this, "dataSharingDisableButton");
3675
+ __publicField$c(this, "dataSharingTermsAgreementLabel");
3431
3676
  this.dataConsentHeadline = page.locator("h3.sw-usage-data-consent-banner__content-headline");
3432
3677
  this.dataSharingAgreeButton = page.getByRole("button", { name: "Agree" });
3433
3678
  this.dataSharingDisableButton = page.getByRole("button", { name: "Disable data sharing" });
@@ -3439,23 +3684,23 @@ class DataSharing {
3439
3684
  }
3440
3685
  }
3441
3686
 
3442
- var __defProp$6 = Object.defineProperty;
3443
- var __defNormalProp$6 = (obj, key, value) => key in obj ? __defProp$6(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3444
- var __publicField$6 = (obj, key, value) => {
3445
- __defNormalProp$6(obj, typeof key !== "symbol" ? key + "" : key, value);
3687
+ var __defProp$b = Object.defineProperty;
3688
+ var __defNormalProp$b = (obj, key, value) => key in obj ? __defProp$b(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3689
+ var __publicField$b = (obj, key, value) => {
3690
+ __defNormalProp$b(obj, typeof key !== "symbol" ? key + "" : key, value);
3446
3691
  return value;
3447
3692
  };
3448
3693
  class Dashboard {
3449
3694
  constructor(page) {
3450
3695
  this.page = page;
3451
- __publicField$6(this, "welcomeHeadline");
3452
- __publicField$6(this, "dataSharingConsentBanner");
3453
- __publicField$6(this, "dataSharingAgreeButton");
3454
- __publicField$6(this, "dataSharingNotAtTheMomentButton");
3455
- __publicField$6(this, "dataSharingTermsAgreementLabel");
3456
- __publicField$6(this, "dataSharingSettingsLink");
3457
- __publicField$6(this, "dataSharingAcceptMessageText");
3458
- __publicField$6(this, "dataSharingNotAtTheMomentMessageText");
3696
+ __publicField$b(this, "welcomeHeadline");
3697
+ __publicField$b(this, "dataSharingConsentBanner");
3698
+ __publicField$b(this, "dataSharingAgreeButton");
3699
+ __publicField$b(this, "dataSharingNotAtTheMomentButton");
3700
+ __publicField$b(this, "dataSharingTermsAgreementLabel");
3701
+ __publicField$b(this, "dataSharingSettingsLink");
3702
+ __publicField$b(this, "dataSharingAcceptMessageText");
3703
+ __publicField$b(this, "dataSharingNotAtTheMomentMessageText");
3459
3704
  this.welcomeHeadline = page.locator("h1.sw-dashboard-index__welcome-title");
3460
3705
  this.dataSharingConsentBanner = page.locator(".sw-usage-data-consent-banner");
3461
3706
  this.dataSharingAgreeButton = page.getByRole("button", { name: "Agree" });
@@ -3470,25 +3715,25 @@ class Dashboard {
3470
3715
  }
3471
3716
  }
3472
3717
 
3473
- var __defProp$5 = Object.defineProperty;
3474
- var __defNormalProp$5 = (obj, key, value) => key in obj ? __defProp$5(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3475
- var __publicField$5 = (obj, key, value) => {
3476
- __defNormalProp$5(obj, typeof key !== "symbol" ? key + "" : key, value);
3718
+ var __defProp$a = Object.defineProperty;
3719
+ var __defNormalProp$a = (obj, key, value) => key in obj ? __defProp$a(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3720
+ var __publicField$a = (obj, key, value) => {
3721
+ __defNormalProp$a(obj, typeof key !== "symbol" ? key + "" : key, value);
3477
3722
  return value;
3478
3723
  };
3479
3724
  class ShippingListing {
3480
3725
  constructor(page) {
3481
3726
  this.page = page;
3482
- __publicField$5(this, "header");
3483
- __publicField$5(this, "addShippingMethod");
3484
- __publicField$5(this, "contextMenu");
3485
- __publicField$5(this, "editButton");
3486
- __publicField$5(this, "deleteButton");
3727
+ __publicField$a(this, "header");
3728
+ __publicField$a(this, "addShippingMethod");
3729
+ __publicField$a(this, "contextMenu");
3730
+ __publicField$a(this, "editButton");
3731
+ __publicField$a(this, "deleteButton");
3487
3732
  //warning modal
3488
- __publicField$5(this, "modal");
3489
- __publicField$5(this, "modalHeader");
3490
- __publicField$5(this, "modalCancelButton");
3491
- __publicField$5(this, "modalDeleteButton");
3733
+ __publicField$a(this, "modal");
3734
+ __publicField$a(this, "modalHeader");
3735
+ __publicField$a(this, "modalCancelButton");
3736
+ __publicField$a(this, "modalDeleteButton");
3492
3737
  this.header = page.locator(".smart-bar__header");
3493
3738
  this.addShippingMethod = page.getByText("Add shipping method", { exact: true });
3494
3739
  this.contextMenu = page.locator(".sw-data-grid-settings__trigger");
@@ -3504,10 +3749,10 @@ class ShippingListing {
3504
3749
  }
3505
3750
  }
3506
3751
 
3507
- var __defProp$4 = Object.defineProperty;
3508
- var __defNormalProp$4 = (obj, key, value) => key in obj ? __defProp$4(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3509
- var __publicField$4 = (obj, key, value) => {
3510
- __defNormalProp$4(obj, typeof key !== "symbol" ? key + "" : key, value);
3752
+ var __defProp$9 = Object.defineProperty;
3753
+ var __defNormalProp$9 = (obj, key, value) => key in obj ? __defProp$9(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3754
+ var __publicField$9 = (obj, key, value) => {
3755
+ __defNormalProp$9(obj, typeof key !== "symbol" ? key + "" : key, value);
3511
3756
  return value;
3512
3757
  };
3513
3758
  class LandingPageCreate {
@@ -3516,24 +3761,24 @@ class LandingPageCreate {
3516
3761
  /**
3517
3762
  * General
3518
3763
  */
3519
- __publicField$4(this, "nameInput");
3520
- __publicField$4(this, "landingPageStatus");
3521
- __publicField$4(this, "salesChannelSelectionList");
3522
- __publicField$4(this, "filtersResultPopoverItemList");
3523
- __publicField$4(this, "saveLandingPageButton");
3524
- __publicField$4(this, "loadingSpinner");
3525
- __publicField$4(this, "seoUrlInput");
3764
+ __publicField$9(this, "nameInput");
3765
+ __publicField$9(this, "landingPageStatus");
3766
+ __publicField$9(this, "salesChannelSelectionList");
3767
+ __publicField$9(this, "filtersResultPopoverItemList");
3768
+ __publicField$9(this, "saveLandingPageButton");
3769
+ __publicField$9(this, "loadingSpinner");
3770
+ __publicField$9(this, "seoUrlInput");
3526
3771
  /**
3527
3772
  * Layout
3528
3773
  */
3529
- __publicField$4(this, "layoutTab");
3530
- __publicField$4(this, "assignLayoutButton");
3531
- __publicField$4(this, "searchLayoutInput");
3532
- __publicField$4(this, "layoutItems");
3533
- __publicField$4(this, "layoutSaveButton");
3534
- __publicField$4(this, "layoutEmptyState");
3535
- __publicField$4(this, "createNewLayoutButton");
3536
- __publicField$4(this, "layoutCheckboxes");
3774
+ __publicField$9(this, "layoutTab");
3775
+ __publicField$9(this, "assignLayoutButton");
3776
+ __publicField$9(this, "searchLayoutInput");
3777
+ __publicField$9(this, "layoutItems");
3778
+ __publicField$9(this, "layoutSaveButton");
3779
+ __publicField$9(this, "layoutEmptyState");
3780
+ __publicField$9(this, "createNewLayoutButton");
3781
+ __publicField$9(this, "layoutCheckboxes");
3537
3782
  this.loadingSpinner = page.locator(".sw-loader");
3538
3783
  this.saveLandingPageButton = page.getByRole("button", { name: "Save" });
3539
3784
  this.nameInput = page.getByLabel("Name");
@@ -3558,10 +3803,10 @@ class LandingPageCreate {
3558
3803
  }
3559
3804
  }
3560
3805
 
3561
- var __defProp$3 = Object.defineProperty;
3562
- var __defNormalProp$3 = (obj, key, value) => key in obj ? __defProp$3(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3563
- var __publicField$3 = (obj, key, value) => {
3564
- __defNormalProp$3(obj, typeof key !== "symbol" ? key + "" : key, value);
3806
+ var __defProp$8 = Object.defineProperty;
3807
+ var __defNormalProp$8 = (obj, key, value) => key in obj ? __defProp$8(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3808
+ var __publicField$8 = (obj, key, value) => {
3809
+ __defNormalProp$8(obj, typeof key !== "symbol" ? key + "" : key, value);
3565
3810
  return value;
3566
3811
  };
3567
3812
  class LandingPageDetail {
@@ -3570,24 +3815,24 @@ class LandingPageDetail {
3570
3815
  /**
3571
3816
  * General
3572
3817
  */
3573
- __publicField$3(this, "nameInput");
3574
- __publicField$3(this, "landingPageStatus");
3575
- __publicField$3(this, "salesChannelSelectionList");
3576
- __publicField$3(this, "filtersResultPopoverItemList");
3577
- __publicField$3(this, "saveLandingPageButton");
3578
- __publicField$3(this, "loadingSpinner");
3579
- __publicField$3(this, "seoUrlInput");
3818
+ __publicField$8(this, "nameInput");
3819
+ __publicField$8(this, "landingPageStatus");
3820
+ __publicField$8(this, "salesChannelSelectionList");
3821
+ __publicField$8(this, "filtersResultPopoverItemList");
3822
+ __publicField$8(this, "saveLandingPageButton");
3823
+ __publicField$8(this, "loadingSpinner");
3824
+ __publicField$8(this, "seoUrlInput");
3580
3825
  /**
3581
3826
  * Layout
3582
3827
  */
3583
- __publicField$3(this, "layoutTab");
3584
- __publicField$3(this, "layoutAssignmentCardTitle");
3585
- __publicField$3(this, "layoutAssignmentCardHeadline");
3586
- __publicField$3(this, "changeLayoutButton");
3587
- __publicField$3(this, "editInDesignerButton");
3588
- __publicField$3(this, "layoutResetButton");
3589
- __publicField$3(this, "layoutAssignmentStatus");
3590
- __publicField$3(this, "layoutAssignmentContentSection");
3828
+ __publicField$8(this, "layoutTab");
3829
+ __publicField$8(this, "layoutAssignmentCardTitle");
3830
+ __publicField$8(this, "layoutAssignmentCardHeadline");
3831
+ __publicField$8(this, "changeLayoutButton");
3832
+ __publicField$8(this, "editInDesignerButton");
3833
+ __publicField$8(this, "layoutResetButton");
3834
+ __publicField$8(this, "layoutAssignmentStatus");
3835
+ __publicField$8(this, "layoutAssignmentContentSection");
3591
3836
  this.loadingSpinner = page.locator(".sw-loader");
3592
3837
  this.saveLandingPageButton = page.getByRole("button", { name: "Save" });
3593
3838
  this.nameInput = page.getByLabel("Name");
@@ -3611,10 +3856,10 @@ class LandingPageDetail {
3611
3856
  }
3612
3857
  }
3613
3858
 
3614
- var __defProp$2 = Object.defineProperty;
3615
- var __defNormalProp$2 = (obj, key, value) => key in obj ? __defProp$2(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3616
- var __publicField$2 = (obj, key, value) => {
3617
- __defNormalProp$2(obj, typeof key !== "symbol" ? key + "" : key, value);
3859
+ var __defProp$7 = Object.defineProperty;
3860
+ var __defNormalProp$7 = (obj, key, value) => key in obj ? __defProp$7(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3861
+ var __publicField$7 = (obj, key, value) => {
3862
+ __defNormalProp$7(obj, typeof key !== "symbol" ? key + "" : key, value);
3618
3863
  return value;
3619
3864
  };
3620
3865
  class Categories {
@@ -3623,38 +3868,40 @@ class Categories {
3623
3868
  /**
3624
3869
  * Landing pages
3625
3870
  */
3626
- __publicField$2(this, "landingPageArea");
3627
- __publicField$2(this, "landingPageHeadline");
3628
- __publicField$2(this, "addLandingPageButton");
3629
- __publicField$2(this, "landingPageItems");
3871
+ __publicField$7(this, "landingPageArea");
3872
+ __publicField$7(this, "landingPageHeadline");
3873
+ __publicField$7(this, "addLandingPageButton");
3874
+ __publicField$7(this, "landingPageItems");
3630
3875
  /**
3631
3876
  * Category tree
3632
3877
  */
3633
- __publicField$2(this, "categoryTree");
3634
- __publicField$2(this, "homeCategory");
3635
- __publicField$2(this, "homeCategoryContextButton");
3636
- __publicField$2(this, "categoryMenuItemList");
3637
- __publicField$2(this, "createCategoryInput");
3638
- __publicField$2(this, "confirmCategoryCreationButton");
3639
- __publicField$2(this, "categoryItems");
3878
+ __publicField$7(this, "categoryTree");
3879
+ __publicField$7(this, "homeCategory");
3880
+ __publicField$7(this, "homeCategoryContextButton");
3881
+ __publicField$7(this, "categoryMenuItemList");
3882
+ __publicField$7(this, "createCategoryInput");
3883
+ __publicField$7(this, "confirmCategoryCreationButton");
3884
+ __publicField$7(this, "categoryItems");
3640
3885
  /**
3641
3886
  * General
3642
3887
  */
3643
- __publicField$2(this, "nameInput");
3644
- __publicField$2(this, "activeCheckbox");
3645
- __publicField$2(this, "categoryTypeSelectionList");
3646
- __publicField$2(this, "filtersResultPopoverItemList");
3647
- __publicField$2(this, "saveButton");
3888
+ __publicField$7(this, "nameInput");
3889
+ __publicField$7(this, "activeCheckbox");
3890
+ __publicField$7(this, "categoryTypeSelectionList");
3891
+ __publicField$7(this, "filtersResultPopoverItemList");
3892
+ __publicField$7(this, "saveButton");
3893
+ __publicField$7(this, "loadingSpinner");
3648
3894
  /**
3649
3895
  * Customisable link
3650
3896
  */
3651
- __publicField$2(this, "entitySelectionList");
3652
- __publicField$2(this, "linkTypeSelectionList");
3653
- __publicField$2(this, "categorySelectionList");
3654
- __publicField$2(this, "productSelectionList");
3655
- __publicField$2(this, "landingPageSelectionList");
3656
- __publicField$2(this, "filterResultPopoverTreeCheckboxItemList");
3657
- __publicField$2(this, "openInNewTabCheckbox");
3897
+ __publicField$7(this, "entitySelectionList");
3898
+ __publicField$7(this, "linkTypeSelectionList");
3899
+ __publicField$7(this, "categorySelectionList");
3900
+ __publicField$7(this, "productSelectionList");
3901
+ __publicField$7(this, "landingPageSelectionList");
3902
+ __publicField$7(this, "filterResultPopoverTreeCheckboxItemList");
3903
+ __publicField$7(this, "openInNewTabCheckbox");
3904
+ __publicField$7(this, "popoverCategoryTree");
3658
3905
  this.landingPageArea = page.locator(".sw-category-detail__landing-page-collapse");
3659
3906
  this.landingPageHeadline = this.landingPageArea.getByRole("heading", { name: "Landing pages" });
3660
3907
  this.addLandingPageButton = this.landingPageArea.getByText("Add landing page");
@@ -3672,34 +3919,249 @@ class Categories {
3672
3919
  this.categoryTypeSelectionList = page.locator(".sw-select").filter({ hasText: "Category type" }).locator(".sw-select__selection");
3673
3920
  this.linkTypeSelectionList = page.locator(".sw-select").filter({ hasText: "Link type" }).locator(".sw-select__selection");
3674
3921
  this.entitySelectionList = page.locator(".sw-select").filter({ hasText: "Entity" }).locator(".sw-select__selection");
3675
- this.categorySelectionList = page.locator(".sw-select").filter({ hasText: "Category" }).locator(".sw-select__selection");
3676
- this.productSelectionList = page.locator(".sw-select").filter({ hasText: "Product" }).locator(".sw-select__selection");
3677
- this.landingPageSelectionList = page.locator(".sw-select").filter({ hasText: "Landing page" }).locator(".sw-select__selection");
3922
+ this.categorySelectionList = page.locator(".sw-category-link-settings__selection-category");
3923
+ this.productSelectionList = page.locator(".sw-category-link-settings__selection-product");
3924
+ this.landingPageSelectionList = page.locator(".sw-category-link-settings__selection-landing-page");
3678
3925
  this.filtersResultPopoverItemList = page.locator(".sw-select-result-list__content").getByRole("listitem");
3679
- this.filterResultPopoverTreeCheckboxItemList = page.locator(".sw-tree__content").getByRole("checkbox");
3926
+ this.popoverCategoryTree = page.locator(".sw-category-tree-field__results_popover");
3927
+ this.filterResultPopoverTreeCheckboxItemList = this.popoverCategoryTree.locator(".sw-tree__content").locator(".sw-tree-item");
3680
3928
  this.openInNewTabCheckbox = page.getByRole("checkbox", { name: "Open in new tab" });
3929
+ this.loadingSpinner = page.locator(".sw-loader");
3930
+ }
3931
+ async getLandingPageByName(landingPageName) {
3932
+ return this.landingPageItems.locator(`text="${landingPageName}"`);
3933
+ }
3934
+ async getPopOverCategoryByName(categoryName) {
3935
+ return this.popoverCategoryTree.locator(".sw-tree-item__element").filter({ hasText: `${categoryName}` });
3681
3936
  }
3682
3937
  url() {
3683
3938
  return `#/sw/category/index`;
3684
3939
  }
3685
3940
  }
3686
3941
 
3942
+ var __defProp$6 = Object.defineProperty;
3943
+ var __defNormalProp$6 = (obj, key, value) => key in obj ? __defProp$6(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3944
+ var __publicField$6 = (obj, key, value) => {
3945
+ __defNormalProp$6(obj, typeof key !== "symbol" ? key + "" : key, value);
3946
+ return value;
3947
+ };
3948
+ class RuleDetail {
3949
+ constructor(page) {
3950
+ this.page = page;
3951
+ __publicField$6(this, "nameInput");
3952
+ __publicField$6(this, "priorityInput");
3953
+ __publicField$6(this, "conditionTypeSelectionInput");
3954
+ __publicField$6(this, "conditionValueSelectionInput");
3955
+ __publicField$6(this, "filtersResultPopoverSelectionList");
3956
+ this.nameInput = page.getByLabel("Name");
3957
+ this.priorityInput = page.getByLabel("Priority");
3958
+ this.conditionTypeSelectionInput = page.locator(".sw-condition-type-select").locator(".sw-single-select__selection");
3959
+ this.conditionValueSelectionInput = page.locator(".sw-condition__value-content").locator(".sw-entity-single-select__selection");
3960
+ this.filtersResultPopoverSelectionList = page.locator(".sw-select-result-list__content").getByRole("listitem");
3961
+ }
3962
+ url(ruleId, tabName = "base") {
3963
+ return `#/sw/settings/rule/detail/${ruleId}/${tabName}`;
3964
+ }
3965
+ }
3966
+
3967
+ var __defProp$5 = Object.defineProperty;
3968
+ var __defNormalProp$5 = (obj, key, value) => key in obj ? __defProp$5(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3969
+ var __publicField$5 = (obj, key, value) => {
3970
+ __defNormalProp$5(obj, typeof key !== "symbol" ? key + "" : key, value);
3971
+ return value;
3972
+ };
3973
+ class CustomFieldListing {
3974
+ constructor(page) {
3975
+ this.page = page;
3976
+ __publicField$5(this, "addNewSetButton");
3977
+ __publicField$5(this, "customFieldRows");
3978
+ this.addNewSetButton = page.getByText("Add new set");
3979
+ this.customFieldRows = page.getByRole("row");
3980
+ }
3981
+ async getLineItemByCustomFieldSetName(customFieldSetName) {
3982
+ const lineItem = this.page.getByRole("row").filter({ hasText: customFieldSetName });
3983
+ const customFieldSetNameText = lineItem.getByText(customFieldSetName);
3984
+ const customFieldSetContextButton = lineItem.locator(".sw-context-button__button");
3985
+ const customFieldSetEditButton = this.page.locator(".sw-context-menu__content").getByRole("link", { name: "Edit" });
3986
+ const customFieldSetDeleteButton = this.page.locator(".sw-context-menu__content").getByRole("link", { name: "Delete" });
3987
+ const warningDialog = this.page.getByRole("dialog", { name: "Warning" });
3988
+ const warningDialogCancelButton = warningDialog.getByRole("button", { name: "Cancel" });
3989
+ const warningDialogDeleteButton = warningDialog.getByRole("button", { name: "Delete" });
3990
+ return {
3991
+ customFieldSetNameText,
3992
+ customFieldSetContextButton,
3993
+ customFieldSetEditButton,
3994
+ customFieldSetDeleteButton,
3995
+ warningDialog,
3996
+ warningDialogCancelButton,
3997
+ warningDialogDeleteButton
3998
+ };
3999
+ }
4000
+ url() {
4001
+ return `#/sw/settings/custom/field/index`;
4002
+ }
4003
+ }
4004
+
4005
+ var __defProp$4 = Object.defineProperty;
4006
+ var __defNormalProp$4 = (obj, key, value) => key in obj ? __defProp$4(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
4007
+ var __publicField$4 = (obj, key, value) => {
4008
+ __defNormalProp$4(obj, typeof key !== "symbol" ? key + "" : key, value);
4009
+ return value;
4010
+ };
4011
+ class CustomFieldCreate {
4012
+ constructor(page) {
4013
+ this.page = page;
4014
+ __publicField$4(this, "saveButton");
4015
+ __publicField$4(this, "cancelButton");
4016
+ __publicField$4(this, "technicalNameInput");
4017
+ __publicField$4(this, "positionInput");
4018
+ __publicField$4(this, "labelEnglishGBInput");
4019
+ __publicField$4(this, "assignToSelectionList");
4020
+ __publicField$4(this, "resultAssignToPopoverItemList");
4021
+ this.saveButton = page.getByRole("button", { name: "Save" });
4022
+ this.cancelButton = page.getByRole("button", { name: "Cancel" });
4023
+ this.technicalNameInput = page.getByLabel("Technical name");
4024
+ this.positionInput = page.getByLabel("Position");
4025
+ this.labelEnglishGBInput = page.getByLabel("Label (English (GB))");
4026
+ this.assignToSelectionList = page.locator(".sw-field").filter({ hasText: "Assign To" }).locator(".sw-select__selection");
4027
+ this.resultAssignToPopoverItemList = page.locator(".sw-select-result-list__content").getByRole("listitem");
4028
+ }
4029
+ url() {
4030
+ return `#/sw/settings/custom/field/create`;
4031
+ }
4032
+ }
4033
+
4034
+ var __defProp$3 = Object.defineProperty;
4035
+ var __defNormalProp$3 = (obj, key, value) => key in obj ? __defProp$3(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
4036
+ var __publicField$3 = (obj, key, value) => {
4037
+ __defNormalProp$3(obj, typeof key !== "symbol" ? key + "" : key, value);
4038
+ return value;
4039
+ };
4040
+ class CustomFieldDetail extends CustomFieldCreate {
4041
+ constructor(page) {
4042
+ super(page);
4043
+ this.page = page;
4044
+ __publicField$3(this, "newCustomFieldButton");
4045
+ __publicField$3(this, "customFieldEditDialog");
4046
+ __publicField$3(this, "newCustomFieldDialog");
4047
+ __publicField$3(this, "customFieldTechnicalNameInput");
4048
+ __publicField$3(this, "customFieldPositionInput");
4049
+ __publicField$3(this, "customFieldTypeSelectionList");
4050
+ __publicField$3(this, "customFieldModifyByStoreApiCheckbox");
4051
+ __publicField$3(this, "customFieldCancelButton");
4052
+ __publicField$3(this, "customFieldAddButton");
4053
+ __publicField$3(this, "customFieldEditApplyButton");
4054
+ __publicField$3(this, "customFieldLabelEnglishGBInput");
4055
+ __publicField$3(this, "customFieldPlaceholderEnglishGBInput");
4056
+ __publicField$3(this, "customFieldHelpTextEnglishGBInput");
4057
+ __publicField$3(this, "customFieldDeleteListButton");
4058
+ __publicField$3(this, "customFieldDeleteDialog");
4059
+ __publicField$3(this, "customFieldDeleteCancelButton");
4060
+ __publicField$3(this, "customFieldDeleteButton");
4061
+ this.newCustomFieldButton = page.getByRole("button", { name: "New custom field" });
4062
+ this.customFieldDeleteListButton = page.locator(".sw-custom-field-list__delete-button");
4063
+ this.newCustomFieldDialog = page.getByRole("dialog", { name: "New custom field" });
4064
+ this.customFieldAddButton = this.newCustomFieldDialog.getByRole("button", { name: "Add" });
4065
+ this.customFieldTechnicalNameInput = this.newCustomFieldDialog.getByLabel("Technical Name");
4066
+ this.customFieldPositionInput = this.newCustomFieldDialog.getByLabel("Position");
4067
+ this.customFieldTypeSelectionList = this.newCustomFieldDialog.getByLabel("Type");
4068
+ this.customFieldModifyByStoreApiCheckbox = this.newCustomFieldDialog.getByLabel("Modifiable via Store API");
4069
+ this.customFieldCancelButton = this.newCustomFieldDialog.getByRole("button", { name: "Cancel" });
4070
+ this.customFieldLabelEnglishGBInput = this.newCustomFieldDialog.getByLabel("Label (English (GB))");
4071
+ this.customFieldPlaceholderEnglishGBInput = this.newCustomFieldDialog.getByLabel("Placeholder (English (GB))");
4072
+ this.customFieldHelpTextEnglishGBInput = this.newCustomFieldDialog.getByLabel("Help text (English (GB))");
4073
+ this.customFieldEditDialog = page.getByRole("dialog", { name: "Edit custom field" });
4074
+ this.customFieldEditApplyButton = this.customFieldEditDialog.getByRole("button", { name: "Apply changes" });
4075
+ this.customFieldDeleteDialog = page.getByRole("dialog", { name: "Delete custom field" });
4076
+ this.customFieldDeleteCancelButton = this.customFieldDeleteDialog.getByRole("button", { name: "Cancel" });
4077
+ this.customFieldDeleteButton = this.customFieldDeleteDialog.getByRole("button", { name: "Delete" });
4078
+ }
4079
+ async getLineItemByCustomFieldName(customFieldName) {
4080
+ const lineItem = this.page.getByRole("row").filter({ hasText: customFieldName });
4081
+ const customFieldCheckbox = lineItem.locator(".icon--regular-checkmark-xxs");
4082
+ const customFieldLabelText = lineItem.getByRole("textbox");
4083
+ const customFieldContextButton = lineItem.locator(".sw-context-button__button");
4084
+ const customFieldEditButton = this.page.locator(".sw-context-menu__content").getByRole("link", { name: "Edit" });
4085
+ const customFieldDeleteButton = this.page.locator(".sw-context-menu__content").getByRole("link", { name: "Delete" });
4086
+ const warningDialog = this.page.getByRole("dialog", { name: "Delete custom field" });
4087
+ const warningDialogCancelButton = warningDialog.getByRole("button", { name: "Cancel" });
4088
+ const warningDialogDeleteButton = warningDialog.getByRole("button", { name: "Delete" });
4089
+ return {
4090
+ customFieldLabelText,
4091
+ customFieldCheckbox,
4092
+ customFieldContextButton,
4093
+ customFieldEditButton,
4094
+ customFieldDeleteButton,
4095
+ warningDialog,
4096
+ warningDialogCancelButton,
4097
+ warningDialogDeleteButton
4098
+ };
4099
+ }
4100
+ url(customFieldUuid) {
4101
+ return `#/sw/settings/custom/field/detail/${customFieldUuid}`;
4102
+ }
4103
+ }
4104
+
4105
+ var __defProp$2 = Object.defineProperty;
4106
+ var __defNormalProp$2 = (obj, key, value) => key in obj ? __defProp$2(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
4107
+ var __publicField$2 = (obj, key, value) => {
4108
+ __defNormalProp$2(obj, typeof key !== "symbol" ? key + "" : key, value);
4109
+ return value;
4110
+ };
4111
+ class CategoryDetail {
4112
+ constructor(page) {
4113
+ this.page = page;
4114
+ __publicField$2(this, "saveButton");
4115
+ __publicField$2(this, "cancelButton");
4116
+ __publicField$2(this, "customFieldCard");
4117
+ __publicField$2(this, "customFieldSetTabs");
4118
+ __publicField$2(this, "customFieldSetTabCustomContent");
4119
+ this.saveButton = page.getByRole("button", { name: "Save" });
4120
+ this.cancelButton = page.getByRole("button", { name: "Cancel" });
4121
+ this.customFieldCard = page.locator(".sw-card").getByText("Custom fields");
4122
+ this.customFieldSetTabs = this.customFieldCard.locator(".sw-tabs-item");
4123
+ this.customFieldSetTabCustomContent = this.customFieldCard.locator(".sw-tabs__custom-content");
4124
+ }
4125
+ async getCustomFieldSetCardContentByName(customFieldSetName) {
4126
+ const customFieldCard = this.page.locator(".sw-card").filter({ hasText: "Custom fields" });
4127
+ const customFieldSetTab = customFieldCard.getByText(customFieldSetName);
4128
+ const customFieldSetTabCustomContent = customFieldCard.locator(`.sw-custom-field-set-renderer-tab-content__${customFieldSetName}`);
4129
+ return {
4130
+ customFieldSetTab,
4131
+ customFieldSetTabCustomContent
4132
+ };
4133
+ }
4134
+ url(categoryUuid) {
4135
+ return `#/sw/category/index/${categoryUuid}/base`;
4136
+ }
4137
+ }
4138
+
3687
4139
  var __defProp$1 = Object.defineProperty;
3688
4140
  var __defNormalProp$1 = (obj, key, value) => key in obj ? __defProp$1(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3689
4141
  var __publicField$1 = (obj, key, value) => {
3690
4142
  __defNormalProp$1(obj, typeof key !== "symbol" ? key + "" : key, value);
3691
4143
  return value;
3692
4144
  };
3693
- class RuleDetail {
4145
+ class RuleCreate {
3694
4146
  constructor(page) {
3695
4147
  this.page = page;
3696
4148
  __publicField$1(this, "nameInput");
3697
4149
  __publicField$1(this, "priorityInput");
4150
+ __publicField$1(this, "conditionTypeSelectionInput");
4151
+ __publicField$1(this, "conditionValueSelectionInput");
4152
+ __publicField$1(this, "filtersResultPopoverSelectionList");
4153
+ __publicField$1(this, "saveButton");
4154
+ __publicField$1(this, "cancelButton");
3698
4155
  this.nameInput = page.getByLabel("Name");
3699
4156
  this.priorityInput = page.getByLabel("Priority");
4157
+ this.conditionTypeSelectionInput = page.locator(".sw-condition-type-select").locator(".sw-single-select__selection");
4158
+ this.conditionValueSelectionInput = page.locator(".sw-condition__value-content").locator(".sw-entity-single-select__selection");
4159
+ this.filtersResultPopoverSelectionList = page.locator(".sw-select-result-list__content").getByRole("listitem");
4160
+ this.saveButton = page.getByRole("button", { name: "Save" });
4161
+ this.cancelButton = page.getByRole("button", { name: "Cancel" });
3700
4162
  }
3701
- url(ruleId, tabName = "base") {
3702
- return `#/sw/settings/rule/detail/${ruleId}/${tabName}`;
4163
+ url() {
4164
+ return `#/sw/settings/rule/create/base`;
3703
4165
  }
3704
4166
  }
3705
4167
 
@@ -3715,9 +4177,14 @@ const AdminPageObjects = {
3715
4177
  DataSharing,
3716
4178
  ShippingListing,
3717
4179
  Categories,
4180
+ CategoryDetail,
3718
4181
  LandingPageCreate,
3719
4182
  LandingPageDetail,
3720
- RuleDetail
4183
+ RuleDetail,
4184
+ RuleCreate,
4185
+ CustomFieldListing,
4186
+ CustomFieldCreate,
4187
+ CustomFieldDetail
3721
4188
  };
3722
4189
  const test$5 = test$e.extend({
3723
4190
  AdminProductDetail: async ({ AdminPage }, use) => {
@@ -3753,6 +4220,9 @@ const test$5 = test$e.extend({
3753
4220
  AdminCategories: async ({ AdminPage }, use) => {
3754
4221
  await use(new Categories(AdminPage));
3755
4222
  },
4223
+ AdminCategoryDetail: async ({ AdminPage }, use) => {
4224
+ await use(new CategoryDetail(AdminPage));
4225
+ },
3756
4226
  AdminLandingPageDetail: async ({ AdminPage }, use) => {
3757
4227
  await use(new LandingPageDetail(AdminPage));
3758
4228
  },
@@ -3761,6 +4231,18 @@ const test$5 = test$e.extend({
3761
4231
  },
3762
4232
  AdminRuleDetail: async ({ AdminPage }, use) => {
3763
4233
  await use(new RuleDetail(AdminPage));
4234
+ },
4235
+ AdminRuleCreate: async ({ AdminPage }, use) => {
4236
+ await use(new RuleCreate(AdminPage));
4237
+ },
4238
+ AdminCustomFieldListing: async ({ AdminPage }, use) => {
4239
+ await use(new CustomFieldListing(AdminPage));
4240
+ },
4241
+ AdminCustomFieldCreate: async ({ AdminPage }, use) => {
4242
+ await use(new CustomFieldCreate(AdminPage));
4243
+ },
4244
+ AdminCustomFieldDetail: async ({ AdminPage }, use) => {
4245
+ await use(new CustomFieldDetail(AdminPage));
3764
4246
  }
3765
4247
  });
3766
4248
 
@@ -4422,6 +4904,66 @@ const Register = test$e.extend({
4422
4904
  }
4423
4905
  });
4424
4906
 
4907
+ const RegisterGuest = test$e.extend({
4908
+ RegisterGuest: async ({ StorefrontAccountLogin, AdminApiContext }, use) => {
4909
+ const registrationData = {
4910
+ firstName: "Jeff",
4911
+ lastName: "Goldblum",
4912
+ email: "invalid",
4913
+ password: "shopware",
4914
+ street: "Ebbinghof 10",
4915
+ city: "Sch\xF6ppingen",
4916
+ country: "Germany",
4917
+ postalCode: "48624"
4918
+ };
4919
+ const task = (email, country = "Germany") => {
4920
+ return async function RegisterGuest2() {
4921
+ registrationData.email = email;
4922
+ await StorefrontAccountLogin.firstNameInput.fill(registrationData.firstName);
4923
+ await StorefrontAccountLogin.lastNameInput.fill(registrationData.lastName);
4924
+ await StorefrontAccountLogin.registerEmailInput.fill(registrationData.email);
4925
+ await StorefrontAccountLogin.streetAddressInput.fill(registrationData.street);
4926
+ await StorefrontAccountLogin.cityInput.fill(registrationData.city);
4927
+ if (country != "Germany") {
4928
+ await StorefrontAccountLogin.countryInput.selectOption(country);
4929
+ } else {
4930
+ await StorefrontAccountLogin.countryInput.selectOption(registrationData.country);
4931
+ }
4932
+ await StorefrontAccountLogin.postalCodeInput.fill(registrationData.postalCode);
4933
+ await StorefrontAccountLogin.registerButton.click();
4934
+ };
4935
+ };
4936
+ await use(task);
4937
+ const customerResponse = await AdminApiContext.post("search/customer", {
4938
+ data: {
4939
+ limit: 1,
4940
+ filter: [{
4941
+ type: "equals",
4942
+ field: "email",
4943
+ value: registrationData.email
4944
+ }]
4945
+ }
4946
+ });
4947
+ expect(customerResponse.ok()).toBeTruthy();
4948
+ const customerResponseData = await customerResponse.json();
4949
+ for (const customer of customerResponseData.data) {
4950
+ await AdminApiContext.delete(`customer/${customer.id}`);
4951
+ }
4952
+ }
4953
+ });
4954
+
4955
+ const ChangeStorefrontCurrency = test$e.extend({
4956
+ ChangeStorefrontCurrency: async ({ StorefrontHome }, use) => {
4957
+ const task = (isoCode) => {
4958
+ return async function ChangeStorefrontCurrency2() {
4959
+ await StorefrontHome.currenciesDropdown.click();
4960
+ await StorefrontHome.currenciesDropdown.getByText(" " + isoCode).click();
4961
+ };
4962
+ };
4963
+ await use(task);
4964
+ }
4965
+ });
4966
+
4425
4967
  const AddProductToCart = test$e.extend({
4426
4968
  AddProductToCart: async ({ ShopCustomer, StorefrontProductDetail }, use) => {
4427
4969
  const task = (ProductData, quantity = "1") => {
@@ -4621,6 +5163,8 @@ const test$2 = mergeTests(
4621
5163
  Login,
4622
5164
  Logout,
4623
5165
  Register,
5166
+ RegisterGuest,
5167
+ ChangeStorefrontCurrency,
4624
5168
  AddProductToCart,
4625
5169
  ChangeProductQuantity,
4626
5170
  ProceedFromProductToCheckout,