Junit 4 test suite and individual test classes
        Posted  
        
            by Hypnus
        on Stack Overflow
        
        See other posts from Stack Overflow
        
            or by Hypnus
        
        
        
        Published on 2010-02-22T10:44:23Z
        Indexed on 
            2010/05/31
            21:53 UTC
        
        
        Read the original article
        Hit count: 256
        
I have a JUnit 4 test suite with BeforeClass and AfterClass methods that make a setup/teardown for the following test classes. What I need is to run the test classes also by them selves, but for that I need a setup/teardown scenario (BeforeClass and AfterClass or something like that) for each test class. The thing is that when I run the suite I do not want to execute the setup/teardown before and after each test class, I only want to execute the setup/teardown from the test suite (once). Is it possible ? Thanks in advance.
© Stack Overflow or respective owner