[testng-dev] @Test at Class Level

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

[testng-dev] @Test at Class Level

Kuricheti venkata ramesh babu
Hi ,

Scenario :  

@Test
public class testNG_Class01 {

  public void f1() {
  
                   System.out.println("Hello TestNG1!!!");
  
                         }
 

  public void f2() {
                  String str ="Hello TestNG2!!!" ;
            System.out.println(str);
  
                         }
}


When I ran this [ by right click -> Run as ->TestNG Test], I can see that only f2 method is executed. 

Any reason ?

Thanks,
Ramesh

--
You received this message because you are subscribed to the Google Groups "testng-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/testng-dev.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: [testng-dev] @Test at Class Level

⇜Krishnan Mahadevan⇝
With whatever you have provided its hard to say.
Can you please share a screenshot of the Run configuration screen ? That would add some additional context.

Thanks & Regards
Krishnan Mahadevan

"All the desirable things in life are either illegal, expensive, fattening or in love with someone else!"
My Scribblings @ http://wakened-cognition.blogspot.com/
My Technical Scribblings @ https://rationaleemotions.com/


On Wed, Apr 17, 2019 at 7:25 PM Kuricheti venkata ramesh babu <[hidden email]> wrote:
Hi ,

Scenario :  

@Test
public class testNG_Class01 {

  public void f1() {
  
                   System.out.println("Hello TestNG1!!!");
  
                         }
 

  public void f2() {
                  String str ="Hello TestNG2!!!" ;
            System.out.println(str);
  
                         }
}


When I ran this [ by right click -> Run as ->TestNG Test], I can see that only f2 method is executed. 

Any reason ?

Thanks,
Ramesh

--
You received this message because you are subscribed to the Google Groups "testng-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/testng-dev.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "testng-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/testng-dev.
For more options, visit https://groups.google.com/d/optout.