def test12_show(self): """Test show method.""" s = io.StringIO() oo = Object() oo.log.addHandler(logging.StreamHandler(s)) oo.show(objdir='fixtures/1.0/good-objects/minimal_one_version_one_file') out = s.getvalue() self.assertIn('[fixtures/1.0/good-objects/minimal_one_version_one_file]', out) self.assertTrue('├── 0=ocfl_object_1.0' in out)
def test11_show(self): """Test show method.""" s = io.StringIO() oo = Object(fhout=s) oo.show(path='fixtures/1.0/objects/of1') out = s.getvalue() if sys.version_info < (3, 0): out = out.encode('utf8') self.assertTrue(out.startswith('[fixtures/1.0/objects/of1]')) self.assertTrue('├── 0=ocfl_object_1.0' in out)