Does TestNG has runner like SpringJUnit4ClassRunner

Posted by Michal Mech on Stack Overflow See other posts from Stack Overflow or by Michal Mech
Published on 2010-04-12T19:20:11Z Indexed on 2010/04/12 19:23 UTC
Read the original article Hit count: 524

Filed under:
|
|
|

Hi,

When I write tests in JUnit (in Spring context) I usualy do it like this:

@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration("classpath:testContext.xml")
public class SimpleTest {

    @Test
    public void testMethod() {
        // execute test logic...
    }
}

How can I do the same with TestNG?

© Stack Overflow or respective owner

Related posts about java

Related posts about testng