def test_sub_superclasses_of_existent_class_indirect_recursive(self): service_name = rospy.get_param(\ "rapp_knowrob_wrapper_is_subsuperclass_of_topic") rospy.wait_for_service(service_name) test_service = rospy.ServiceProxy(\ service_name, ontologyIsSubSuperClassOfSrv) req = ontologyIsSubSuperClassOfSrvRequest() req.parent_class = 'SpatialThing' req.child_class = 'MicrowaveOven' req.recursive = True response = test_service(req) self.assertEqual(response.result, True)
def test_sub_superclasses_of_existent_class_indirect_recursive(self): service_name = rospy.get_param(\ "rapp_knowrob_wrapper_is_subsuperclass_of_topic") rospy.wait_for_service(service_name) test_service = rospy.ServiceProxy(\ service_name, ontologyIsSubSuperClassOfSrv) req = ontologyIsSubSuperClassOfSrvRequest() req.parent_class = 'SpatialThing' req.child_class = 'MicrowaveOven' req.recursive = True response = test_service(req) self.assertEqual(response.result, True)
def test_sub_superclasses_of_existent_classes_recursive(self): service_name = rospy.get_param(\ "rapp_knowrob_wrapper_is_subsuperclass_of_topic") rospy.wait_for_service(service_name) test_service = rospy.ServiceProxy(\ service_name, ontologyIsSubSuperClassOfSrv) req = ontologyIsSubSuperClassOfSrvRequest() req.parent_class = 'Aoua' req.child_class = 'Aoua2' req.recursive = True response = test_service(req) self.assertEqual(response.result, False) self.assertEqual(response.success, False) self.assertEqual(response.error, "Class: Aoua does not exist")
def test_sub_superclasses_of_existent_classes_recursive(self): service_name = rospy.get_param(\ "rapp_knowrob_wrapper_is_subsuperclass_of_topic") rospy.wait_for_service(service_name) test_service = rospy.ServiceProxy(\ service_name, ontologyIsSubSuperClassOfSrv) req = ontologyIsSubSuperClassOfSrvRequest() req.parent_class = 'Aoua' req.child_class = 'Aoua2' req.recursive = True response = test_service(req) self.assertEqual(response.result, False) self.assertEqual(response.success, False) self.assertEqual(response.error, "Class: Aoua does not exist")