mirror of
https://bitbucket.org/atlassian/dc-deployments-automation.git
synced 2025-12-14 00:43:06 -06:00
26 lines
740 B
Python
26 lines
740 B
Python
import os
|
|
import urllib.request
|
|
|
|
import testinfra.utils.ansible_runner
|
|
|
|
testinfra_hosts = testinfra.utils.ansible_runner.AnsibleRunner(
|
|
os.environ['MOLECULE_INVENTORY_FILE']).get_hosts('all')
|
|
|
|
|
|
def test_version_downloaded(host):
|
|
verfile = host.file('/media/atl/jira/shared/jira-software.version')
|
|
assert verfile.exists
|
|
|
|
|
|
def test_version_is_latest(host):
|
|
verfile = host.file('/media/atl/jira/shared/jira-software.version')
|
|
assert verfile.exists
|
|
|
|
assert verfile.content.decode("UTF-8").strip() == "7.13.2"
|
|
|
|
def test_latest_is_downloaded(host):
|
|
installer = host.file('/opt/atlassian/tmp/jira-software.7.13.2.bin')
|
|
assert installer.exists
|
|
assert installer.user == 'root'
|
|
assert installer.mode == 0o0755
|