コード例 #1
0
 def test_put_with_lease(self):
     blob = LocalFileBlob(os.path.join(TEST_FOLDER, 'foobar.blob'))
     input = (1, 2, 3)
     blob.delete()
     blob.put(input, lease_period=0.01)
     blob.lease(0.01)
     self.assertEqual(blob.get(), input)
コード例 #2
0
 def test_lease_error(self):
     blob = LocalFileBlob(os.path.join(TEST_FOLDER, 'foobar.blob'))
     blob.delete()
     self.assertEqual(blob.lease(0.01), None)