Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

collection: Use -i instead of -l test scripts #680

Merged
merged 2 commits into from
Mar 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -143,9 +143,10 @@
command = (
'ansible-playbook sap_general_preconfigure-default-settings.yml '
+ par1['command_line_parameter']
+ '-l '
+ '-u root '
+ '-i '
+ _managed_node
+ ' '
+ ', '
+ '-e "'
)
for par2 in par1['role_vars']:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -100,11 +100,15 @@ def print_log(text):
for par1 in __tests[0:3]:
print('\n' + 'Test ' + par1['number'] + ': ' + par1['name'])
# prepare the test:
command = ('ansible-playbook prepare-install-test-'
+ par1['number']
+ '.yml '
+ '-l '
+ __managed_node)
command = (
'ansible-playbook prepare-install-test-'
+ par1['number']
+ '.yml '
+ '-u root '
+ '-i '
+ __managed_node
+ ','
)
args = shlex.split(command)
# _py_rc = os.system(command)
__logfile = __logdir + '/' + __logfile_prefix + __datestr + '-prepare-' + par1['number'] + '.log'
Expand All @@ -116,14 +120,17 @@ def print_log(text):
__filedescriptor.flush()

# run the test:
command = ('ansible-playbook run-install-test-'
+ par1['number']
+ '.yml '
+ par1['command_line_parameter']
+ '-l '
+ __managed_node
+ ' '
+ '-e "')
command = (
'ansible-playbook run-install-test-'
+ par1['number']
+ '.yml '
+ par1['command_line_parameter']
+ '-u root '
+ '-i '
+ __managed_node
+ ', '
+ '-e "'
)
# add all role vars for this test:
for par2 in par1['role_vars']:
command += str(par2)
Expand All @@ -149,9 +156,13 @@ def print_log(text):
print('Test ' + par1['number'] + ' FAILED!!!')

# uninstall SAP HANA:
command = ('ansible-playbook hana-uninstall.yml '
+ '-l '
+ __managed_node)
command = (
'ansible-playbook hana-uninstall.yml '
+ '-u root '
+ '-i '
+ __managed_node
+ ','
)
args = shlex.split(command)
__logfile = __logdir + '/' + __logfile_prefix + __datestr + '-uninstall-' + par1['number'] + '.log'
with open(__logfile, 'wb') as __filedescriptor:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -186,9 +186,10 @@
print('\n' + 'Test ' + par1['number'] + ': ' + par1['name'])
command = ('ansible-playbook sap_hana_preconfigure-default-settings.yml '
+ par1['command_line_parameter']
+ '-l '
+ '-u root '
+ '-i '
+ _managed_node
+ ' '
+ ', '
+ '-e "')
for par2 in par1['role_vars']:
command += str(par2)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,9 +98,10 @@
print('\n' + 'Test ' + par1['number'] + ': ' + par1['name'])
command = ('ansible-playbook sap_netweaver_preconfigure-default-settings.yml '
+ par1['command_line_parameter']
+ '-l '
+ '-u root '
+ '-i '
+ _managed_node
+ ' '
+ ', '
+ '-e "')
for par2 in par1['role_vars']:
command += str(par2)
Expand Down
Loading