I am thinking Is it possible for testNG to take care of building the Junit test cases, and if there was some compiling error for one test case, it will record that error message and switch to next one ?
---------------------------------------------------------------------
Posted via Jive Forums
http://forums.opensymphony.com/thread.jspa?threadID=35674&messageID=69813#69813
I am not sure I am understanding exactly your question. TestNG is not
compiling Java sources, and it using the information you gave him to
run your tests. If you are telling TestNG to run tests in the class A
and TestNG is not able to load that class than it is normal to signal
you this problem.
hth,
./alex
--
.w( the_mindstorm )p.
I am working on a project which is at very early stage, all the developers are creating object classes and junit test cases. And there is one person, which is me, has some extra job, which is to run ALL the junit test cases to make sure these junit test cases working. There are about 3,000+ test classes.
As you can see from time to time, I have to make sure that ALL new test classes are built before I start this testNG command, otherwise this command will just stop. So my expectation is :
1. Once testNG finds one test case class is not available, it builds the class. ( that may be too much for it )
2. OR it finds one test case class is not available, it saves the "class not available " info in this testcase.html and goes to the next test case.
In that way, I may run this testNG command TWICE, and gets all the "FINAL" test results.
---------------------------------------------------------------------
Posted via Jive Forums
http://forums.opensymphony.com/thread.jspa?threadID=35674&messageID=69832#69832
TestNG will never do this. TestNG will never become a java compiler;
not even trigger a compilation.
> 2. OR it finds one test case class is not available, it saves the "class not available " info in this testcase.html and goes to the next test case.
>
It is a very serious problem you have manually specified a test class
and it is not found. And you don't really want to continue, because it
may result in a completely screwed test suite.
(say your missing class is the one that rollback your database tests,
if we just continue than you will have a screwed database).
IMO TestNG is behaving correctly and we don't intend to change this
behavior without very solid arguments. Once you included the class it
is your responsibility to make sure it is available or not.
./alex
--
.w( the_mindstorm )p.