#86 - Fixed test names to make sure they run during build.

Fixed some generics declaration to make sure code compiles on Java 6 as well.
This commit is contained in:
Oliver Gierke
2013-06-12 12:35:22 +02:00
parent 1db0068013
commit 3068a03764
19 changed files with 24 additions and 24 deletions

View File

@@ -13,7 +13,7 @@ import com.fasterxml.jackson.databind.ObjectMapper;
* @author Oliver Gierke
* @author Jon Brisbin
*/
public abstract class AbstractJackson2MarshallingIntegrationTests {
public abstract class AbstractJackson2MarshallingIntegrationTest {
protected ObjectMapper mapper;

View File

@@ -26,7 +26,7 @@ import org.junit.Before;
*
* @author Oliver Gierke
*/
public abstract class AbstractMarshallingIntegrationTests {
public abstract class AbstractMarshallingIntegrationTest {
protected ObjectMapper mapper;

View File

@@ -26,7 +26,7 @@ import org.junit.Test;
* @author Oliver Gierke
* @author Jon Brisbin
*/
public class Jackson2LinkIntegrationTest extends AbstractJackson2MarshallingIntegrationTests {
public class Jackson2LinkIntegrationTest extends AbstractJackson2MarshallingIntegrationTest {
private static final String REFERENCE = "{\"rel\":\"something\",\"href\":\"location\"}";

View File

@@ -13,7 +13,7 @@ import com.fasterxml.jackson.annotation.JsonAutoDetect;
* @author Oliver Gierke
* @author Jon Brisbin
*/
public class Jackson2ResourceIntegrationTest extends AbstractJackson2MarshallingIntegrationTests {
public class Jackson2ResourceIntegrationTest extends AbstractJackson2MarshallingIntegrationTest {
static final String REFERENCE = "{\"links\":[{\"rel\":\"self\",\"href\":\"localhost\"}],\"firstname\":\"Dave\",\"lastname\":\"Matthews\"}";

View File

@@ -25,7 +25,7 @@ import org.junit.Test;
*
* @author Oliver Gierke
*/
public class Jackson2ResourceSupportIntegrationTest extends AbstractJackson2MarshallingIntegrationTests {
public class Jackson2ResourceSupportIntegrationTest extends AbstractJackson2MarshallingIntegrationTest {
static final String REFERENCE = "{\"links\":[{\"rel\":\"self\",\"href\":\"localhost\"}]}";

View File

@@ -25,7 +25,7 @@ import org.junit.Test;
*
* @author Oliver Gierke
*/
public class LinkIntegrationTest extends AbstractMarshallingIntegrationTests {
public class LinkIntegrationTest extends AbstractMarshallingIntegrationTest {
private static final String REFERENCE = "{\"rel\":\"something\",\"href\":\"location\"}";

View File

@@ -27,7 +27,7 @@ import org.junit.Test;
*
* @author Oliver Gierke
*/
public class ResourceIntegrationTest extends AbstractMarshallingIntegrationTests {
public class ResourceIntegrationTest extends AbstractMarshallingIntegrationTest {
static final String REFERENCE = "{\"links\":[{\"rel\":\"self\",\"href\":\"localhost\"}],\"firstname\":\"Dave\",\"lastname\":\"Matthews\"}";

View File

@@ -25,7 +25,7 @@ import org.junit.Test;
*
* @author Oliver Gierke
*/
public class ResourceSupportIntegrationTest extends AbstractMarshallingIntegrationTests {
public class ResourceSupportIntegrationTest extends AbstractMarshallingIntegrationTest {
static final String REFERENCE = "{\"links\":[{\"rel\":\"self\",\"href\":\"localhost\"}]}";

View File

@@ -45,7 +45,7 @@ import com.fasterxml.jackson.databind.SerializationFeature;
*
* @author Oliver Gierke
*/
public class VndErrorsMarshallingTests {
public class VndErrorsMarshallingTest {
ObjectMapper jackson1Mapper;
com.fasterxml.jackson.databind.ObjectMapper jackson2Mapper;
@@ -55,7 +55,7 @@ public class VndErrorsMarshallingTests {
String jsonReference;
String xmlReference;
public VndErrorsMarshallingTests() throws IOException {
public VndErrorsMarshallingTest() throws IOException {
jsonReference = readFile(new ClassPathResource("vnderror.json"));
xmlReference = readFile(new ClassPathResource("vnderror.xml"));

View File

@@ -77,13 +77,13 @@ public class EnableHypermediaSupportIntegrationTest {
private static void assertEntityLinksSetUp(ApplicationContext context) {
Map<String, EntityLinks> discoverers = context.getBeansOfType(EntityLinks.class);
assertThat(discoverers.values(), hasItem(Matchers.<EntityLinks> instanceOf(DelegatingEntityLinks.class)));
assertThat(discoverers.values(), Matchers.<EntityLinks> hasItem(instanceOf(DelegatingEntityLinks.class)));
}
private static void assertRelProvidersSetUp(ApplicationContext context) {
Map<String, RelProvider> discoverers = context.getBeansOfType(RelProvider.class);
assertThat(discoverers.values(), hasItem(Matchers.<RelProvider> instanceOf(DelegatingRelProvider.class)));
assertThat(discoverers.values(), Matchers.<RelProvider> hasItem(instanceOf(DelegatingRelProvider.class)));
}
@Configuration

View File

@@ -31,7 +31,7 @@ import org.springframework.hateoas.LinkDiscoverer;
*
* @author Oliver Gierke
*/
public abstract class AbstractLinkDiscovererUnitTests {
public abstract class AbstractLinkDiscovererUnitTest {
@Test
public void findsSingleLink() {

View File

@@ -22,7 +22,7 @@ import org.springframework.hateoas.LinkDiscoverer;
*
* @author Oliver Gierke
*/
public class DefaultLinkDiscovererUnitTest extends AbstractLinkDiscovererUnitTests {
public class DefaultLinkDiscovererUnitTest extends AbstractLinkDiscovererUnitTest {
static final String SAMPLE = "{ links : [ " + //
"{ rel : 'self', href : 'selfHref' }, " + //

View File

@@ -29,7 +29,7 @@ import org.springframework.plugin.core.PluginRegistry;
/**
* @author Oliver Gierke
*/
public class DelegatingRelProviderUnitTests {
public class DelegatingRelProviderUnitTest {
@Test
public void foo() {

View File

@@ -22,7 +22,7 @@ import org.junit.Test;
*
* @author Oliver Gierke
*/
public class JsonPathLinkDiscovererUnitTests {
public class JsonPathLinkDiscovererUnitTest {
@Test(expected = IllegalArgumentException.class)
public void rejectsNullPattern() {

View File

@@ -35,7 +35,7 @@ import org.springframework.hateoas.core.EvoInflectorRelProvider;
* @author Oliver Gierke
* @author Dietrich Schulten
*/
public class HalEmbeddedBuilderUnitTests {
public class HalEmbeddedBuilderUnitTest {
RelProvider provider;

View File

@@ -16,14 +16,14 @@
package org.springframework.hateoas.hal;
import org.springframework.hateoas.LinkDiscoverer;
import org.springframework.hateoas.core.AbstractLinkDiscovererUnitTests;
import org.springframework.hateoas.core.AbstractLinkDiscovererUnitTest;
/**
* Unit tests for {@link HalLinkDiscoverer}.
*
* @author Oliver Gierke
*/
public class HalLinkDiscovererUnitTest extends AbstractLinkDiscovererUnitTests {
public class HalLinkDiscovererUnitTest extends AbstractLinkDiscovererUnitTest {
static final LinkDiscoverer discoverer = new HalLinkDiscoverer();
static final String SAMPLE = "{ _links : { " + //

View File

@@ -23,7 +23,7 @@ import java.util.List;
import org.junit.Before;
import org.junit.Test;
import org.springframework.hateoas.AbstractMarshallingIntegrationTests;
import org.springframework.hateoas.AbstractMarshallingIntegrationTest;
import org.springframework.hateoas.Link;
import org.springframework.hateoas.Links;
import org.springframework.hateoas.PagedResources;
@@ -40,7 +40,7 @@ import org.springframework.hateoas.hal.Jackson1HalModule.HalHandlerInstantiator;
* @author Alexander Baetz
* @author Oliver Gierke
*/
public class Jackson1HalIntegrationTest extends AbstractMarshallingIntegrationTests {
public class Jackson1HalIntegrationTest extends AbstractMarshallingIntegrationTest {
static final String SINGLE_LINK_REFERENCE = "{\"_links\":{\"self\":{\"href\":\"localhost\"}}}";
static final String LIST_LINK_REFERENCE = "{\"_links\":{\"self\":[{\"href\":\"localhost\"},{\"href\":\"localhost2\"}]}}";

View File

@@ -23,7 +23,7 @@ import java.util.List;
import org.junit.Before;
import org.junit.Test;
import org.springframework.hateoas.AbstractJackson2MarshallingIntegrationTests;
import org.springframework.hateoas.AbstractJackson2MarshallingIntegrationTest;
import org.springframework.hateoas.Link;
import org.springframework.hateoas.Links;
import org.springframework.hateoas.PagedResources;
@@ -40,7 +40,7 @@ import org.springframework.hateoas.hal.Jackson2HalModule.HalHandlerInstantiator;
* @author Alexander Baetz
* @author Oliver Gierke
*/
public class Jackson2HalIntegrationTest extends AbstractJackson2MarshallingIntegrationTests {
public class Jackson2HalIntegrationTest extends AbstractJackson2MarshallingIntegrationTest {
static final String SINGLE_LINK_REFERENCE = "{\"_links\":{\"self\":{\"href\":\"localhost\"}}}";
static final String LIST_LINK_REFERENCE = "{\"_links\":{\"self\":[{\"href\":\"localhost\"},{\"href\":\"localhost2\"}]}}";

View File

@@ -33,7 +33,7 @@ import org.springframework.http.ResponseEntity;
*
* @author Oliver Gierke
*/
public class HeaderLinksResponseEntityUnitTests {
public class HeaderLinksResponseEntityUnitTest {
static final Object CONTENT = new Object();
static final Link LINK = new Link("href", "rel");