From the conversation in https://github.com/DSpace/DSpace/pull/1866
The (pre-existing) testing framework builds a test dspace install directory by combining all "src/test/data/dspaceFolder" directories of all modules (see https://github.com/DSpace/DSpace/blob/dspace-6.2/src/main/assembly/testEnvironment.xml#L30). So all Spring beans defined in test-specific Spring XML files, need to be present in the test resources of all modules. That is why I had to add a copy of that class to dspace-api and dspace-spring-rest. Another example of such a class is org.dspace.identifier.MockDOIConnector.