Class TestSupportedRelationshipSearch
java.lang.Object
org.odpi.openmetadata.conformance.beans.OpenMetadataTestCase
org.odpi.openmetadata.conformance.tests.repository.RepositoryConformanceTestCase
org.odpi.openmetadata.conformance.tests.repository.instances.TestSupportedRelationshipSearch
Test that all defined relationships can be retrieved by property searches.
This testcase covers relationship searches using basic and advanced search criteria/values.
The difference is:
basic = only literal values or repo helper regexes can be used for values of string match properties or as searchCriteria
advanced = arbitrary regexes can be used for values of string match properties or as searchCriteria
-
Nested Class Summary
Nested classes/interfaces inherited from class org.odpi.openmetadata.conformance.beans.OpenMetadataTestCase
OpenMetadataTestCase.TestPhase
-
Field Summary
Fields inherited from class org.odpi.openmetadata.conformance.tests.repository.RepositoryConformanceTestCase
cohortRepositoryConnector, repositoryConformanceWorkPad
Fields inherited from class org.odpi.openmetadata.conformance.beans.OpenMetadataTestCase
defaultProfileId, defaultRequirementId, discoveredProperties, exceptionBean, notSupportedAssertions, successfulAssertions, successMessage, testCaseDescriptionURL, testCaseId, testCaseName, unsuccessfulAssertions
-
Constructor Summary
ConstructorDescriptionTestSupportedRelationshipSearch
(RepositoryConformanceWorkPad workPad, Map<String, EntityDef> entityDefs, RelationshipDef relationshipDef) Typical constructor sets up superclass and discovered information needed for tests -
Method Summary
Modifier and TypeMethodDescriptionprotected List<TypeDefAttribute>
getAllPropertiesForTypedef
(String userId, TypeDef typeDef) Return type def attributes for the properties defined in the TypeDef and all of its supertypesliteraliseMatchProperties
(String userId, TypeDef typeDef, InstanceProperties matchProperties) literaliseStringProperty
(String value) protected void
run()
Default run method - throws Exception because this is a multi-phase testcaseprotected void
Method implemented by the actual test case.Methods inherited from class org.odpi.openmetadata.conformance.tests.repository.RepositoryConformanceTestCase
addEntityProxyToRepository, addEntityToRepository, buildExceptionMessage, generatePropertiesForInstance, getAllPropertiesForInstance, getAllUniquePropertiesForInstance, getEntityDef, getMaxSearchResults, getMetadataCollection, getMinPropertiesForInstance, getPropertiesForInstance, getPropertiesForTypeDef, getRepositoryConnector, incrementSuccessfulCount, incrementUnsuccessfulCount, logTestEnd, logTestStart, updateTestIdByType
Methods inherited from class org.odpi.openmetadata.conformance.beans.OpenMetadataTestCase
addDiscoveredProperty, addNotSupportedAssertion, assertCondition, assertCondition, assertObjectsAreEqual, cleanTest, cleanup, endAsynchronousTest, executeTest, executeTest, getResult, getSummary, getTestCaseDescriptionURL, getTestCaseId, getTestCaseName, isTestPassed, isTestRan, setSuccessMessage, startAsynchronousTest, toString, updateTestId, verifyCondition, verifyCondition, verifyObjectsAreEqual
-
Constructor Details
-
TestSupportedRelationshipSearch
public TestSupportedRelationshipSearch(RepositoryConformanceWorkPad workPad, Map<String, EntityDef> entityDefs, RelationshipDef relationshipDef) Typical constructor sets up superclass and discovered information needed for tests- Parameters:
workPad
- place for parameters and resultsentityDefs
- the entity types supported by the repository under testrelationshipDef
- type of valid relationships
-
-
Method Details
-
run
Default run method - throws Exception because this is a multi-phase testcase- Specified by:
run
in classOpenMetadataTestCase
- Throws:
Exception
- something went wrong with the test.
-
run
Method implemented by the actual test case. This overloads the default implementation in OpenMetadatatestCase- Overrides:
run
in classOpenMetadataTestCase
- Parameters:
phase
- test phase- Throws:
Exception
- something went wrong with the test.
-
getAllPropertiesForTypedef
Return type def attributes for the properties defined in the TypeDef and all of its supertypes- Parameters:
userId
- calling usertypeDef
- the definition of the type- Returns:
- properties for an instance of this type
-
literaliseMatchProperties
public InstanceProperties literaliseMatchProperties(String userId, TypeDef typeDef, InstanceProperties matchProperties) -
literaliseStringProperty
-
literaliseStringPropertyExact
-
literaliseStringPropertyStartsWith
-
literaliseStringPropertyEndsWith
-
literaliseStringPropertyContains
-