Skip to content
Snippets Groups Projects
Commit f0780d29 authored by nimrod's avatar nimrod
Browse files

- Pass test on older versions of Git.

parent 214fbe80
Branches
No related tags found
No related merge requests found
......@@ -6,13 +6,17 @@ testinfra_hosts = AnsibleRunner('.molecule/ansible_inventory').get_hosts('all')
def test_gitreceive(Command, Sudo):
with Sudo():
Command('rm -rf /home/git/test /var/tmp/gitreceive')
push = Command('git -C /root/gitreceive-test push test master')
push = Command(
'git --git-dir /root/gitreceive-test/.git push test master')
assert push.rc == 0
for message in ['----> Unpacking ...', '----> Fetching submodules ...',
for message in [
'----> Unpacking ...', '----> Fetching submodules ...',
'----> Running receiver ...', 'Dummy receiver script',
'----> Cleanup ...', '----> OK.']:
'----> Cleanup ...', '----> OK.'
]:
assert message in push.stderr
with Sudo():
second_push = Command('git -C /root/gitreceive-test push test master')
second_push = Command(
'git --git-dir /root/gitreceive-test/.git push test master')
assert second_push.rc == 0
assert 'Everything up-to-date' in second_push.stderr
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment