Commit graph

45 commits

Author SHA1 Message Date
Gianluca Zuccarelli
3a83a14720 BlueprintCard: fix name truncation
This might be an issue with the pf6 truncate component. Since we're not
really using the popover, we can just use vanilla js to truncate the
string rather than use the Truncate component. We can match the
behaviour of the component by also splitting on 24 characters.

https://github.com/patternfly/patternfly-react/issues/11964
2025-08-21 13:44:58 +00:00
Sanne Raymaekers
fa0560ac4d playwright: wait until distro and arch have been initialized
On-prem the distro and architecture are set after the wizard has been
opened. This triggers a reload of the image types and makes the tests
very flaky.
2025-08-20 12:32:43 +00:00
Lucas Garfield
04adcc133c Wizard: add AAP step 2025-08-14 11:28:49 +00:00
Gianluca Zuccarelli
11e352440f Wizard: hide some review items for cockpit frontend
Hide some of the steps in the review step that aren't applicable to the
cockpit frontend.
2025-08-14 08:41:48 +00:00
regexowl
eafcd200ae ESLint: Set trailingComma to all and run lint fix 2025-08-05 13:56:59 +00:00
regexowl
e9025e460c src: Run lint autofix 2025-08-05 13:56:59 +00:00
regexowl
2bea0bd50b Wizard: Update kernel argument validation regex
There are special characters missing from the validation regex.
2025-08-05 12:52:39 +00:00
regexowl
fdaf5129c8 playwright: Update required Oscap packages
Follow up to https://github.com/osbuild/image-builder-crc/pull/1659.

This updates test to check required Oscap packages to match updated set.
2025-08-01 08:41:26 +00:00
Anna Vítová
ceec85209c Playwright: OSCAP basic test not altering things added by OSCAP 2025-07-29 15:46:56 +00:00
Gianluca Zuccarelli
661fd29a5e playwright: add timeout for cockpit tests
Playwright at times is making assertions before the osbuild-worker file is loaded.
This is causing some flakiness in the tests, adding a timeout before some of the
assertions should hopefully remove some of the flakiness.
2025-07-25 09:47:56 +00:00
Gianluca Zuccarelli
690b71636a playwright: fix cockpit cloud provider test
The test was a bit flaky, move the worker file check to the end of
the test since it appears that we might be trying to read the file
before it has been created.
2025-07-23 08:58:26 +00:00
Gianluca Zuccarelli
a6eadbffac playwright: add an aws upload test
Create a blueprint configured for AWS and make sure it shows up in
the images table when it is built.
2025-07-23 08:58:26 +00:00
regexowl
25a5f140d8 ESLint: Add rule to sort imports alphabetically
The `import/order` rule isn't enough to sort import within a single import group alphabetically.

This adds `sort-imports` rule that handles the sorting within groups.
2025-07-15 16:52:45 +00:00
regexowl
a0fe3644c3 src: Remove more data-testids
As using `data-testid`s in tests is an anti-pattern, this removes more of them and replaces them with appropriate locators in the tests.
2025-07-15 16:51:29 +00:00
Florian Schüller
ccfdb49db2 CreateImageWizard: Implement user-friendly error messages
Puts the error messages in one place - LabelInput.tsx
2025-07-15 13:47:37 +00:00
regexowl
3f35101f68 Migrate ESLint to v 9.x
This bumps needed dependencies and migrates previously used ESLint configs to the new flat config schema.
2025-07-15 13:39:36 +00:00
Gianluca Zuccarelli
c9d721ea52 playwright: add a test for cockpit cloud config
SSIA
2025-07-15 12:38:52 +00:00
Lucas Garfield
5d6c6dc58b BlueprintCard: Make hand cursor appear on hover
This commit fixes an issue where if both isClickable and isSelectable
are passed to a card in Patternfly 6, the hand cursor no longer appears
on hover and it is not obvious the card is clickable.

