Code Duplication    Length = 9-10 lines in 2 locations

acceptance/test_contextAPI.py 2 locations

@@ 25-34 (lines=10) @@
22
        with open(path,'w') as tempfile:
23
            tempfile.write('0')
24
25
    def test_Relative_paths(self):
26
        self.provenance.discover('testdata')
27
        newfile = 'temp/smoothed.test'
28
        self.touch(newfile)
29
        self.provenance.log(newfile, 'test', 'testdata/eeg/stub.cnt')
30
        img = self.provenance.get(forFile=newfile)
31
32
    def test_Log(self):
33
        self.provenance.discover('testdata')
34
        newfile = 'temp/smoothed.test'
35
        self.touch(newfile)
36
        parent = os.path.abspath('testdata/eeg/stub.cnt')
37
        self.provenance.log(newfile, 'test', parent)
@@ 36-44 (lines=9) @@
33
        self.provenance.discover('testdata')
34
        newfile = 'temp/smoothed.test'
35
        self.touch(newfile)
36
        parent = os.path.abspath('testdata/eeg/stub.cnt')
37
        self.provenance.log(newfile, 'test', parent)
38
        testfpath = os.path.abspath(newfile)
39
        img = self.provenance.get(forFile=testfpath)
40
        self.assertEqual(img.provenance['subject'], 'Jane Doe')
41
        self.assertEqual(img.provenance['size'], os.path.getsize(newfile))
42
43
    def test_Record_with_user(self):
44
        self.provenance.discover('testdata')
45
        newfile = 'temp/recorded.test'
46
        self.touch(newfile)
47
        parent = os.path.abspath('testdata/eeg/stub.cnt')