예제 #1
0
 def testInvalidCodeNumber(self):
     """Test that an index out of range is handled"""
     with self.assertRaises(LookupException):
         cqi = CyberQInterface("127.0.0.1")
         cqi._lookup("temperature", 4)
예제 #2
0
 def testInvalidCodeNumber(self):
     """Test that an index out of range is handled"""
     with self.assertRaises(LookupException):
         cqi = CyberQInterface("127.0.0.1")
         cqi._lookup("temperature", 4)
예제 #3
0
 def testBadTableName(self):
     """Test that an unknown table produces a known exception"""
     with self.assertRaises(LookupException):
         cqi = CyberQInterface("127.0.0.1")
         cqi._lookup("badtable", 0)
예제 #4
0
 def testBadTableName(self):
     """Test that an unknown table produces a known exception"""
     with self.assertRaises(LookupException):
         cqi = CyberQInterface("127.0.0.1")
         cqi._lookup("badtable", 0)