refactored test data generation. Refactored entity factor methods.
Signed-off-by: Kai Zimmermann <kai.zimmermann@bosch-si.com>
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
*/
|
||||
package org.eclipse.hawkbit.rest;
|
||||
|
||||
import org.eclipse.hawkbit.repository.jpa.AbstractIntegrationTest;
|
||||
import org.eclipse.hawkbit.repository.jpa.AbstractJpaIntegrationTest;
|
||||
import org.eclipse.hawkbit.rest.configuration.RestConfiguration;
|
||||
import org.eclipse.hawkbit.rest.util.FilterHttpResponse;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -19,7 +19,7 @@ import org.springframework.test.web.servlet.setup.DefaultMockMvcBuilder;
|
||||
* Abstract Test for Rest tests.
|
||||
*/
|
||||
@SpringApplicationConfiguration(classes = { RestConfiguration.class })
|
||||
public abstract class AbstractRestIntegrationTest extends AbstractIntegrationTest {
|
||||
public abstract class AbstractRestIntegrationTest extends AbstractJpaIntegrationTest {
|
||||
|
||||
@Autowired
|
||||
private FilterHttpResponse filterHttpResponse;
|
||||
@@ -29,5 +29,4 @@ public abstract class AbstractRestIntegrationTest extends AbstractIntegrationTes
|
||||
final DefaultMockMvcBuilder createMvcWebAppContext = super.createMvcWebAppContext();
|
||||
return createMvcWebAppContext.addFilter(filterHttpResponse);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
*/
|
||||
package org.eclipse.hawkbit.rest;
|
||||
|
||||
import org.eclipse.hawkbit.repository.jpa.AbstractIntegrationTestWithMongoDB;
|
||||
import org.eclipse.hawkbit.repository.jpa.AbstractJpaIntegrationTestWithMongoDB;
|
||||
import org.eclipse.hawkbit.rest.configuration.RestConfiguration;
|
||||
import org.eclipse.hawkbit.rest.util.FilterHttpResponse;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -19,14 +19,14 @@ import org.springframework.test.web.servlet.setup.DefaultMockMvcBuilder;
|
||||
* Abstract Test for Rest tests.
|
||||
*/
|
||||
@SpringApplicationConfiguration(classes = { RestConfiguration.class })
|
||||
public abstract class AbstractRestIntegrationTestWithMongoDB extends AbstractIntegrationTestWithMongoDB {
|
||||
public abstract class AbstractRestIntegrationTestWithMongoDB extends AbstractJpaIntegrationTestWithMongoDB {
|
||||
|
||||
@Autowired
|
||||
private FilterHttpResponse filterHttpResponse;
|
||||
|
||||
@Override
|
||||
protected DefaultMockMvcBuilder createMvcWebAppContext() {
|
||||
DefaultMockMvcBuilder createMvcWebAppContext = super.createMvcWebAppContext();
|
||||
final DefaultMockMvcBuilder createMvcWebAppContext = super.createMvcWebAppContext();
|
||||
return createMvcWebAppContext.addFilter(filterHttpResponse);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user