MCPcopy Create free account
hub / github.com/cloudpipe/cloudpickle / test_plus_mode

Method test_plus_mode

tests/cloudpickle_file_test.py:58–65  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

56 os.remove(self.tmpfilepath)
57
58 def test_plus_mode(self):
59 # Write, then seek to 0
60 with open(self.tmpfilepath, "w+") as f:
61 f.write(self.teststring)
62 f.seek(0)
63 new_f = pickle.loads(cloudpickle.dumps(f))
64 self.assertEqual(self.teststring, new_f.read())
65 os.remove(self.tmpfilepath)
66
67 def test_seek(self):
68 # Write, then seek to arbitrary position

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected