1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Oct 2012
    Rep Power

    (Java/Junit) Problem with CLASSPATH/compile Test file.

    Okay, I am trying to test a class with a test class using import junit.framework.*; and I download the Junit library and saved it with a classpath of: C:\Program Files (x86)\Java\jdk1.7.0_07\lib\junit-4.8.2.j

    I set up the CLASSPATH, and every time I try to compile the test file I get this error: C:\Users\Anita\Documents\java\Project2>j TestImage.java
    TestImage.java:1: error: package junit.framework does not exist
    import junit.framework.*;

    Did I do something wrong in the classpath? I tried everything! Any suggestions on how I can finally get junit to work?
  2. #2
  3. Java Junkie
    Devshed Specialist (4000 - 4499 posts)

    Join Date
    Feb 2004
    Mobile, Alabama
    Rep Power
    Did you include the jar file in your CLASSPATH?

IMN logo majestic logo threadwatch logo seochat tools logo