Co-Author: Gianluca Zuccarelli <gzuccare@redhat.com>
2025-07-03 06:52:30 +00:00
regexowl
eafb9ea0f3 Playwright: Update login
The login screen was recently changed, this updates the tests to reflect it.
2025-07-01 07:49:10 +00:00
Tom Koscielniak
0319c81b41 playwright: Add check to ensure test is authenticated
In order to fix the flakiness in cockpit plugin tests introduced by the single login, the tests need a check if they are authenticated at the start of their execution and relog in case the session expired.
2025-06-27 12:53:37 +00:00
regexowl
969497e722 Wizard: Parse locale codes to readable options
This parses options in the Languages dropdown to human readable form like so:
'en_US.UTF-8' -> 'English - United States (en_US.UTF-8)'
2025-06-27 11:45:26 +02:00
Katarina Sieklova
064aa172a0 Wizard: add Filesystem customization test 2025-06-24 07:14:56 +00:00
Tom Koscielniak
2a611e9704 playwright: Add handler for new intercom notifications
Adds handler for the new intercom popup notifications that trigger OpenScap window. Also adds noWaitAfter for the click action to fix flakiness.
2025-06-19 14:26:03 +00:00
Tom Koscielniak
b499dfcf93 playwright: Add single login for all tests
Add a single login for all tests in the form of a global setup. This commit also removes the login from all tests and replaces it with navigation to landing page and revamps the popup closing logic from being applied in logging step  into a separate fixture.
2025-06-19 14:26:03 +00:00
regexowl
b59a729656 sharedComponents: Rename "Create blueprint" button
This renames the button to "Create image blueprint" to make the relationship between images and blueprints clearer.
2025-06-18 14:12:47 +00:00
Anna Vítová
cd137fb055 Tets: add Kernel customizations test 2025-06-18 08:52:06 +00:00
Tom Koscielniak
42d7379a6c playwright: Cleanup fails gracefully if no BP is created
If no blueprint was created, the cleanup function fails gracefully without throwing error. Also includes a fix for a missing navigation to the IB landing page.
2025-06-05 14:17:18 +02:00
regexowl
2080425753 src: Update remaining v5 version slugs 2025-05-28 09:08:52 -05:00
regexowl
1fc1f0cb8d src: Run codemods and lint
Run `npx @patternfly/pf-codemods@latest src --v6 --fix` and lint autofix to get the bulk of the changes in.
2025-05-28 09:08:52 -05:00
Dominik Vagner
d0a70dfbbe fix(test): add close pop-ups locator for intercom modal
This locator should automatically close all "openscap faster trigger"
pop-ups in playwright tests.
2025-05-27 11:42:22 +02:00
Katarina Sieklova
0d63c9b4a2 Wizard: Systemd services test (HMS-5975)
Added new cutomization test for the Systemd services step - just simple 3 fields checks.
2025-05-26 12:13:23 +02:00
Katarina Sieklova
774714cb99 Wizard: add Firewall test 2025-05-09 13:17:11 +02:00
Gianluca Zuccarelli
df495748e9 playwright: check admin access for on-prem
Add a check to the playwright tests to ensure that the user sees the
'Access is limited.' error message if the logged in user doesn't have
the required privileges.
2025-05-07 11:03:18 +02:00
Anna Vítová
6209a87aa8 tests/playwright: Add Timezone customization test
Adds a Timezone customization test that creates a BP, edits BP, exports and imports it back and verifies the BP content.
2025-04-30 12:35:27 +02:00
Anna Vítová
71e1842aa4 tests/playwright: Add Locale customization test
Adds a Locale customization test that creates a BP, edits BP, exports and imports it back and verifies the BP content.
2025-04-29 13:47:17 +02:00
Simon Steinbeiss
357dd3a910 playwright: Adjust Package step test to new widget
Since the new SearchInput widget gets decomposed by PatternFly into a
<div> and the actual <input> element we're looking for is nested rather
deeply in this hierarchy, we need to use the locator to allow Playwright
to descend into that input.
2025-04-25 11:06:49 +02:00
Tom Koscielniak
0bddb80e94 tests/playwright: Add Hostname customization test
Adds a Hostname customization test that creates a BP, edits BP, exports and imports it back and verifies the BP content.
This test also servers as a template for other customization tests. Includes a refactor of existing helper functions.
2025-04-15 14:14:40 +02:00
regexowl
72aed71662 Playwright: Add check for admin access popup
The admin access popup is different for passwordless user and a user with a password.

This checks what popup got rendered and based on that acts to get administrative access.
2025-04-03 10:48:45 +02:00
Anna Vítová
a4034e8787 Wizard: add satellite registration, add jwt-decode
The jwt decode dependency helps us to keep track of the token that is
present in the Satellite command. jwt-decode is the most popular
dependency for the job, and very easy to use.
2025-04-03 09:46:41 +02:00
Gianluca Zuccarelli
9d883a8dfc CreateImageWizard: enable OpenSCAP for on-prem
SSIA
2025-03-31 18:02:11 -05:00
Tom Koscielniak
781267f16c tests: Streamline hosted Playwright local setup
Streamline the process of setting up Playwright for local development of hosted service tests using dotenv. Add short guide to README as well.
2025-03-27 11:42:05 +01:00
regexowl
cd5daade6b playwright: Add togglePreview helper function
This adds a helper function that switches into preview.

Heavily inspired by and all credit due to `content-sources-playwright`.
2025-03-21 14:09:16 +01:00
regexowl
3a85341dbf playwright: Add playwright to ESLint and fix errors
This add the `playwright` folder to the lint script and fixes errors.
2025-03-14 14:17:18 +01:00
Sanne Raymaekers
21ec51a69e playwright: adapt tests to hosted
Makes the test's base url, user & password configurable through the
environment. Abstracts differences between hosted and cockpit where
possible to lib, and adds conditionals otherwise.
2025-03-11 13:30:14 +01:00
schutzbot
6ef29afac3 Post release version bump
[skip ci]
2025-03-06 13:12:33 +01:00