Skip to content

Conversation

@kkrawczyk123
Copy link
Collaborator

Add page elements and assertions for:

  • putaway details tabs their contents
  • putaway list page default filtering
  • use search bar on putaway list page
  • use reload button on edit putaway
  • download putaway pdf


get rows() {
return this.table.getByRole('row');
return this.table.getByRole('cell');
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume it's due to badly written HTML, not your fault

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds comprehensive test assertions for putaway details and list pages in the e2e test suite, along with upgrading Playwright from version 1.34.0 to 1.57.0 and updating the Node.js runtime from version 14 to 18.

Key Changes:

  • Added new test file with detailed assertions for putaway workflows including creation, viewing, editing, and completion
  • Created new page object models for OrderHeaderTable and ItemStatusTable components
  • Updated existing page objects to include additional UI element getters for enhanced test coverage
  • Upgraded Playwright test framework and Node.js runtime to newer versions

Reviewed changes

Copilot reviewed 10 out of 11 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
src/tests/putaway/assertPutawayDetailsPage.test.ts New comprehensive test file covering putaway details page functionality with multiple test steps for creating, viewing, and completing putaway orders
src/pages/putaway/putawayDetails/components/SummaryTable.ts Modified table element selectors and added getColumnHeader method for column validation
src/pages/putaway/putawayDetails/components/OrderHeaderTable.ts New page object for order header table with getters for order number, status, and order type
src/pages/putaway/putawayDetails/components/ItemStatusTable.ts New page object for item status table with row navigation and status field getters
src/pages/putaway/putawayDetails/PutawayDetailsPage.ts Added multiple button and action menu element getters, integrated new table components
src/pages/putaway/list/PutawayListTable.ts Added statusTag getter for row status verification
src/pages/putaway/list/PutawayListPage.ts Added filter and search element getters for list page interactions
package.json Upgraded @playwright/test from ~1.34.0 to ~1.57.0
package-lock.json Updated lockfile to reflect Playwright upgrade and dependency changes
README.md Updated Node requirement from 14.21.x to 18.19.x and NPM from 6.14.6 to 9.2.0
.github/workflows/playwright.yml Updated Node.js version from 14 to 18 in CI workflow

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.


get rows() {
return this.table.getByRole('row');
return this.table.getByRole('cell');
Copy link

Copilot AI Dec 2, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The rows getter returns cells instead of rows, which is semantically incorrect. It should return this.table.getByRole('row') to properly represent table rows. This mismatch between the getter name and what it returns could cause confusion and bugs when developers expect to work with rows but are actually working with cells.

Suggested change
return this.table.getByRole('cell');
return this.table.getByRole('row');

Copilot uses AI. Check for mistakes.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, I mentioned that above

}

get rows() {
return this.table.getByRole('cell');
Copy link

Copilot AI Dec 2, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar issue: the rows getter returns cells (getByRole('cell')) instead of rows. This should be this.table.getByRole('row') to correctly represent table rows and maintain consistency with the getter name.

Suggested change
return this.table.getByRole('cell');
return this.table.getByRole('row');

Copilot uses AI. Check for mistakes.
Comment on lines 35 to 49
return this.page
.getByTestId('item-status-table')
.getByTestId('order-item-status-code');
}

get originBin() {
return this.page
.getByTestId('item-status-table')
.getByTestId('origin-bin-location');
}

get destinationBin() {
return this.page
.getByTestId('item-status-table')
.getByTestId('destination-bin-location');
Copy link

Copilot AI Dec 2, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Row class getters (itemStatus, originBin, destinationBin) don't use the row property that was passed in the constructor. They all query from this.page.getByTestId('item-status-table') directly, making the Row instance's locator redundant. These getters will always return the first matching element in the table regardless of which row instance is being accessed, potentially causing incorrect assertions when there are multiple rows.

Suggested change
return this.page
.getByTestId('item-status-table')
.getByTestId('order-item-status-code');
}
get originBin() {
return this.page
.getByTestId('item-status-table')
.getByTestId('origin-bin-location');
}
get destinationBin() {
return this.page
.getByTestId('item-status-table')
.getByTestId('destination-bin-location');
return this.row.getByTestId('order-item-status-code');
}
get originBin() {
return this.row.getByTestId('origin-bin-location');
}
get destinationBin() {
return this.row.getByTestId('destination-bin-location');

Copilot uses AI. Check for mistakes.
@alannadolny alannadolny merged commit 31e2239 into main Dec 3, 2025
0 of 2 checks passed
@alannadolny alannadolny deleted the OBPIH-7531 branch December 3, 2025 11:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants