DATACMNS-973 - Migrate ticket references in test code to Spring Framework style.

This commit is contained in:
Mark Paluch
2017-01-13 08:45:25 +01:00
parent a946d651ff
commit 4eb1ae8de2
146 changed files with 1080 additions and 3893 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2014-2015 the original author or authors.
* Copyright 2014-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -89,10 +89,7 @@ public class BytecodeGeneratingEntityInstantiatorUnitTests<P extends PersistentP
verify(provider, times(1)).getParameterValue((Parameter) constructor.getParameters().iterator().next());
}
/**
* @see DATACMNS-300, DATACMNS-578
*/
@Test(expected = MappingInstantiationException.class)
@Test(expected = MappingInstantiationException.class) // DATACMNS-300, DATACMNS-578
@SuppressWarnings({ "unchecked", "rawtypes" })
public void throwsExceptionOnBeanInstantiationException() {
@@ -102,10 +99,7 @@ public class BytecodeGeneratingEntityInstantiatorUnitTests<P extends PersistentP
INSTANCE.createInstance(entity, provider);
}
/**
* @see DATACMNS-134, DATACMNS-578
*/
@Test
@Test // DATACMNS-134, DATACMNS-578
public void createsInnerClassInstanceCorrectly() {
BasicPersistentEntity<Inner, P> entity = new BasicPersistentEntity<Inner, P>(from(Inner.class));
@@ -130,10 +124,7 @@ public class BytecodeGeneratingEntityInstantiatorUnitTests<P extends PersistentP
});
}
/**
* @see DATACMNS-283, DATACMNS-578
*/
@Test
@Test // DATACMNS-283, DATACMNS-578
@SuppressWarnings({ "unchecked", "rawtypes" })
public void capturesContextOnInstantiationException() throws Exception {
@@ -162,10 +153,7 @@ public class BytecodeGeneratingEntityInstantiatorUnitTests<P extends PersistentP
}
}
/**
* @see DATACMNS-578
*/
@Test
@Test // DATACMNS-578
@SuppressWarnings({ "unchecked", "rawtypes" })
public void instantiateObjCtorDefault() {
@@ -181,10 +169,7 @@ public class BytecodeGeneratingEntityInstantiatorUnitTests<P extends PersistentP
}
}
/**
* @see DATACMNS-578
*/
@Test
@Test // DATACMNS-578
@SuppressWarnings({ "unchecked", "rawtypes" })
public void instantiateObjCtorNoArgs() {
@@ -201,10 +186,7 @@ public class BytecodeGeneratingEntityInstantiatorUnitTests<P extends PersistentP
}
}
/**
* @see DATACMNS-578
*/
@Test
@Test // DATACMNS-578
@SuppressWarnings({ "unchecked", "rawtypes" })
public void instantiateObjCtor1ParamString() {
@@ -224,10 +206,7 @@ public class BytecodeGeneratingEntityInstantiatorUnitTests<P extends PersistentP
}
}
/**
* @see DATACMNS-578
*/
@Test
@Test // DATACMNS-578
@SuppressWarnings({ "unchecked", "rawtypes" })
public void instantiateObjCtor2ParamStringString() {
@@ -248,10 +227,7 @@ public class BytecodeGeneratingEntityInstantiatorUnitTests<P extends PersistentP
}
}
/**
* @see DATACMNS-578
*/
@Test
@Test // DATACMNS-578
@SuppressWarnings({ "unchecked", "rawtypes" })
public void instantiateObjectCtor1ParamInt() {
@@ -271,10 +247,7 @@ public class BytecodeGeneratingEntityInstantiatorUnitTests<P extends PersistentP
}
}
/**
* @see DATACMNS-578
*/
@Test
@Test // DATACMNS-578
@SuppressWarnings({ "unchecked", "rawtypes" })
public void instantiateObjectCtor7ParamsString5IntsString() {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2014 the original author or authors.
* Copyright 2014-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -89,10 +89,7 @@ public class ClassGeneratingEntityInstantiatorUnitTests<P extends PersistentProp
verify(provider, times(1)).getParameterValue((Parameter) constructor.getParameters().iterator().next());
}
/**
* @see DATACMNS-300, DATACMNS-578
*/
@Test(expected = MappingInstantiationException.class)
@Test(expected = MappingInstantiationException.class) // DATACMNS-300, DATACMNS-578
@SuppressWarnings({ "unchecked", "rawtypes" })
public void throwsExceptionOnBeanInstantiationException() {
@@ -102,10 +99,7 @@ public class ClassGeneratingEntityInstantiatorUnitTests<P extends PersistentProp
this.instance.createInstance(entity, provider);
}
/**
* @see DATACMNS-134, DATACMNS-578
*/
@Test
@Test // DATACMNS-134, DATACMNS-578
public void createsInnerClassInstanceCorrectly() {
BasicPersistentEntity<Inner, P> entity = new BasicPersistentEntity<Inner, P>(from(Inner.class));
@@ -130,10 +124,7 @@ public class ClassGeneratingEntityInstantiatorUnitTests<P extends PersistentProp
});
}
/**
* @see DATACMNS-283, DATACMNS-578
*/
@Test
@Test // DATACMNS-283, DATACMNS-578
@SuppressWarnings({ "unchecked", "rawtypes" })
public void capturesContextOnInstantiationException() throws Exception {
@@ -162,10 +153,7 @@ public class ClassGeneratingEntityInstantiatorUnitTests<P extends PersistentProp
}
}
/**
* @see DATACMNS-578
*/
@Test
@Test // DATACMNS-578
@SuppressWarnings({ "unchecked", "rawtypes" })
public void instantiateObjCtorDefault() {
@@ -181,10 +169,7 @@ public class ClassGeneratingEntityInstantiatorUnitTests<P extends PersistentProp
}
}
/**
* @see DATACMNS-578
*/
@Test
@Test // DATACMNS-578
@SuppressWarnings({ "unchecked", "rawtypes" })
public void instantiateObjCtorNoArgs() {
@@ -201,10 +186,7 @@ public class ClassGeneratingEntityInstantiatorUnitTests<P extends PersistentProp
}
}
/**
* @see DATACMNS-578
*/
@Test
@Test // DATACMNS-578
@SuppressWarnings({ "unchecked", "rawtypes" })
public void instantiateObjCtor1ParamString() {
@@ -224,10 +206,7 @@ public class ClassGeneratingEntityInstantiatorUnitTests<P extends PersistentProp
}
}
/**
* @see DATACMNS-578
*/
@Test
@Test // DATACMNS-578
@SuppressWarnings({ "unchecked", "rawtypes" })
public void instantiateObjCtor2ParamStringString() {
@@ -248,10 +227,7 @@ public class ClassGeneratingEntityInstantiatorUnitTests<P extends PersistentProp
}
}
/**
* @see DATACMNS-578
*/
@Test
@Test // DATACMNS-578
@SuppressWarnings({ "unchecked", "rawtypes" })
public void instantiateObjectCtor1ParamInt() {
@@ -271,10 +247,7 @@ public class ClassGeneratingEntityInstantiatorUnitTests<P extends PersistentProp
}
}
/**
* @see DATACMNS-578
*/
@Test
@Test // DATACMNS-578
@SuppressWarnings({ "unchecked", "rawtypes" })
public void instantiateObjectCtor7ParamsString5IntsString() {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2013 the original author or authors.
* Copyright 2013-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -71,10 +71,7 @@ public class DefaultTypeMapperUnitTests {
verify(mapper, times(1)).resolveTypeFrom(STRING);
}
/**
* @see DATACMNS-349
*/
@Test
@Test // DATACMNS-349
public void returnsTypeAliasForInformation() {
Object alias = "alias";
@@ -83,10 +80,7 @@ public class DefaultTypeMapperUnitTests {
assertThat(this.typeMapper.getAliasFor(STRING_TYPE_INFO), is(alias));
}
/**
* @see DATACMNS-783
*/
@Test
@Test // DATACMNS-783
public void specializesRawSourceTypeUsingGenericContext() {
ClassTypeInformation<Foo> root = ClassTypeInformation.from(Foo.class);

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2014-2016 the original author or authors.
* Copyright 2014-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -74,75 +74,51 @@ public class Jsr310ConvertersUnitTests {
public static class CommonTests {
/**
* @see DATACMNS-606
*/
@Test
@Test // DATACMNS-606
public void convertsDateToLocalDateTime() {
assertThat(CONVERSION_SERVICE.convert(NOW, LocalDateTime.class).toString(),
is(format(NOW, "yyyy-MM-dd'T'HH:mm:ss.SSS")));
}
/**
* @see DATACMNS-606
*/
@Test
@Test // DATACMNS-606
public void convertsLocalDateTimeToDate() {
LocalDateTime now = LocalDateTime.now();
assertThat(format(CONVERSION_SERVICE.convert(now, Date.class), "yyyy-MM-dd'T'HH:mm:ss.SSS"), is(now.toString()));
}
/**
* @see DATACMNS-606
*/
@Test
@Test // DATACMNS-606
public void convertsDateToLocalDate() {
assertThat(CONVERSION_SERVICE.convert(NOW, LocalDate.class).toString(), is(format(NOW, "yyyy-MM-dd")));
}
/**
* @see DATACMNS-606
*/
@Test
@Test // DATACMNS-606
public void convertsLocalDateToDate() {
LocalDate now = LocalDate.now();
assertThat(format(CONVERSION_SERVICE.convert(now, Date.class), "yyyy-MM-dd"), is(now.toString()));
}
/**
* @see DATACMNS-606
*/
@Test
@Test // DATACMNS-606
public void convertsDateToLocalTime() {
assertThat(CONVERSION_SERVICE.convert(NOW, LocalTime.class).toString(), is(format(NOW, "HH:mm:ss.SSS")));
}
/**
* @see DATACMNS-606
*/
@Test
@Test // DATACMNS-606
public void convertsLocalTimeToDate() {
LocalTime now = LocalTime.now();
assertThat(format(CONVERSION_SERVICE.convert(now, Date.class), "HH:mm:ss.SSS"), is(now.toString()));
}
/**
* @see DATACMNS-623
*/
@Test
@Test // DATACMNS-623
public void convertsDateToInstant() {
Date now = new Date();
assertThat(CONVERSION_SERVICE.convert(now, Instant.class), is(now.toInstant()));
}
/**
* @see DATACMNS-623
*/
@Test
@Test // DATACMNS-623
public void convertsInstantToDate() {
Date now = new Date();
@@ -170,9 +146,7 @@ public class Jsr310ConvertersUnitTests {
@RunWith(Parameterized.class)
public static class DurationConversionTests extends ConversionTest<Duration> {
/**
* @see DATACMNS-951
*/
// DATACMNS-951
@Parameters
public static Collection<Object[]> data() {
@@ -189,9 +163,7 @@ public class Jsr310ConvertersUnitTests {
public static class PeriodConversionTests extends ConversionTest<Period> {
/**
* @see DATACMNS-951
*/
// DATACMNS-951
@Parameters
public static Collection<Object[]> data() {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012 the original author or authors.
* Copyright 2012-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -99,10 +99,7 @@ public class MappingContextTypeInformationMapperUnitTests {
assertThat(mapper.resolveTypeFrom("foo"), is((TypeInformation) from(Entity.class)));
}
/**
* @see DATACMNS-485
*/
@Test
@Test // DATACMNS-485
@SuppressWarnings("unchecked")
public void createsTypeMapperForGenericTypesWithDifferentBindings() {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2013 the original author or authors.
* Copyright 2012-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -92,10 +92,7 @@ public class ReflectionEntityInstantiatorUnitTests<P extends PersistentProperty<
verify(provider, times(1)).getParameterValue((Parameter) constructor.getParameters().iterator().next());
}
/**
* @see DATACMNS-300
*/
@Test(expected = MappingInstantiationException.class)
@Test(expected = MappingInstantiationException.class) // DATACMNS-300
@SuppressWarnings({ "unchecked", "rawtypes" })
public void throwsExceptionOnBeanInstantiationException() {
@@ -105,10 +102,7 @@ public class ReflectionEntityInstantiatorUnitTests<P extends PersistentProperty<
INSTANCE.createInstance(entity, provider);
}
/**
* @see DATACMNS-134
*/
@Test
@Test // DATACMNS-134
public void createsInnerClassInstanceCorrectly() {
BasicPersistentEntity<Inner, P> entity = new BasicPersistentEntity<Inner, P>(from(Inner.class));
@@ -133,10 +127,7 @@ public class ReflectionEntityInstantiatorUnitTests<P extends PersistentProperty<
});
}
/**
* @see DATACMNS-283
*/
@Test
@Test // DATACMNS-283
@SuppressWarnings({ "unchecked", "rawtypes" })
public void capturesContextOnInstantiationException() throws Exception {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2015 the original author or authors.
* Copyright 2015-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -57,75 +57,51 @@ public class ThreeTenBackPortConvertersUnitTests {
CONVERSION_SERVICE = conversionService;
}
/**
* @see DATACMNS-606
*/
@Test
@Test // DATACMNS-606
public void convertsDateToLocalDateTime() {
assertThat(CONVERSION_SERVICE.convert(NOW, LocalDateTime.class).toString(),
is(format(NOW, "yyyy-MM-dd'T'HH:mm:ss.SSS")));
}
/**
* @see DATACMNS-606
*/
@Test
@Test // DATACMNS-606
public void convertsLocalDateTimeToDate() {
LocalDateTime now = LocalDateTime.now();
assertThat(format(CONVERSION_SERVICE.convert(now, Date.class), "yyyy-MM-dd'T'HH:mm:ss.SSS"), is(now.toString()));
}
/**
* @see DATACMNS-606
*/
@Test
@Test // DATACMNS-606
public void convertsDateToLocalDate() {
assertThat(CONVERSION_SERVICE.convert(NOW, LocalDate.class).toString(), is(format(NOW, "yyyy-MM-dd")));
}
/**
* @see DATACMNS-606
*/
@Test
@Test // DATACMNS-606
public void convertsLocalDateToDate() {
LocalDate now = LocalDate.now();
assertThat(format(CONVERSION_SERVICE.convert(now, Date.class), "yyyy-MM-dd"), is(now.toString()));
}
/**
* @see DATACMNS-606
*/
@Test
@Test // DATACMNS-606
public void convertsDateToLocalTime() {
assertThat(CONVERSION_SERVICE.convert(NOW, LocalTime.class).toString(), is(format(NOW, "HH:mm:ss.SSS")));
}
/**
* @see DATACMNS-606
*/
@Test
@Test // DATACMNS-606
public void convertsLocalTimeToDate() {
LocalTime now = LocalTime.now();
assertThat(format(CONVERSION_SERVICE.convert(now, Date.class), "HH:mm:ss.SSS"), is(now.toString()));
}
/**
* @see DATACMNS-623
*/
@Test
@Test // DATACMNS-623
public void convertsDateToInstant() {
Date now = new Date();
assertThat(CONVERSION_SERVICE.convert(now, Instant.class), is(toInstant(now)));
}
/**
* @see DATACMNS-623
*/
@Test
@Test // DATACMNS-623
public void convertsInstantToDate() {
Date now = new Date();