mirror of
https://github.com/inventree/InvenTree.git
synced 2026-07-18 12:36:11 +00:00
* UX: Disable standard allocation for trackable parts and add tooltip (#11811) * Test: Update Playwright tests for disabled trackable allocation * Fix: Align trackable allocation logic and tests based on review * Test: Fix incorrect assumption of trackable Red Widget in pui_build.spec.ts --------- Co-authored-by: Matthias Mair <code@mjmair.com>
This commit is contained in:
co-authored by
Matthias Mair
parent
20309146aa
commit
c2c8e72f37
@@ -418,6 +418,18 @@ test('Build Order - Allocation', async ({ browser }) => {
|
||||
|
||||
await row.getByText(/150 \/ 150/).waitFor();
|
||||
|
||||
// Open the allocation menu for the red widget
|
||||
const mainRedWidget = await page.getByRole('cell', { name: 'Red Widget' });
|
||||
const mainRedRow = await getRowFromCell(mainRedWidget);
|
||||
|
||||
await mainRedRow.getByLabel(/row-action-menu-/i).click();
|
||||
|
||||
await page
|
||||
.getByRole('menuitem', { name: 'Allocate Stock', exact: true })
|
||||
.waitFor();
|
||||
|
||||
await page.keyboard.press('Escape');
|
||||
|
||||
// Expand this row
|
||||
await cell.click();
|
||||
await page.getByRole('cell', { name: '2022-4-27', exact: true }).waitFor();
|
||||
@@ -494,9 +506,13 @@ test('Build Order - Allocation', async ({ browser }) => {
|
||||
const redRow = await getRowFromCell(redWidget);
|
||||
|
||||
await redRow.getByLabel(/row-action-menu-/i).click();
|
||||
await page
|
||||
.getByRole('menuitem', { name: 'Allocate Stock', exact: true })
|
||||
.waitFor();
|
||||
|
||||
const allocateStockBtn = page.getByRole('menuitem', {
|
||||
name: 'Allocate Stock',
|
||||
exact: true
|
||||
});
|
||||
await expect(allocateStockBtn).toBeEnabled();
|
||||
|
||||
await page
|
||||
.getByRole('menuitem', { name: 'Deallocate Stock', exact: true })
|
||||
.waitFor();
|
||||
|
||||
Reference in New Issue
Block a user