Compare commits

..

7 Commits

Author SHA1 Message Date
Lukas Ruzicka 50021146b8 Create test suite for Desktop Keyring
This adds both the Gnome and the KDE tests to test the
Desktop Keyring. After a discussion with the Brno team,
how this could be tested without the need to rely on
external servers to log into, we set up a local FTP server,
we will log into it and remember the credentials and verify
that the credentials will be stored in the keyring correctly.
2024-04-10 15:59:39 +02:00
Adam Williamson 5bd224687f Bump base version in ostree-parse-pungi.py
The flatpaks have been updated to the F40 runtime, so we need to
keep pace here.

Signed-off-by: Adam Williamson <awilliam@redhat.com>
2024-04-09 20:28:13 -07:00
Adam Williamson d74fd9e6b4 Update some GNOME needles too
Signed-off-by: Adam Williamson <awilliam@redhat.com>
2024-04-08 13:21:08 -07:00
Adam Williamson 3ca5816696 Update some more needles for KDE
Signed-off-by: Adam Williamson <awilliam@redhat.com>
2024-04-08 13:18:03 -07:00
Adam Williamson d0912fd217 Fix blivet preserve_home test templates for UEFI switchover
Somehow these two got completely scrambled, testing the wrong
things on the wrong images. Fix them to match the non-blivet
counterparts, which are correct.

Signed-off-by: Adam Williamson <awilliam@redhat.com>
2024-04-08 12:19:51 -07:00
Deborah Brouwer 4eec75bec3 Get dns server address if host isn’t using systemd-resolved
The worker containers aren’t using systemd-resolved so
get_host_dns() can’t find the dns server causing tests that need
it to fail. Add an alternative place to look for the dns server address
that doesn’t rely on systemd-resolved.

Signed-off-by: Deborah Brouwer <deborah.brouwer@collabora.com>
2024-04-05 21:10:11 +00:00
Adam Williamson c3baa66465 Bump retry count on some flaky tests
The silverblue tests are flaky because of
https://github.com/fedora-silverblue/issue-tracker/issues/548 .
The desktop_upgrade_encrypted test is flaky on Rawhide (so, when
booting from F40 initially) since we switched to UEFI, not sure
if it's because of UEFI somehow or just a timing coincidence.
Am going to look into it, but for now this should save lots of
manual restarting.

Signed-off-by: Adam Williamson <awilliam@redhat.com>
2024-04-05 08:01:16 -07:00
86 changed files with 655 additions and 30 deletions

View File

@ -62,6 +62,17 @@ sub get_host_dns {
# FIXME this is gonna break when we have IPv6 DNS servers on the
# worker hosts
my @forwards = split(' ', $result);
# Alternatively, for hosts that aren't running systemd, read /etc/resolv.conf
if (!@forwards && open(my $fh, '<', "/etc/resolv.conf")) {
while (<$fh>) {
next if /:/; # ignore ipv6 addresses
if ($_ =~ m/^nameserver +(.+)/) {
push @forwards, $1;
}
}
close($fh);
}
return @forwards;
}

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 271,
"ypos": 113,
"width": 142,
"height": 24,
"type": "match"
}
],
"properties": [],
"tags": [
"apps_run_seahorse"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 624 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 746,
"ypos": 41,
"width": 126,
"height": 21,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_add_network_folder"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 95 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 599,
"ypos": 201,
"width": 66,
"height": 17,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_button_connect"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 134 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 607,
"ypos": 734,
"width": 66,
"height": 21,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_button_connect"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 61 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 60,
"ypos": 331,
"width": 131,
"height": 19,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_ftp_localhost"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 42 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 253,
"ypos": 163,
"width": 87,
"height": 67,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_test_file"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 47 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 521,
"ypos": 304,
"width": 195,
"height": 47,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_keys_values"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 56 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 217,
"ypos": 736,
"width": 82,
"height": 18,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_location_line"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 29 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 39,
"ypos": 307,
"width": 40,
"height": 20,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_maps_unfold"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 63 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"ypos": 106,
"height": 61,
"type": "match",
"width": 71,
"xpos": 572
}
],
"properties": [],
"tags": [
"keyring_open_location"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 636 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 605,
"ypos": 106,
"width": 71,
"height": 61,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_open_location"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 92 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 6,
"ypos": 188,
"width": 82,
"height": 21,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_open_network"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 79 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 40,
"ypos": 498,
"width": 112,
"height": 20,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_other_location"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 67 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 43,
"ypos": 258,
"width": 69,
"height": 18,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_passwords_unfold"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 54 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 428,
"ypos": 565,
"width": 125,
"height": 17,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_remember_forever"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 134 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 404,
"ypos": 468,
"width": 132,
"height": 15,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_remember_password"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 128 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 689,
"ypos": 436,
"width": 21,
"height": 14,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_reveal_password"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 275 KiB

View File

@ -0,0 +1,16 @@
{
"area": [
{
"xpos": 668,
"ypos": 578,
"width": 100,
"height": 17,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_save_connect",
"keyring_save_next"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 93 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 384,
"ypos": 122,
"width": 130,
"height": 19,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_seahorse_details"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 648,
"ypos": 424,
"width": 65,
"height": 79,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_seahorse_details_shown"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 35,
"ypos": 121,
"width": 38,
"height": 19,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_seahorse_login"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 44 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 33,
"ypos": 121,
"width": 40,
"height": 21,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_seahorse_login"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 52 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 440,
"ypos": 262,
"width": 111,
"height": 22,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_seahorse_password_shown"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 104 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 615,
"ypos": 260,
"width": 27,
"height": 26,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_seahorse_show_password"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 103 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 189,
"ypos": 261,
"width": 27,
"height": 15,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_select_ftp"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 194 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 508,
"ypos": 356,
"width": 76,
"height": 23,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_select_registered"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 446,
"ypos": 236,
"width": 105,
"height": 22,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_show_values"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 93 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 286,
"ypos": 117,
"width": 77,
"height": 50,
"type": "match"
}
],
"properties": [],
"tags": [
"keyring_test_file"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 59 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"width": 149,
"xpos": 442,
"ypos": 460,
"type": "match",
"height": 111
}
],
"properties": [],
"tags": [
"loupe_image_rotated_left"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 371 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 347,
"width": 102,
"type": "match",
"height": 318,
"ypos": 355
}
],
"properties": [],
"tags": [
"maps_route_bike_shown"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 483 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"ypos": 354,
"height": 318,
"type": "match",
"width": 102,
"xpos": 347
}
],
"properties": [],
"tags": [
"maps_route_bike_shown"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 459 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"width": 215,
"xpos": 404,
"ypos": 532,
"type": "match",
"height": 33
}
],
"properties": [],
"tags": [
"tour_search"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 118 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"ypos": 228,
"height": 157,
"type": "match",
"xpos": 451,
"width": 160
}
],
"properties": [],
"tags": [
"getting_started"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 340 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 459,
"ypos": 96,
"width": 104,
"height": 23,
"type": "match"
}
],
"properties": [],
"tags": [
"kwalletmanager_runs"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 647 KiB

View File

@ -0,0 +1,16 @@
{
"area": [
{
"xpos": 880,
"width": 17,
"ypos": 728,
"type": "match",
"height": 18
}
],
"properties": [],
"tags": [
"DESKTOP-kde",
"desktop_expand_systray"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

View File

@ -0,0 +1,16 @@
{
"area": [
{
"xpos": 871,
"width": 17,
"type": "match",
"height": 18,
"ypos": 728
}
],
"properties": [],
"tags": [
"DESKTOP-kde",
"desktop_expand_systray"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 MiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"ypos": 730,
"height": 18,
"type": "match",
"xpos": 763,
"width": 18
}
],
"properties": [],
"tags": [
"desktop_update_notification_systray"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 MiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 707,
"ypos": 577,
"width": 46,
"height": 16,
"type": "match"
}
],
"properties": [],
"tags": [
"kde_button_next"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 90 KiB

View File

@ -0,0 +1,15 @@
{
"area": [
{
"xpos": 563,
"ypos": 502,
"width": 42,
"height": 16,
"type": "match"
}
],
"properties": [],
"tags": [
"kde_button_ok"
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 132 KiB

View File

@ -5,7 +5,7 @@ import sys
# the "current" base platform version, i.e. the one that the GNOME
# app builds currently tagged "stable" need
BASEVER = "39"
BASEVER = "40"
# a regex to find where we replace that
BASEPATT = re.compile(r"(runtime/org.fedoraproject.Platform/.*?/f)(\d+)")

View File

@ -130,7 +130,7 @@
"HDDSIZEGB": "15",
"NUMDISKS": "2",
"PACKAGE_SET": "default",
"RETRY": "1",
"RETRY": "2",
"SUBVARIANT": "Silverblue"
},
"version": "*"

View File

@ -311,6 +311,7 @@
"DESKTOP": "gnome",
"HDDSIZEGB": "20",
"PACKAGE_SET": "default",
"RETRY": "2",
"TEST_TARGET": "ISO"
},
"version": "*"
@ -1469,12 +1470,11 @@
},
"install_blivet_btrfs_preserve_home_bios": {
"profiles": {
"fedora-Server-dvd-iso-ppc64le-*-ppc64le": 40,
"fedora-Server-dvd-iso-x86_64-*-64bit": 40
"fedora-Server-dvd-iso-x86_64-*-bios": 41
},
"settings": {
"PARTITIONING": "custom_blivet_btrfs_preserve_home",
"HDD_1": "disk_f%CURRREL%_desktop_5_%ARCH%.qcow2",
"HDD_1": "disk_f%CURRREL%_minimal-bios_4_%ARCH%.qcow2",
"POSTINSTALL": "btrfs_preserve_home_check_content",
"ROOT_PASSWORD": "weakpassword"
}
@ -1482,11 +1482,11 @@
"install_blivet_btrfs_preserve_home": {
"profiles": {
"fedora-Server-dvd-iso-aarch64-*-aarch64": 40,
"fedora-Server-dvd-iso-x86_64-*-64bit": 41
"fedora-Server-dvd-iso-x86_64-*-64bit": 40
},
"settings": {
"PARTITIONING": "custom_blivet_btrfs_preserve_home",
"HDD_1": "disk_f%CURRREL%_minimal_4_%ARCH%.qcow2",
"HDD_1": "disk_f%CURRREL%_desktop_5_%ARCH%.qcow2",
"POSTINSTALL": "btrfs_preserve_home_check_content",
"ROOT_PASSWORD": "weakpassword"
}
@ -3080,6 +3080,7 @@
"DESKTOP": "gnome",
"ENCRYPT_PASSWORD": "weakpassword",
"HDD_1": "disk_f%UP1REL%_desktopencrypt_2_%ARCH%.qcow2",
"RETRY": "2",
"ROOT_PASSWORD": "weakpassword",
"TEST_TARGET": "COMPOSE",
"UPGRADE": "1",

View File

@ -16,11 +16,11 @@ sub run {
my $desktop = get_var("DESKTOP");
# Switch to console
$self->root_console(tty => 3);
# We install the necessary packages.
assert_script_run("dnf -y install pure-ftpd");
if ($desktop eq "gnome") {
assert_script_run("dnf -y install seahorse");
assert_script_run("dnf -y install seahorse");
}
# Download the configuration file for FTP and unpack it.
@ -47,7 +47,7 @@ sub run {
sleep(2);
# Set its password, wait between attempts so that the system has time
# to react to the input.
type_string("weakpassword\n"); # To pass the password entry.
type_string("weakpassword\n"); # To pass the password entry.
sleep(2);
type_string("weakpassword\n");
sleep(2);

View File

@ -3,7 +3,7 @@ use strict;
use testapi;
use utils;
# This script will
# This script will
# - use the file application to log onto the localhost's
# ftp server while we will ask the system to remember the login credentials.
# - check that the credentials have been stored in the system
@ -17,7 +17,7 @@ sub run {
if ($desktop eq "kde") {
# The Dolphin application is already started, so we begin
# with clicking on Network to open the network folders.
# We want to add a new connection and go through the
# We want to add a new connection and go through the
# password addition process.
assert_and_click("keyring_open_network");
assert_and_click("keyring_add_network_folder");
@ -25,7 +25,7 @@ sub run {
assert_and_click("kde_button_next");
# We will set up the connection.
type_very_safely("FTPConnect");
send_key("tab");
send_key("tab");
type_very_safely("tucnak");
send_key("tab");
type_very_safely("127.0.0.1");
@ -42,7 +42,7 @@ sub run {
# has been created to access it. Click on that icon.
assert_and_click("keyring_open_location");
# While double click would sometimes fail here, we
# want to confirm opening the icon using the
# want to confirm opening the icon using the
# Enter key.
send_key("ret");
# Check that we have opened the location and that
@ -54,7 +54,7 @@ sub run {
else {
# The Nautilus application is already started, so we begin
# with clicking on Other locations.
# We want to add a new connection and go through the
# We want to add a new connection and go through the
# password addition process.
assert_and_click("keyring_other_location");
assert_and_click("keyring_location_line");
@ -62,7 +62,7 @@ sub run {
assert_and_click("keyring_button_connect");
# We will set up the connection.
assert_and_click("keyring_select_registered");
send_key("tab");
send_key("tab");
type_very_safely("tucnak");
send_key("tab");
type_very_safely("weakpassword");
@ -76,7 +76,7 @@ sub run {
assert_screen("keyring_test_file");
# Close the application.
send_key("alt-f4");
}
}

View File

@ -16,7 +16,7 @@ sub run {
menu_launch_type("kwalletmanager");
assert_screen("kwalletmanager_runs");
send_key("super-pgup");
# Navigate to the stored entry and check that
# the credentials are stored there.
assert_and_dclick("keyring_passwords_unfold");
@ -25,9 +25,23 @@ sub run {
assert_and_click("keyring_show_values");
assert_screen("keyring_keys_values");
}
else {
# Start the Seahorse application and maximize it.
menu_launch_type("seahorse");
assert_screen("apps_run_seahorse");
send_key("super-up");
# Navigate to the stored entry and check
# that the credentials are stored there.
assert_and_click("keyring_seahorse_login");
assert_and_dclick("keyring_seahorse_details");
assert_screen("keyring_seahorse_details_shown");
assert_and_click("keyring_seahorse_show_password");
assert_screen("keyring_seahorse_password_shown");
}
# Reboot the machine.
$self->root_console( tty => 3 );
$self->root_console(tty => 3);
enter_cmd("reboot");
}

View File

@ -12,12 +12,6 @@ sub run {
my $self = shift;
my $pw = get_var("USER_PASSWORD") // "weakpassword";
my $desktop = get_var("DESKTOP");
my $app = "files";
my $key = "up";
if ($desktop eq "kde") {
$app = "dolphin";
$key = "pgup";
}
# Check that the machine has been rebooted
# and log in.
boot_to_login_screen();
@ -25,18 +19,35 @@ sub run {
type_very_safely("$pw\n");
wait_still_screen(5);
# Start the file exploring application
menu_launch_type($app);
send_key("super-$key");
if ($desktop eq "kde") {
# Start the file exploring application
menu_launch_type("dolphin");
send_key("super-pgup");
if ($desktop eq "kde") {
# Open the network location and check
# Open the network location and check
# that the FTP content is accessible.
assert_and_click("keyring_open_network");
assert_and_click("keyring_open_location");
send_key("ret");
assert_screen("keyring_test_file");
}
else {
# Start the file exploring application
send_key("esc");
menu_launch_type("nautilus");
send_key("super-up");
# Open the network location and check
# that the FTP content is accessible.
assert_and_click("keyring_other_location");
assert_and_click("keyring_location_line");
type_very_safely("ftp://127.0.0.1");
assert_and_click("keyring_button_connect");
# Check that we have opened the location and that
# we can see the FTP content.
assert_screen("keyring_test_file");
}
}
sub test_flags {