On Wed, Sep 28, 2022 at 01:15:12AM -0700, Istvan Vig wrote:
> Hello!
> I would like to create an integration test for the version 7.4. And I would
> like to run this test in the way where the
> org.dspace.identifier.VersionedHandleIdentifierProviderWithCanonicalHandles
> is uncommented in the identifier-service.xml:
> ```XML
> <bean id="org.dspace.identifier.HandleIdentifierProvider"
> class="org.dspace.identifier.VersionedHandleIdentifierProviderWithCanonicalHandles"
> scope="singleton"> <property name="configurationService"
> ref="org.dspace.services.ConfigurationService"/> </bean>
> ```
> However, I do not know how should I set up the test env. in order to use
> this versioning option. I copied the identifier-service.xml into the
> folders *dspace-api/src/test/data/dspaceFolder/config/spring/api* and *dspace-server-webapp/src/test/data/dspaceFolder/config/spring/api
> *with the uncommented lines. Then I ran the test and I then checked the
> file
> *dspace-server-webapp/target/testing/dspace/config/spring/api/identifier-service.xml*
> and found that the uncommented lines are there.
>
> But when I run the integration test and print out the generated handles I
> see the default versioning functionality. So it seems that the test does
> not use the VersionedHandleIdentifierProviderWithCanonicalHandles class as
> I expected.
The test environment is packed up during the assembly phase, and
unpacked into the test directory tree during testing. I find that,
when I change anything in the test environment, I have to 'mvn clean
install' before running tests, so that the changed environment can be
retrieved from my local repository.
--
Mark H. Wood
Lead Technology Analyst
University Library
Indiana University - Purdue University Indianapolis
755 W. Michigan Street
Indianapolis, IN 46202
317-274-0749
www.ulib.iupui.edu