Hi to all, I;m facing a problem that I'm unable to solve, following the
tutorial regarding persistence and Hibernate, an error raised up running
"mvn -e test -Dtest=AnonIdDaoTest -Dsurefire.useFile=false".
This is the output of the command (part of): 

-------------------------------------------------------
 T E S T S
-------------------------------------------------------
Running org.rossw.aftrial.dao.AnonIdDaoTest
Tests run: 2, Failures: 0, Errors: 2, Skipped: 0, Time elapsed: 1.172 sec
<<< FA
ILURE!
testAddAndRemoveAnonId(org.rossw.aftrial.dao.AnonIdDaoTest)  Time elapsed:
1.078
 sec  <<< ERROR!
org.springframework.beans.factory.BeanCreationException: Error creating bean
wit
h name 'anonIdDao' defined in URL
[file:/C:/NBprojects/AppfuseTrial/core/target/
classes/applicationContext.xml]: Instantiation of bean failed; nested
exception
is org.springframework.beans.BeanInstantiationException: Could not
instantiate b
ean class [org.appfuse.dao.hibernate.GenericDaoHibernate]: No default
constructo
r found; nested exception is java.lang.NoSuchMethodException:
org.appfuse.dao.hi
bernate.GenericDaoHibernate.<init>()
        at
org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory.instantiateBean(AbstractAutowireCapableBeanFactory.java:917)
        at
org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:873)
        at
org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory.doCreateBean(AbstractAutowireCapableBeanFactory.java:514)
        at
org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory$1.run(AbstractAutowireCapableBeanFactory.java:485)
        at java.security.AccessController.doPrivileged(Native Method)
        at
org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory.createBean(AbstractAutowireCapableBeanFactory.java:455)
        at
org.springframework.beans.factory.support.AbstractBeanFactory$1.getOb
ject(AbstractBeanFactory.java:251)
        at
org.springframework.beans.factory.support.DefaultSingletonBeanRegistr
y.getSingleton(DefaultSingletonBeanRegistry.java:169)
        at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean
(AbstractBeanFactory.java:248)
        at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean
(AbstractBeanFactory.java:170)
        at
org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory.autowireByName(AbstractAutowireCapableBeanFactory.java:1061)
        at
org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory.populateBean(AbstractAutowireCapableBeanFactory.java:1009)
        at
org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory.autowireBeanProperties(AbstractAutowireCapableBeanFactory.java:291)
        at
org.springframework.test.AbstractDependencyInjectionSpringContextTest
s.injectDependencies(AbstractDependencyInjectionSpringContextTests.java:230)
        at
org.springframework.test.AbstractDependencyInjectionSpringContextTest
s.prepareTestInstance(AbstractDependencyInjectionSpringContextTests.java:195)
        at
org.springframework.test.AbstractSingleSpringContextTests.setUp(Abstr
actSingleSpringContextTests.java:102)
        at junit.framework.TestCase.runBare(TestCase.java:132)
        at
org.springframework.test.ConditionalTestCase.runBare(ConditionalTestC
ase.java:76)
        at junit.framework.TestResult$1.protect(TestResult.java:110)
        at junit.framework.TestResult.runProtected(TestResult.java:128)
        at junit.framework.TestResult.run(TestResult.java:113)
        at junit.framework.TestCase.run(TestCase.java:124)
        at junit.framework.TestSuite.runTest(TestSuite.java:232)
        at junit.framework.TestSuite.run(TestSuite.java:227)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at
org.apache.maven.surefire.junit.JUnitTestSet.execute(JUnitTestSet.jav
a:210)
        at
org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTes
tSet(AbstractDirectoryTestSuite.java:135)
        at
org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(Ab
stractDirectoryTestSuite.java:122)
        at org.apache.maven.surefire.Surefire.run(Surefire.java:129)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at
org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(Su
refireBooter.java:225)
        at
org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.j
ava:747)
Caused by: org.springframework.beans.BeanInstantiationException: Could not
insta
ntiate bean class [org.appfuse.dao.hibernate.GenericDaoHibernate]: No
default co
nstructor found; nested exception is java.lang.NoSuchMethodException:
org.appfus
e.dao.hibernate.GenericDaoHibernate.<init>()
        at
org.springframework.beans.factory.support.SimpleInstantiationStrategy
.instantiate(SimpleInstantiationStrategy.java:58)
        at
org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory.instantiateBean(AbstractAutowireCapableBeanFactory.java:911)
        ... 37 more
Caused by: java.lang.NoSuchMethodException:
org.appfuse.dao.hibernate.GenericDao
Hibernate.<init>()
        at java.lang.Class.getConstructor0(Class.java:2706)
        at java.lang.Class.getDeclaredConstructor(Class.java:1985)
        at
org.springframework.beans.factory.support.SimpleInstantiationStrategy
.instantiate(SimpleInstantiationStrategy.java:54)
        ... 38 more

I've searched for the GenericDaoHibernate source but I haven't found it (is
there a javadoc?).

Thoughts ?
Thanks
Rob
-- 
View this message in context: 
http://www.nabble.com/GenericDaoHibernate---NoSuchMethodException-tp16491882s2369p16491882.html
Sent from the AppFuse - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to