Example #1
0
 def test_evaluate_read_same(self):
     dir = TempDirectory()
     dir.write('foo', 'content')
     d = TestContainer('parsed', FileBlock('foo', 'content', 'read'))
     d.evaluate_with(Files('td'), globs={'td': dir})
     compare([C(FileResult, passed=True, expected=None, actual=None)],
             [r.evaluated for r in d])
Example #2
0
 def test_evaluate_read_difference(self):
     dir = TempDirectory()
     dir.write('foo', b'actual')
     d = TestContainer('parsed',FileBlock('foo','expected','read'))
     d.evaluate_with(Files('td'),globs={'td':dir})
     compare([C(FileResult,
                passed=False,
                path='foo',
                expected='expected',
                actual='actual')],
             [r.evaluated for r in d])