Skip to content

Commit

Permalink
Merge pull request #3 from shopware/public-page-object-params
Browse files Browse the repository at this point in the history
fix: make page object props public
  • Loading branch information
pweyck authored May 22, 2024
2 parents b18d68b + a85ff8d commit 007e4b5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion src/page-objects/administration/CustomerDetail.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,15 @@ import type { components } from '@shopware/api-client/admin-api-types';

export class CustomerDetail implements PageObject {
public readonly customerId;
public readonly customer: components['schemas']['Customer'];

public readonly editButton: Locator;
public readonly generalTab: Locator;
public readonly accountCard: Locator;

constructor(public readonly page: Page, customer :components['schemas']['Customer'] ) {
constructor(public readonly page: Page, customer: components['schemas']['Customer'] ) {
this.customerId = customer.id;
this.customer = customer;
this.editButton = page.getByRole('button', { name: 'Edit' });
this.generalTab = page.getByRole('link', { name: 'General' });
this.accountCard = page.locator('.sw-customer-card')
Expand Down
2 changes: 1 addition & 1 deletion src/page-objects/administration/OrderDetail.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export class OrderDetail implements PageObject {
public readonly dataGridContextButton: Locator;
public readonly orderTag: Locator;

private readonly orderData: components['schemas']['Order'];
public readonly orderData: components['schemas']['Order'];

constructor(public readonly page: Page, orderData: components['schemas']['Order']) {
this.orderData = orderData;
Expand Down

0 comments on commit 007e4b5

Please sign in to comment.