示例#1
0
 def test_app_manager_invalid_query_cannot_validate(self):
     app_mgr = ApplicationQueryManager(self.fw_query)
     self.assertFalse(
         app_mgr.is_query_valid(FakeQueryInterface.TEST_QUERY_DATA_INVALID))
     self.assertFalse(
         app_mgr.is_query_valid(
             FakeQueryInterface.TEST_QUERY_DATA_ALMOST_VALID1))
     self.assertFalse(
         app_mgr.is_query_valid(
             FakeQueryInterface.TEST_QUERY_DATA_ALMOST_VALID2))
示例#2
0
 def test_app_mgr_rejects_invalid_inventory_query(self):
     app_mgr = ApplicationQueryManager(self.fw_query)
     result = app_mgr.is_query_valid(66)
     self.assertFalse(result)
示例#3
0
 def test_app_mgr_accepts_valid_inventory_query(self):
     app_mgr = ApplicationQueryManager(self.fw_query)
     result = app_mgr.is_query_valid(55)
     self.assertTrue(result)