1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Using the _get_test and _get_stage methods.

This commit is contained in:
Yves Dorfsman 2013-02-23 10:20:38 -07:00 committed by Michael DeHaan
parent 943829c9b7
commit cff8cdd428

View file

@ -291,9 +291,10 @@ class TestRunner(unittest.TestCase):
assert result['changed'] == False
def test_lineinfile(self):
samplefn = 'rocannon.txt'
sample = os.path.join('test', 'artifact' + samplefn)
shutil.copy( os.path.join('test', samplefn), sample)
sampleroot = 'rocannon'
sample_origin = self._get_test_file(sampleroot + '.txt')
sample = self._get_stage_file(sampleroot + '.out' + '.txt')
shutil.copy( sample_origin, sample)
# The order of the test cases is important
# defaults to insertafter at the end of the file