test/fixtures: Migrate some fixtures to TypeScript

This migrates following fixtures to TypeScript:
- architectures
- customizations
- sources

Typing and explicit returns were added.

The extensions of `composes` and `packages` fixtures were also updated from .tsx to .ts
This commit is contained in:
regexowl 2023-07-20 12:27:52 +02:00 committed by Lucas Garfield
parent 9fd260cfea
commit 8fbad0d99b
6 changed files with 85 additions and 33 deletions

View file

@ -17,7 +17,7 @@ import CreateImageWizard from '../../../Components/CreateImageWizard/CreateImage
import ShareImageModal from '../../../Components/ShareImageModal/ShareImageModal';
import { RHEL_8, RHEL_9, PROVISIONING_API } from '../../../constants.js';
import { mockComposesEmpty } from '../../fixtures/composes';
import { customizations, ids } from '../../fixtures/customizations';
import { customizations } from '../../fixtures/customizations';
import { mockPkgResultAlphaContentSources } from '../../fixtures/packages';
import { server } from '../../mocks/server.js';
import {
@ -881,6 +881,7 @@ describe('Click through all steps', () => {
expect(within(revtbody).getAllByRole('row')).toHaveLength(3);
// mock the backend API
const ids = [];
const composeImage = jest
.spyOn(api, 'composeImage')
.mockImplementation((body) => {