Wizard: Update kernel argument validation regex
There are special characters missing from the validation regex.
This commit is contained in:
parent
894d2a4d76
commit
2bea0bd50b
3 changed files with 4 additions and 4 deletions
|
|
@ -47,7 +47,7 @@ test('Create a blueprint with Kernel customization', async ({
|
|||
await frame.getByRole('button', { name: 'Add kernel argument' }).click();
|
||||
await frame
|
||||
.getByPlaceholder('Add kernel argument')
|
||||
.fill('invalid/argument');
|
||||
.fill('invalid$argument');
|
||||
await frame.getByRole('button', { name: 'Add kernel argument' }).click();
|
||||
await expect(
|
||||
frame.getByText(
|
||||
|
|
|
|||
|
|
@ -122,7 +122,7 @@ export const isKernelNameValid = (kernelName: string) => {
|
|||
};
|
||||
|
||||
export const isKernelArgumentValid = (arg: string) => {
|
||||
return /^[a-zA-Z0-9=-_,."']*$/.test(arg);
|
||||
return /^[a-zA-Z0-9=\-_,."'/:#+]*$/.test(arg);
|
||||
};
|
||||
|
||||
export const isPortValid = (port: string) => {
|
||||
|
|
|
|||
|
|
@ -262,7 +262,7 @@ keyboard = "invalid-keyboard"
|
|||
|
||||
[customizations.kernel]
|
||||
name = "--invalid-kernel-name--"
|
||||
append = "invalid-kernel-argument"
|
||||
append = "invalid$kernel$argument"
|
||||
|
||||
[customizations.firewall]
|
||||
ports = ["invalid-port"]
|
||||
|
|
@ -640,7 +640,7 @@ describe('Import modal', () => {
|
|||
);
|
||||
await waitFor(() =>
|
||||
user.click(
|
||||
screen.getByRole('button', { name: /close invalid-kernel-argument/i })
|
||||
screen.getByRole('button', { name: /close invalid\$kernel\$argument/i })
|
||||
)
|
||||
);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue