1
0
mirror of https://pagure.io/fedora-qa/os-autoinst-distri-fedora.git synced 2024-11-14 02:34:21 +00:00
os-autoinst-distri-fedora/tests/freeipa_password_change_postinstall.pm
Adam Williamson b7abdf81a9 always use --nogpgcheck when installing packages
Summary:
Except when running on the pre-upgrade release in the upgrade
tests (where GPG check should always be OK).

Currently we always need to use --nogpgcheck on Rawhide, and we
must also use it on Branched prior to the Bodhi activation
point. At present we don't really have any simple way to know
when the Bodhi activation point has kicked in. We could assume
that it's safe to do GPG checking for 'candidate' (not nightly)
composes, but even that isn't 100% safe and isn't really the
*right* thing to do. So I think for now it's best to just always
use --nogpgcheck , until we come up with a decent way to check
for Bodhi enablement, or releng figures things out so we can
rely on packages being signed in Rawhide and in Branched before
Bodhi enablement.

Test Plan:
Check the tests all still run, make sure I didn't
miss any dnf calls.

Reviewers: jskladan, garretraziel

Reviewed By: garretraziel

Subscribers: tflink

Differential Revision: https://phab.qadevel.cloud.fedoraproject.org/D964
2016-08-10 07:56:13 -07:00

60 lines
2.1 KiB
Perl

use base "installedtest";
use strict;
use testapi;
use freeipa;
sub run {
my $self = shift;
$self->console_login(user=>'root');
# clear browser data so we don't go back to the 'admin' login
assert_script_run 'rm -rf /root/.mozilla';
type_string "startx /usr/bin/firefox\n";
assert_screen "firefox";
start_webui("test1", "batterystaple");
assert_and_click "freeipa_webui_actions";
assert_and_click "freeipa_webui_reset_password_link";
wait_still_screen 3;
type_string "batterystaple";
wait_still_screen 1;
send_key "tab";
send_key "tab";
wait_still_screen 1;
type_string "loremipsum";
wait_still_screen 1;
send_key "tab";
wait_still_screen 1;
type_string "loremipsum";
wait_still_screen 1;
assert_and_click "freeipa_webui_reset_password_button";
wait_still_screen 2;
# log out
assert_and_click "freeipa_webui_user_menu";
assert_and_click "freeipa_webui_logout";
wait_still_screen 3;
# close browser, back to console
send_key "ctrl-q";
# we don't get back to a prompt instantly and keystrokes while X
# is still shutting down are swallowed, so wait_still_screen before
# finishing (and handing off to freeipa_client_postinstall)
wait_still_screen 5;
# check we can kinit with changed password
assert_script_run 'printf "loremipsum" | kinit test1';
# change password via CLI (back to batterystaple, as that's what
# freeipa_client test expects)
assert_script_run 'dnf -y --nogpgcheck install freeipa-admintools';
assert_script_run 'printf "batterystaple\nbatterystaple" | ipa user-mod test1 --password';
# check we can kinit again
assert_script_run 'printf "batterystaple" | kinit test1';
# we just stay here - freeipa_client will pick right up
}
sub test_flags {
# without anything - rollback to 'lastgood' snapshot if failed
# 'fatal' - whole test suite is in danger if this fails
# 'milestone' - after this test succeeds, update 'lastgood'
# 'important' - if this fails, set the overall state to 'fail'
return {};
}
1;