Add FTP login script.
This commit is contained in:
parent
9c763cea27
commit
fdba636913
|
@ -30,6 +30,9 @@ sub run {
|
||||||
assert_script_run("useradd -g ftpusers -d /dev/null -s /sbin/nologin ftpuser");
|
assert_script_run("useradd -g ftpusers -d /dev/null -s /sbin/nologin ftpuser");
|
||||||
assert_script_run("mkdir /ftpdata");
|
assert_script_run("mkdir /ftpdata");
|
||||||
assert_script_run("chown -R ftpuser:ftpusers /ftpdata");
|
assert_script_run("chown -R ftpuser:ftpusers /ftpdata");
|
||||||
|
assert_script_run("echo 'This is a test file' > /ftpdata/testfile.txt");
|
||||||
|
assert_script_run("firewall-cmd --add-service=ftp --permanent");
|
||||||
|
assert_script_run("firewall-cmd --reload");
|
||||||
|
|
||||||
# Set up the FTP server.
|
# Set up the FTP server.
|
||||||
enter_cmd("pure-pw useradd tucnak -u ftpuser -g ftpusers -d /ftpdata");
|
enter_cmd("pure-pw useradd tucnak -u ftpuser -g ftpusers -d /ftpdata");
|
||||||
|
|
|
@ -0,0 +1,41 @@
|
||||||
|
use base "installedtest";
|
||||||
|
use strict;
|
||||||
|
use testapi;
|
||||||
|
use utils;
|
||||||
|
|
||||||
|
# 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
|
||||||
|
# - reboot the computer and check that the system still remembers them
|
||||||
|
# and that we can do the FTP again without credentials.
|
||||||
|
|
||||||
|
|
||||||
|
sub run {
|
||||||
|
my $self = shift;
|
||||||
|
assert_and_click("keyring_open_network");
|
||||||
|
assert_and_click("keyring_add_network_folder");
|
||||||
|
assert_and_click("keyring_select_ftp");
|
||||||
|
assert_and_click("kde_button_next");
|
||||||
|
type_very_safely("FTPConnect");
|
||||||
|
send_key("tab");
|
||||||
|
type_very_safely("tucnak");
|
||||||
|
send_key("tab");
|
||||||
|
type_very_safely("127.0.0.1");
|
||||||
|
assert_and_click("keyring_save_connect");
|
||||||
|
type_very_safely("weakpassword");
|
||||||
|
assert_and_click("keyring_remember_password");
|
||||||
|
assert_and_click("kde_button_ok");
|
||||||
|
assert_and_click("keyring_open_location");
|
||||||
|
send_key("ret");
|
||||||
|
assert_screen("keyring_test_file");
|
||||||
|
send_key("alt-f4");
|
||||||
|
}
|
||||||
|
|
||||||
|
sub test_flags {
|
||||||
|
return {fatal => 1, milestone => 1};
|
||||||
|
}
|
||||||
|
|
||||||
|
1;
|
||||||
|
|
||||||
|
# vim: set sw=4 et:
|
Loading…
Reference in New Issue