Commit graph

10 commits

Author SHA1 Message Date
regexowl
8597929ff3 test: test: Remove act() warnings
This removes `Warning: An update to <component> inside a test was not wrapped inact(...)` warnings.
2024-07-16 16:55:31 +02:00
regexowl
2a48966bba test: Update test files to work with Vitest
This updates the files to be compatible with Vitest. Changes include:
- adding `@testing-library/jest-dom` import to enable custom jest matchers
- renaming `jest.` to `vi.`
- setting flags to false as default where needed
2024-07-16 16:55:31 +02:00
regexowl
da1d76ad94 test: Add edit mode tests
This adds basic edit mode tests for the remaining steps.
2024-06-20 00:05:41 +02:00
regexowl
a23cc9321b test: Update tests after adding SaveAndBuild modal
This updates tests with a `openAndDismissSaveAndBuildModal` function that handles closing the SaveAndBuild modal after clicking on Create blueprint for the first time.
2024-06-06 16:58:59 +02:00
Amir
6f9c4f3864 feat(HMS-3582): add first boot step to wizard 2024-05-02 16:35:26 +02:00
regexowl
df9ec1499d V2Wizard: Fix FSC units on Edit
This updates the logic of parsing bytesize into size/unit pair.

Currently 'GiB' is set as a default which causes problem with smaller partitions on Edit.

A validation for the min_size is in place and the rule is that the size cannot be smaller than 0 of a given unit. If there was a partition with smaller size in KiB it will break the rule when converted to GiB.
2024-05-01 19:47:41 +02:00
lucasgarfield
61b23216f4 V2 Wizard: OpenSCAP edit tests
Edit mode is now fully tested and working for OpenSCAP profiles. A
handler for the PUT request was added and the fixtures were updated to
support this.

`EditImageWizard.tsx`: Previously we dispatched `initializeWizard()`
while waiting for the blueprintDetails to load. This meant that the
state was incorrect (empty) while the blueprintDetails request was
in flight.

`requestMapper.tsx`: Correctly populate state in edit mode if the
blueprint contains a custom file system – previously custom mountpoints
were dropped and automatic mode was selected.

`spyOnRequest()`: Differentiate between request types (e.g. GET, PUT)
for the same endpoint.
2024-04-30 15:13:50 +02:00
regexowl
6494070a40 test: Replace image installer with guest image in happy path tests
This replaces 'image-installer' target with 'guest-image' in happy path tests which allows proper testing of FSC functionality. File system customisations are not applied to bare metal - installer images.
2024-04-29 11:57:30 +02:00
Andrew Dewar
3231b324f0 HMS-3796: Add snapshot date selection to wizard 2024-04-25 14:45:50 +02:00
lucasgarfield
782a8eba7e V2 Wizard: Add custom file system to request customizations (HMS-3690)
The blueprint request now contains a field for the filesystem in its
customizations.
2024-04-16 10:02:19 +02:00