def test_read_and_write_are_opposites(self): covdata1 = CoverageData() covdata1.add_arcs(ARCS_3) stringio = StringIO() covdata1.write_fileobj(stringio) stringio.seek(0) covdata2 = CoverageData() covdata2.read_fileobj(stringio) self.assert_arcs3_data(covdata2)