⚲
Project
General
Profile
Sign in
Home
Projects
Help
Search
:
qe-yam
All Projects
QA (public)
»
openQA Project (public)
»
openQA Tests (public)
»
qe-yam
Overview
Activity
Roadmap
Issues
Gantt
Calendar
Documents
Wiki
Download (1.24 KB)
action #130003
» encrypt_fs.spec.ts
Simple test for setting encryptiion password -
rainerkoenig
, 2023-06-01 13:52
import
{
test
,
expect
}
from
'
@playwright/test
'
;
import
{
mainPagePath
}
from
"
../lib/installer
"
;
test
.
describe
(
'
The user section
'
,
()
=>
{
test
.
beforeEach
(
async
({
page
})
=>
{
await
page
.
goto
(
mainPagePath
());
});
test
(
'
can set the encryption password
'
,
async
({
page
})
=>
{
// See https://playwright.dev/docs/api/class-locator
// initial expectation
await
expect
(
page
.
getByText
(
"
Install using device
"
)).
toBeVisible
();
// click the "Storage" header
await
page
.
locator
(
"
a[href='#/storage']
"
).
click
();
// click on the encryption input widget
await
page
.
locator
(
"
input[id='encryption']
"
).
click
();
// We now should see the encryption settings popup
await
expect
(
page
.
getByText
(
"
Encryption settings
"
)).
toBeVisible
();
// fill a new password
await
page
.
locator
(
'
#password
'
).
fill
(
'
agama
'
);
await
page
.
locator
(
'
#passwordConfirmation
'
).
fill
(
'
agama
'
);
await
page
.
locator
(
'
button[type="submit"]
'
).
click
();
// wait until the popup is closed
await
expect
(
page
.
locator
(
'
[role="dialog"]
'
)).
not
.
toBeVisible
();
// check if encryption is checked
await
expect
(
page
.
getByLabel
(
'
Encryption settings
'
)).
toBeVisible
();
// go back to the main page
await
page
.
getByText
(
'
Back
'
).
click
();
});
})
« Previous
1
2
Next »
(2-2/2)
Loading...