Exemplo n.º 1
0
 def test_save_creates_space(self):
     space = Space(self.conn, 'not saved')
     self.assertFalse(space.persisted())
     resp = space.save()
     self.assertIsInstance(resp, Space)
     self.assertTrue(space.persisted())
Exemplo n.º 2
0
 def test_space_is_persisted_if_id_present(self):
     space = Space(self.conn, 'saved', id=42)
     self.assertTrue(space.persisted())
Exemplo n.º 3
0
 def test_space_is_not_persisted(self):
     space = Space(self.conn, 'not saved')
     self.assertFalse(space.persisted())
Exemplo n.º 4
0
 def test_save_creates_space(self):
     space = Space(self.conn, 'not saved')
     self.assertFalse(space.persisted())
     resp = space.save()
     self.assertIsInstance(resp, Space)
     self.assertTrue(space.persisted())
Exemplo n.º 5
0
 def test_space_is_persisted_if_id_present(self):
     space = Space(self.conn, 'saved', id=42)
     self.assertTrue(space.persisted())
Exemplo n.º 6
0
 def test_space_is_not_persisted(self):
     space = Space(self.conn, 'not saved')
     self.assertFalse(space.persisted())