test: Move clicking helper functions to wizardTestUtils

As clicking helper functions are used only in the context of Wizard, this moves them to an appropriate place.
This commit is contained in:
regexowl 2024-08-09 15:00:05 +02:00 committed by Ondřej Ezr
parent a3abc29f51
commit d0412db518
18 changed files with 66 additions and 83 deletions

View file

@ -4,7 +4,7 @@ import { userEvent } from '@testing-library/user-event';
import { CREATE_BLUEPRINT, EDIT_BLUEPRINT } from '../../../../../constants';
import { mockBlueprintIds } from '../../../../fixtures/blueprints';
import { detailsCreateBlueprintRequest } from '../../../../fixtures/editMode';
import { clickNext, getNextButton } from '../../../../testUtils';
import { clickNext, getNextButton } from '../../wizardTestUtils';
import {
blueprintRequest,
clickRegisterLater,

View file

@ -10,7 +10,7 @@ import {
} from '../../../../../constants';
import { mockBlueprintIds } from '../../../../fixtures/blueprints';
import { fscCreateBlueprintRequest } from '../../../../fixtures/editMode';
import { clickNext } from '../../../../testUtils';
import { clickNext } from '../../wizardTestUtils';
import {
blueprintRequest,
clickRegisterLater,

View file

@ -13,7 +13,7 @@ import {
firstBootCreateBlueprintRequest,
firstBootData,
} from '../../../../fixtures/editMode';
import { clickNext, getNextButton } from '../../../../testUtils';
import { clickNext, getNextButton } from '../../wizardTestUtils';
import {
blueprintRequest,
clickRegisterLater,

View file

@ -26,10 +26,8 @@ import {
rhel9CreateBlueprintRequest,
x86_64CreateBlueprintRequest,
} from '../../../../fixtures/editMode';
import {
clickNext,
renderCustomRoutesWithReduxRouter,
} from '../../../../testUtils';
import { renderCustomRoutesWithReduxRouter } from '../../../../testUtils';
import { clickNext } from '../../wizardTestUtils';
import {
blueprintRequest,
clickRegisterLater,

View file

@ -13,7 +13,7 @@ import {
expectedServicesCisL2,
oscapCreateBlueprintRequest,
} from '../../../../fixtures/editMode';
import { clickNext } from '../../../../testUtils';
import { clickNext } from '../../wizardTestUtils';
import {
clickRegisterLater,
enterBlueprintName,

View file

@ -11,7 +11,7 @@ import {
expectedSinglePackageRecommendation,
packagesCreateBlueprintRequest,
} from '../../../../fixtures/editMode';
import { clickNext } from '../../../../testUtils';
import { clickNext } from '../../wizardTestUtils';
import { selectCustomRepo } from '../../wizardTestUtils';
import {
blueprintRequest,

View file

@ -24,12 +24,12 @@ import {
import { mockBlueprintIds } from '../../../../fixtures/blueprints';
import { registrationCreateBlueprintRequest } from '../../../../fixtures/editMode';
import { server } from '../../../../mocks/server';
import { renderCustomRoutesWithReduxRouter } from '../../../../testUtils';
import {
clickBack,
clickNext,
renderCustomRoutesWithReduxRouter,
verifyCancelButton,
} from '../../../../testUtils';
} from '../../wizardTestUtils';
import {
enterBlueprintName,
renderCreateMode,

View file

@ -13,7 +13,7 @@ import {
expectedPayloadRepositories,
repositoriesCreateBlueprintRequest,
} from '../../../../fixtures/editMode';
import { clickNext } from '../../../../testUtils';
import { clickNext } from '../../wizardTestUtils';
import {
blueprintRequest,
clickRegisterLater,

View file

@ -9,7 +9,7 @@ import {
expectedPayloadRepositories,
snapshotCreateBlueprintRequest,
} from '../../../../fixtures/editMode';
import { clickNext } from '../../../../testUtils';
import { clickNext } from '../../wizardTestUtils';
import {
blueprintRequest,
clickRegisterLater,

View file

@ -8,7 +8,7 @@ import {
} from '../../../../../store/imageBuilderApi';
import { mockBlueprintIds } from '../../../../fixtures/blueprints';
import { awsCreateBlueprintRequest } from '../../../../fixtures/editMode';
import { clickBack, clickNext } from '../../../../testUtils';
import { clickBack, clickNext } from '../../wizardTestUtils';
import {
blueprintRequest,
clickRegisterLater,

View file

@ -8,7 +8,7 @@ import {
} from '../../../../../store/imageBuilderApi';
import { mockBlueprintIds } from '../../../../fixtures/blueprints';
import { azureCreateBlueprintRequest } from '../../../../fixtures/editMode';
import { clickBack, clickNext } from '../../../../testUtils';
import { clickBack, clickNext } from '../../wizardTestUtils';
import {
blueprintRequest,
clickRegisterLater,

View file

@ -10,7 +10,7 @@ import {
} from '../../../../../store/imageBuilderApi';
import { mockBlueprintIds } from '../../../../fixtures/blueprints';
import { gcpCreateBlueprintRequest } from '../../../../fixtures/editMode';
import { clickBack, clickNext } from '../../../../testUtils';
import { clickBack, clickNext } from '../../wizardTestUtils';
import {
blueprintRequest,
clickRegisterLater,