Add @Override annotations to test sources
Issue: SPR-10129
This commit is contained in:
@@ -45,14 +45,17 @@ public class AutowiredQualifierFooService implements FooService {
|
||||
this.initCalled = true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String foo(int id) {
|
||||
return this.fooDao.findFoo(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Future<String> asyncFoo(int id) {
|
||||
return new AsyncResult<String>(this.fooDao.findFoo(id));
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isInitCalled() {
|
||||
return this.initCalled;
|
||||
}
|
||||
|
||||
@@ -74,16 +74,19 @@ public class FooServiceImpl implements FooService {
|
||||
this.initCalled = true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String foo(int id) {
|
||||
return this.fooDao.findFoo(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Future<String> asyncFoo(int id) {
|
||||
System.out.println(Thread.currentThread().getName());
|
||||
Assert.state(ServiceInvocationCounter.getThreadLocalCount() != null, "Thread-local counter not exposed");
|
||||
return new AsyncResult<String>(this.fooDao.findFoo(id));
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isInitCalled() {
|
||||
return this.initCalled;
|
||||
}
|
||||
|
||||
@@ -28,14 +28,17 @@ import org.springframework.scheduling.annotation.AsyncResult;
|
||||
@Scope("myScope")
|
||||
public class ScopedProxyTestBean implements FooService {
|
||||
|
||||
@Override
|
||||
public String foo(int id) {
|
||||
return "bar";
|
||||
}
|
||||
|
||||
@Override
|
||||
public Future<String> asyncFoo(int id) {
|
||||
return new AsyncResult<String>("bar");
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isInitCalled() {
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -26,6 +26,7 @@ import org.springframework.stereotype.Repository;
|
||||
@Qualifier("testing")
|
||||
public class StubFooDao implements FooDao {
|
||||
|
||||
@Override
|
||||
public String findFoo(int id) {
|
||||
return "bar";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user