Skip to content

OBPIH-6956 Add tests for assert qty and split line with 0 qty #50

Merged
awalkowiak merged 4 commits intomainfrom
OBPIH-6956
Mar 11, 2025
Merged

OBPIH-6956 Add tests for assert qty and split line with 0 qty #50
awalkowiak merged 4 commits intomainfrom
OBPIH-6956

Conversation

@kkrawczyk123
Copy link
Collaborator

Added tests for assert qty inputs when split lines, edit original qty to 0 and to edit original line to another item.


get clearProductSelect() {
return this.row.locator(
'[class="css-16pqwjk-indicatorContainer react-select__indicator react-select__clear-indicator"]'
Copy link
Contributor

Choose a reason for hiding this comment

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

Are you sure this css class is constant? Let's double check that this 16pqwjk is not changing.

import { StockMovementResponse } from '@/types';
import { formatDate, getDateByOffset } from '@/utils/DateUtils';

test.describe('Assert qty inputs when split lines', () => {
Copy link
Contributor

Choose a reason for hiding this comment

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

What are you "asserting" here?

Copy link
Contributor

Choose a reason for hiding this comment

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

Plus maybe it would be better to use full quantity instead qty in these descriptions

receivingPage.receivingStep.table.row(5).receivingNowField.textbox
).toHaveValue('100');
await expect(
receivingPage.receivingStep.table.getCellValue(2, 'Lot/Serial No.')
Copy link
Contributor

Choose a reason for hiding this comment

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

Can you move this to some constant?

receivingPage.receivingStep.table.getCellValue(2, 'Lot/Serial No.')
).toContainText(lot);
await expect(
receivingPage.receivingStep.table.getCellValue(2, 'Expiration date')
Copy link
Contributor

Choose a reason for hiding this comment

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

Same as above

@awalkowiak awalkowiak merged commit 65b5d27 into main Mar 11, 2025
1 check failed
@awalkowiak awalkowiak deleted the OBPIH-6956 branch March 11, 2025 11:02
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.

2 participants