@shopware-ag/acceptance-test-suite 11.33.2 → 11.34.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.d.mts +15 -0
- package/dist/index.d.ts +15 -0
- package/dist/index.mjs +46 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -5090,6 +5090,17 @@ declare class ListingPageLayoutDetail implements PageObject {
|
|
|
5090
5090
|
url(layoutId: string): string;
|
|
5091
5091
|
}
|
|
5092
5092
|
|
|
5093
|
+
declare class SalesChannelDetail implements PageObject {
|
|
5094
|
+
readonly page: Page$1;
|
|
5095
|
+
readonly generalTabLink: Locator$1;
|
|
5096
|
+
readonly productsTabLink: Locator$1;
|
|
5097
|
+
readonly themeTabLink: Locator$1;
|
|
5098
|
+
readonly analyticsTabLink: Locator$1;
|
|
5099
|
+
readonly addDomainButton: Locator$1;
|
|
5100
|
+
constructor(page: Page$1);
|
|
5101
|
+
url(salesChannelId: string): string;
|
|
5102
|
+
}
|
|
5103
|
+
|
|
5093
5104
|
interface AdministrationPageTypes {
|
|
5094
5105
|
AdminProductDetail: ProductDetail$1;
|
|
5095
5106
|
AdminOrderDetail: OrderDetail;
|
|
@@ -5130,6 +5141,7 @@ interface AdministrationPageTypes {
|
|
|
5130
5141
|
AdminPromotionsListing: PromotionsListing;
|
|
5131
5142
|
AdminPromotionCreate: PromotionCreate;
|
|
5132
5143
|
AdminPromotionDetail: PromotionDetail;
|
|
5144
|
+
AdminSalesChannelDetail: SalesChannelDetail;
|
|
5133
5145
|
AdminShopwareServices: ShopwareServices;
|
|
5134
5146
|
AdminMedia: Media;
|
|
5135
5147
|
AdminYourProfile: YourProfile;
|
|
@@ -5177,6 +5189,7 @@ declare const AdminPageObjects: {
|
|
|
5177
5189
|
SettingsListing: typeof SettingsListing;
|
|
5178
5190
|
DocumentListing: typeof DocumentListing;
|
|
5179
5191
|
DocumentDetail: typeof DocumentDetail;
|
|
5192
|
+
SalesChannelDetail: typeof SalesChannelDetail;
|
|
5180
5193
|
ShopwareServices: typeof ShopwareServices;
|
|
5181
5194
|
PromotionsListing: typeof PromotionsListing;
|
|
5182
5195
|
PromotionCreate: typeof PromotionCreate;
|
|
@@ -5908,6 +5921,8 @@ declare const test: playwright_test.TestType<playwright_test.PlaywrightTestArgs
|
|
|
5908
5921
|
AddProductToWishlist: Task;
|
|
5909
5922
|
} & {
|
|
5910
5923
|
SelectProductFilterOption: Task;
|
|
5924
|
+
} & {
|
|
5925
|
+
CheckVisibilityInHome: Task;
|
|
5911
5926
|
}, playwright_test.PlaywrightWorkerArgs & playwright_test.PlaywrightWorkerOptions & FixtureTypes>;
|
|
5912
5927
|
|
|
5913
5928
|
export { AdminPageObjects, BUNDLED_RESOURCES, IdProvider, LanguageHelper, RuleType, StorefrontPageObjects, TestDataService, assertScreenshot, baseNamespaces, compareFlowTemplateWithFlow, createRandomImage, encodeImage, extractIdFromUrl, getCountryId, getCurrency, getCurrentContext, getDefaultShippingMethodId, getFlow, getFlowId, getFlowTemplate, getLanguageData, getMediaId, getOrderTransactionId, getPaymentMethodId, getPromotionWithDiscount, getSalutationId, getShippingMethodId, getSnippetSetId, getStateMachineId, getStateMachineStateId, getTaxId, getThemeId, hideElements, isSaaSInstance, isThemeCompiled, replaceElements, replaceElementsIndividually, setCurrentContext, setOrderStatus, setViewport, test, translate, updateAdminUser };
|
package/dist/index.d.ts
CHANGED
|
@@ -5090,6 +5090,17 @@ declare class ListingPageLayoutDetail implements PageObject {
|
|
|
5090
5090
|
url(layoutId: string): string;
|
|
5091
5091
|
}
|
|
5092
5092
|
|
|
5093
|
+
declare class SalesChannelDetail implements PageObject {
|
|
5094
|
+
readonly page: Page$1;
|
|
5095
|
+
readonly generalTabLink: Locator$1;
|
|
5096
|
+
readonly productsTabLink: Locator$1;
|
|
5097
|
+
readonly themeTabLink: Locator$1;
|
|
5098
|
+
readonly analyticsTabLink: Locator$1;
|
|
5099
|
+
readonly addDomainButton: Locator$1;
|
|
5100
|
+
constructor(page: Page$1);
|
|
5101
|
+
url(salesChannelId: string): string;
|
|
5102
|
+
}
|
|
5103
|
+
|
|
5093
5104
|
interface AdministrationPageTypes {
|
|
5094
5105
|
AdminProductDetail: ProductDetail$1;
|
|
5095
5106
|
AdminOrderDetail: OrderDetail;
|
|
@@ -5130,6 +5141,7 @@ interface AdministrationPageTypes {
|
|
|
5130
5141
|
AdminPromotionsListing: PromotionsListing;
|
|
5131
5142
|
AdminPromotionCreate: PromotionCreate;
|
|
5132
5143
|
AdminPromotionDetail: PromotionDetail;
|
|
5144
|
+
AdminSalesChannelDetail: SalesChannelDetail;
|
|
5133
5145
|
AdminShopwareServices: ShopwareServices;
|
|
5134
5146
|
AdminMedia: Media;
|
|
5135
5147
|
AdminYourProfile: YourProfile;
|
|
@@ -5177,6 +5189,7 @@ declare const AdminPageObjects: {
|
|
|
5177
5189
|
SettingsListing: typeof SettingsListing;
|
|
5178
5190
|
DocumentListing: typeof DocumentListing;
|
|
5179
5191
|
DocumentDetail: typeof DocumentDetail;
|
|
5192
|
+
SalesChannelDetail: typeof SalesChannelDetail;
|
|
5180
5193
|
ShopwareServices: typeof ShopwareServices;
|
|
5181
5194
|
PromotionsListing: typeof PromotionsListing;
|
|
5182
5195
|
PromotionCreate: typeof PromotionCreate;
|
|
@@ -5908,6 +5921,8 @@ declare const test: playwright_test.TestType<playwright_test.PlaywrightTestArgs
|
|
|
5908
5921
|
AddProductToWishlist: Task;
|
|
5909
5922
|
} & {
|
|
5910
5923
|
SelectProductFilterOption: Task;
|
|
5924
|
+
} & {
|
|
5925
|
+
CheckVisibilityInHome: Task;
|
|
5911
5926
|
}, playwright_test.PlaywrightWorkerArgs & playwright_test.PlaywrightWorkerOptions & FixtureTypes>;
|
|
5912
5927
|
|
|
5913
5928
|
export { AdminPageObjects, BUNDLED_RESOURCES, IdProvider, LanguageHelper, RuleType, StorefrontPageObjects, TestDataService, assertScreenshot, baseNamespaces, compareFlowTemplateWithFlow, createRandomImage, encodeImage, extractIdFromUrl, getCountryId, getCurrency, getCurrentContext, getDefaultShippingMethodId, getFlow, getFlowId, getFlowTemplate, getLanguageData, getMediaId, getOrderTransactionId, getPaymentMethodId, getPromotionWithDiscount, getSalutationId, getShippingMethodId, getSnippetSetId, getStateMachineId, getStateMachineStateId, getTaxId, getThemeId, hideElements, isSaaSInstance, isThemeCompiled, replaceElements, replaceElementsIndividually, setCurrentContext, setOrderStatus, setViewport, test, translate, updateAdminUser };
|
package/dist/index.mjs
CHANGED
|
@@ -217,6 +217,7 @@ class AdminApiContext {
|
|
|
217
217
|
}
|
|
218
218
|
});
|
|
219
219
|
const authData = await authResponse.json();
|
|
220
|
+
expect(authResponse.ok(), "Should authenticate with client credentials").toBeTruthy();
|
|
220
221
|
if (!authData["access_token"]) {
|
|
221
222
|
throw new Error(`Failed to authenticate with client_id: ${options.client_id}`);
|
|
222
223
|
}
|
|
@@ -233,6 +234,7 @@ class AdminApiContext {
|
|
|
233
234
|
}
|
|
234
235
|
});
|
|
235
236
|
const authData = await authResponse.json();
|
|
237
|
+
expect(authResponse.ok(), "Should authenticate with user credentials").toBeTruthy();
|
|
236
238
|
if (!authData["access_token"]) {
|
|
237
239
|
throw new Error(`Failed to authenticate with user: ${options.admin_username}`);
|
|
238
240
|
}
|
|
@@ -9676,6 +9678,25 @@ class ListingPageLayoutDetail {
|
|
|
9676
9678
|
}
|
|
9677
9679
|
}
|
|
9678
9680
|
|
|
9681
|
+
class SalesChannelDetail {
|
|
9682
|
+
constructor(page) {
|
|
9683
|
+
this.page = page;
|
|
9684
|
+
this.generalTabLink = page.getByRole("tab", { name: "General" });
|
|
9685
|
+
this.productsTabLink = page.getByRole("tab", { name: "Products" });
|
|
9686
|
+
this.themeTabLink = page.getByRole("tab", { name: "Theme" });
|
|
9687
|
+
this.analyticsTabLink = page.getByRole("tab", { name: "Analytics" });
|
|
9688
|
+
this.addDomainButton = page.getByRole("button", { name: "Add domain" });
|
|
9689
|
+
}
|
|
9690
|
+
generalTabLink;
|
|
9691
|
+
productsTabLink;
|
|
9692
|
+
themeTabLink;
|
|
9693
|
+
analyticsTabLink;
|
|
9694
|
+
addDomainButton;
|
|
9695
|
+
url(salesChannelId) {
|
|
9696
|
+
return `#/sw/sales/channel/detail/${salesChannelId}`;
|
|
9697
|
+
}
|
|
9698
|
+
}
|
|
9699
|
+
|
|
9679
9700
|
const AdminPageObjects = {
|
|
9680
9701
|
ProductDetail,
|
|
9681
9702
|
OrderDetail,
|
|
@@ -9713,6 +9734,7 @@ const AdminPageObjects = {
|
|
|
9713
9734
|
SettingsListing,
|
|
9714
9735
|
DocumentListing,
|
|
9715
9736
|
DocumentDetail,
|
|
9737
|
+
SalesChannelDetail,
|
|
9716
9738
|
ShopwareServices,
|
|
9717
9739
|
PromotionsListing,
|
|
9718
9740
|
PromotionCreate,
|
|
@@ -9870,6 +9892,9 @@ const test$6 = test$e.extend({
|
|
|
9870
9892
|
},
|
|
9871
9893
|
AdminLayoutCreate: async ({ AdminPage }, use) => {
|
|
9872
9894
|
await use(new LayoutCreate(AdminPage));
|
|
9895
|
+
},
|
|
9896
|
+
AdminSalesChannelDetail: async ({ AdminPage }, use) => {
|
|
9897
|
+
await use(new SalesChannelDetail(AdminPage));
|
|
9873
9898
|
}
|
|
9874
9899
|
});
|
|
9875
9900
|
|
|
@@ -11308,6 +11333,25 @@ const SelectProductFilterOption = test$e.extend({
|
|
|
11308
11333
|
}
|
|
11309
11334
|
});
|
|
11310
11335
|
|
|
11336
|
+
const CheckVisibilityInHome = test$e.extend({
|
|
11337
|
+
CheckVisibilityInHome: async ({ ShopCustomer, StorefrontHome, TestDataService }, use) => {
|
|
11338
|
+
const task = (productName) => {
|
|
11339
|
+
return async function CheckVisibilityInHome2() {
|
|
11340
|
+
await TestDataService.clearCaches();
|
|
11341
|
+
const productLocators = await StorefrontHome.getListingItemByProductName(productName);
|
|
11342
|
+
await ShopCustomer.expects(async () => {
|
|
11343
|
+
await ShopCustomer.goesTo(`${StorefrontHome.url()}?a=${Date.now()}`);
|
|
11344
|
+
await ShopCustomer.expects(productLocators.productName).toBeVisible();
|
|
11345
|
+
}).toPass({
|
|
11346
|
+
intervals: [1e3, 2500]
|
|
11347
|
+
// retry after 1 seconds, then every 2.5 seconds
|
|
11348
|
+
});
|
|
11349
|
+
};
|
|
11350
|
+
};
|
|
11351
|
+
await use(task);
|
|
11352
|
+
}
|
|
11353
|
+
});
|
|
11354
|
+
|
|
11311
11355
|
const test$3 = mergeTests(
|
|
11312
11356
|
Login,
|
|
11313
11357
|
Logout,
|
|
@@ -11333,7 +11377,8 @@ const test$3 = mergeTests(
|
|
|
11333
11377
|
RemoveProductFromWishlist,
|
|
11334
11378
|
AddProductToCartFromWishlist,
|
|
11335
11379
|
AddProductToWishlist,
|
|
11336
|
-
SelectProductFilterOption
|
|
11380
|
+
SelectProductFilterOption,
|
|
11381
|
+
CheckVisibilityInHome
|
|
11337
11382
|
);
|
|
11338
11383
|
|
|
11339
11384
|
class FeatureService {
|