[midPoint] Can't start test for notification-impl module
Pavol Mederly
mederly at evolveum.com
Tue Aug 4 18:26:38 CEST 2015
Hello Alexey,
when using Intellij IDEA, I recommend the -XX:MaxPermSize=256m in VM
options. But your problem is related to the fact that many tests require
the presence of dummy-connector and dummy-resource JAR bundles on
classpath. While eclipse can do this without any problems, in Intellij
IDEA I haven't yet found a way how to do that.
So I'm using the following workaround:
I created c:\tmp directory and put these files
(dummy-connector-3.2-SNAPSHOT.jar and dummy-resource-3.2-SNAPSHOT.jar)
into it.
The files can be fetched from your local maven repository, if you use
mvn clean install to build midpoint.
However, beware: if you need to run tests from maven, these files have
to be removed; because when using maven, they are present on the
classpath. If they would be in c:\tmp, midPoint would complain about
multiple occurrences of them ;)
Pavol
>
> Hi.
>
> I need to test new functionality in notifications. But I can’t start
> current tests.
>
> I use IntelliJ Idea. I’ve configured run configuration (see
> screenshot) but test does’t work.
>
> In logs I see an error
>
> [TestNG] Running:
>
> D:\.cache\idea14\system\temp-testng-customsuite.xml
>
> Loading midPoint configuration from file
> target\midpoint-home\test-config.xml
>
> Import of src\test\resources\common\resource-dummy.xml has failed:
> FATAL_ERROR: Repository reference
> {http://midpoint.evolveum.com/xml/ns/public/common/common-3}connectorRef
> cannot be resolved: filter matches no object
>
> *op*
> com.evolveum.midpoint.model.api.ModelService.importObjectsFromStream,
> st: FATAL_ERROR, msg: Repository reference
> {http://midpoint.evolveum.com/xml/ns/public/common/common-3}connectorRef
> cannot be resolved: filter matches no object
>
> [p]options=com.evolveum.midpoint.xml.ns._public.common.api_types_3.ImportOptionsType at 27957ac[overwrite=false,keepOid=<null>,stopAfterErrors=<null>,summarizeSucceses=true,summarizeErrors=true,referentialIntegrity=<null>,validateStaticSchema=false,validateDynamicSchema=false,encryptProtectedValues=true,fetchResourceSchema=false,keepMetadata=<null>]
>
> *op* com.evolveum.midpoint.common.operation.import.object, st:
> FATAL_ERROR, msg: Repository reference
> {http://midpoint.evolveum.com/xml/ns/public/common/common-3}connectorRef
> cannot be resolved: filter matches no object
>
> [c]startLineNumber=18
>
> [c]progress=1
>
> [c]object=resource:10000000-0000-0000-0000-000000000004(Dummy Resource)
>
> [c]endLineNumber=316
>
> *op*
> com.evolveum.midpoint.common.validator.Validator.objectBasicsCheck,
> st: SUCCESS, msg: null
>
> *op*
> com.evolveum.midpoint.common.validator.Validator.resourceNamespaceCheck,
> st: SUCCESS, msg: null
>
> *op*
> com.evolveum.midpoint.model.impl.importer.ObjectImporter.resolveReference,
> st: FATAL_ERROR, msg: Repository reference
> {http://midpoint.evolveum.com/xml/ns/public/common/common-3}connectorRef
> cannot be resolved: filter matches no object
>
> [c]item={...common/common-3}connectorRef
>
> *op*
> com.evolveum.midpoint.repo.api.RepositoryService.searchObjects, st:
> SUCCESS, msg: null
>
> [p]query=Q{AND(EQUAL(connectorType,PPV(String:com.evolveum.icf.dummy.connector.DummyConnector),EQUAL(connectorVersion,PPV(String:2.0)),null
> paging
>
> [p]type=com.evolveum.midpoint.xml.ns._public.common.common_3.ConnectorType
>
> java.lang.AssertionError: Import of
> src\test\resources\common\resource-dummy.xml has failed: FATAL_ERROR:
> Repository reference
> {http://midpoint.evolveum.com/xml/ns/public/common/common-3}connectorRef
> cannot be resolved: filter matches no object
>
> at
> com.evolveum.midpoint.test.util.TestUtil.assertSuccess(TestUtil.java:215)
>
> at
> com.evolveum.midpoint.test.util.TestUtil.assertSuccess(TestUtil.java:238)
>
> at
> com.evolveum.midpoint.test.util.TestUtil.assertSuccess(TestUtil.java:242)
>
> at
> com.evolveum.midpoint.model.test.AbstractModelIntegrationTest.importAndGetObjectFromFile(AbstractModelIntegrationTest.java:333)
>
> at
> com.evolveum.midpoint.model.test.AbstractModelIntegrationTest.importAndGetObjectFromFile(AbstractModelIntegrationTest.java:327)
>
> at
> com.evolveum.midpoint.model.impl.AbstractInternalModelIntegrationTest.initSystem(AbstractInternalModelIntegrationTest.java:207)
>
> at
> com.evolveum.midpoint.wf.impl.AbstractWfTest.initSystem(AbstractWfTest.java:158)
>
> at
> com.evolveum.midpoint.test.AbstractIntegrationTest.initSystemConditional(AbstractIntegrationTest.java:180)
>
> How can I setup the run configuration to make this test working?
>
>
>
> _______________________________________________
> midPoint mailing list
> midPoint at lists.evolveum.com
> http://lists.evolveum.com/mailman/listinfo/midpoint
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.evolveum.com/pipermail/midpoint/attachments/20150804/733ff297/attachment.htm>
More information about the midPoint
mailing list