Reputation: 24248
I have an abstract class:
public abstract ClassA {
protected abstract void method1 {...}
Another class ClassB that implements method1.
XML:
bean id="BaseBean" class="ClassB"
bean id="WorkBean" class="ClassA"
lookup-method="method1" bean="BaseBean"
in test:
$RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration(locations = "classpath:test.xml"
public class Test ....
@Autowired
private ClassA classA;
When I run test I receive error:
java.lang.AbstractMethodError ....
Why? Seems that should be invoked method from BaseBean?
Upvotes: 1
Views: 138
Reputation: 6193
I'm not 100% sure if this is your problem, but BaseBean should have singleton="false" on it
Upvotes: 1