Skip to content

Commit

Permalink
Import WE registration codes during installation
Browse files Browse the repository at this point in the history
Import WE registration codes during installation
  • Loading branch information
openQA web UI committed Sep 1, 2022
1 parent 07de828 commit 0114b30
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 2 deletions.
19 changes: 19 additions & 0 deletions data/autoyast_sle15/autoyast_home_encrypted.xml
Original file line number Diff line number Diff line change
Expand Up @@ -115,4 +115,23 @@
<pattern>gnome_x11</pattern>
</patterns>
</software>
<scripts>
<post-scripts config:type="list">
<script>
<filename>post.sh</filename>
<interpreter>shell</interpreter>
<source>
<![CDATA[
#!/bin/sh
# zypper process is locked by some ruby process, modify the repo file
cd /etc/zypp/repos.d;
sed -i 's/enabled=1/enabled=0/' $(ls|grep -i nvidia);
zypper lr;
exit 0;
]]>
</source>
</script>
</post-scripts>
</scripts>
</profile>
2 changes: 2 additions & 0 deletions tests/autoyast/clone.pm
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ use utils qw(zypper_call);
sub run {
my $self = shift;
assert_script_run 'rm -f /root/autoinst.xml';
assert_script_run 'cd /etc/zypp/repos.d';
assert_script_run "sed -i 's/enabled=1/enabled=0/' \$(ls|grep -i nvidia)";
zypper_call('in autoyast2', 300);
my $module_name = y2_module_consoletest::yast2_console_exec(yast2_module => 'clone_system', yast2_opts => '--ncurses');
if (check_screen 'autoyast2-install-accept', 10) {
Expand Down
8 changes: 6 additions & 2 deletions tests/autoyast/installation.pm
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ sub run {

test_ayp_url;
my $test_data = get_test_suite_data();
my @needles = qw(bios-boot nonexisting-package reboot-after-installation linuxrc-install-fail scc-invalid-url warning-pop-up autoyast-boot package-notification nvidia-validation-failed import-untrusted-gpg-key);
my @needles = qw(bios-boot nonexisting-package reboot-after-installation linuxrc-install-fail scc-invalid-url warning-pop-up autoyast-boot package-notification nvidia-validation-failed import-untrusted-gpg-key registration-codes);

my $expected_licenses = get_var('AUTOYAST_LICENSE');
my @expected_warnings;
Expand Down Expand Up @@ -289,9 +289,10 @@ sub run {
}
elsif (match_has_tag('nvidia-validation-failed')) {
# nvidia repositories are unstable and really not needed for anything
record_info("nVidia", "nVidia repository is broken");
record_info("NVIDIA", "NVIDIA repository is broken");
send_key 'alt-y';
wait_still_screen { send_key 'alt-o' };
$num_errors++;
}
elsif (match_has_tag('package-notification')) {
send_key 'alt-o';
Expand All @@ -303,6 +304,9 @@ sub run {
elsif (match_has_tag 'expired-gpg-key') {
send_key 'alt-y';
}
elsif (match_has_tag 'registration-codes') {
send_key 'alt-n';
}
}

if (get_var("USRSCR_DIALOG")) {
Expand Down

0 comments on commit 0114b30

Please sign in to comment.