using JdeScoping.Ui.Tests.Support;
namespace JdeScoping.Ui.Tests;
///
/// Playwright UI tests for the "Time Span + Profit Center + Item/Operation/MIS" search type (TC-070).
/// Validates search form interaction in smoke mode and full submission in strict mode.
/// Requires a running Docker host (Category: RequiresDockerHost).
///
public sealed class TimeSpanPcPartOpSearchTests(PlaywrightFixture fixture) : SearchFlowTestBase(fixture)
{
///
/// Verifies the Time Span + Profit Center + Item/Operation/MIS search form submits with autocomplete and upload (TC-070).
///
///
/// Steps (smoke mode stops after step 4; strict mode runs all steps):
/// 1. Navigate to the search page.
/// 2. Enter the search name "MIGRATED-TC-070".
/// 3. Select the "Time Span + Profit Center + Item/Operation/MIS" search type from the dropdown.
/// 4. Verify the dropdown displays the selected type.
/// 5. Set the date range to 01/01/2019 – 12/31/2019 (strict only).
/// 6. Add autocomplete value "1AM" to the "Filter by Profit Center" panel (strict only).
/// 7. Upload "single_operation.xlsx" to the "Filter By Item/Operation/MIS" panel (strict only).
/// 8. Click Submit (strict only).
/// 9. Assert no error notification is present (strict only).
///
[Fact]
[Trait("Category", "RequiresDockerHost")]
public Task TimeSpanPcPartOp_Submits()
{
return RunSearchSubmissionAsync(
UiSearchTypes.TimeSpanPcPartOp,
"MIGRATED-TC-070",
"01/01/2019",
"12/31/2019",
[
("Filter by Profit Center", "1AM")
],
[
("Filter By Item/Operation/MIS", "single_operation.xlsx")
]);
}
}