File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Testing and the fly likes Spring + Junit Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Java Interview Guide this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Engineering » Testing
Bookmark "Spring + Junit" Watch "Spring + Junit" New topic

Spring + Junit

sam backet

Joined: Sep 02, 2011
Posts: 22


I want to use the Spring to test classes. But I get the following error. The path is correct.

java.lang.IllegalStateException: Failed to load ApplicationContext

- IDE: Netbeans 7.0.1


Jeanne Boyarsky
author & internet detective

Joined: May 26, 2003
Posts: 33134

Is anything else in the stack trace? Usually when Spring can't create a context, it has trouble wiring or injecting something. Also, does really not have a package name. Putting things in the default package can be unpredictable.

[OCA 8 book] [Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Other Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, TOGAF part 1 and part 2
I agree. Here's the link:
subject: Spring + Junit
It's not a secret anymore!