I am trying to use @Tested
If i try to use the object reference which is marked as @Tested in method annotated with @Before that throws null pointer exception. but if i use that object reference directly with test method that just works fine.
Below is the example:
@Tested
private A a;
@Before
public void doSetUp(){
a.setTest(); ---- this will throw NPE with version 1.17 and below
}
But if i use the same piece of code in a test method like below:
I am trying to use @Tested If i try to use the object reference which is marked as @Tested in method annotated with @Before that throws null pointer exception. but if i use that object reference directly with test method that just works fine. Below is the example:
@Tested private A a;
@Before public void doSetUp(){
a.setTest(); ---- this will throw NPE with version 1.17 and below }
But if i use the same piece of code in a test method like below:
@Test public void aTest(){
a.setTest(); -- This will just work fine. }
I have seen the link https://github.com/jmockit/jmockit1/issues/168 is this also fixing my issue with version 1.18???