Example #1
0
 def test_response(self):
     e = VdsmException()
     self.assertEqual(e.response(),
                      {"status": {
                          "code": 0,
                          "message": "Vdsm Exception"
                      }})
Example #2
0
 def ping(self):
     raise VdsmException("Kaboom!!!")
Example #3
0
 def test_response(self):
     e = VdsmException()
     self.assertEqual(e.response(), {"status": e.info()})
Example #4
0
 def test_info(self):
     e = VdsmException()
     self.assertEqual(e.info(), {"code": 0, "message": str(e)})
Example #5
0
 def test_str(self):
     e = VdsmException()
     self.assertEqual(str(e), e.message)