Stop using convention-based annotation attribute overrides in tests
This commit replaces convention-based annotation attribute overrides in tests with explicit use of @AliasFor -- except for tests in spring-core, since we still want to test our support for convention-based annotation attribute overrides. See gh-28760
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2020 the original author or authors.
|
||||
* Copyright 2002-2022 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.
|
||||
@@ -29,6 +29,7 @@ import org.junit.jupiter.api.Test;
|
||||
|
||||
import org.springframework.aop.framework.Advised;
|
||||
import org.springframework.aop.framework.ProxyFactory;
|
||||
import org.springframework.core.annotation.AliasFor;
|
||||
import org.springframework.core.annotation.AnnotationUtils;
|
||||
import org.springframework.core.testfixture.io.SerializationTestUtils;
|
||||
import org.springframework.transaction.TransactionManager;
|
||||
@@ -668,6 +669,7 @@ public class AnnotationTransactionAttributeSourceTests {
|
||||
@Transactional(rollbackFor = Exception.class, noRollbackFor = IOException.class)
|
||||
@interface TxWithAttribute {
|
||||
|
||||
@AliasFor(annotation = Transactional.class)
|
||||
boolean readOnly();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user