0
我有一个黄瓜测试,当我尝试获取一个bean时,会抛出一个非法访问错误。我一直无法弄清楚为什么这不好。Cucumber中的弹簧错误java.lang.IllegalAccessError:试图访问类
@Given('^test$')
public void myTest(){
ApplicationContext ctx = new AnnotationConfigApplicationContext(AppInjector.class);
MyBean bean = ctx.getBean(MyBean.class)
}
java.lang.IllegalAccessError: tried to access class MyBean from StepDef