java - How test classes get reference of source classes in junit test? -
junit test classes reside in totally different target folders, while running test cases how possible test class reference source classes?
the test framework makes use of classpath feature of jvm. classpath indicates program running tests should find classes needs. environment (your ide, example) sets classpath search in both location of test classes , location of classes testing. set classpath search in location of test classes and then search in location of classes being tested.
Comments
Post a Comment