It defines application's behavior using simple English and defined by a language called Gherkin. System.out.println("Test1 Failed"); Cucumber BDD framework with TestNG & Selenium. Example − WHEN I enter my "" AND I enter my "". Add dependency for JUnit − This will indicate Maven, which JUnit files are to be downloaded from the central repository to the local repository. These are inbuilt to Cucumber. Does chemistry workout in job interviews? During execution, the matching glue code i.e. To understand this notion better, let’s take an example of a feature file and a step definition file. Add dependency for Cucumber-Java − this could indicate Maven, which Cucumber files are to be downloaded from the vital repository to the local repository. 4.10 Add dependency for Cucumber-JUnit − this may indicate Maven, which Cucumber JUnit files are to be downloaded from the valuable repository to the local repository. Example − THEN login should be successful. "https://www.facebook.com/login.php?login_attempt=1&lwv=110")){ BUT home page should not be missing. Example − THEN login should be successful. This runner does NOT interepret the Annotation-Based configurations from Cucumber, only the ones from the Cucumber Property-File or System-Properties. Go to File → New → Others → Maven → Maven Project → Next. Offer organization id (group id will perceive your assignment uniquely across all projects). AND can be used in conjunction with GIVEN, WHEN and THEN statement. Step result 1. to five. 2.47.1 We’ll base this example in a BDD exercise where we want to model the behavior of a cashier by means of functionalities in Gherkin and we will do it following these practices. #3) Cucumber Annotations. } , Cucumber hook allows us to better manage the code workflow and helps us to reduce the code redundancy. 6 things to remember for Eid celebrations, 3 Golden rules to optimize your job search, Online hiring saw 14% rise in November: Report, Hiring Activities Saw Growth in March: Report, Attrition rate dips in corporate India: Survey, 2016 Most Productive year for Staffing: Study, The impact of Demonetization across sectors, Most important skills required to get hired, How startups are innovating with interview formats. For every cucumber project there is a single directory at the root of the project named "features". We can say that it is an unseen step, which allows us to perform our scenarios or tests. Cucumber can execute plain-text functional (feature) specifications as automated tests. Product Owner (PO) and business analyst define features in Gherkin. When I enter username as "TOM" , Scenario: The @Steps annotation tells Serenity that this variable is a Step Library. Once pom.xml is edited effectively, save it. Provide the following information within the dependency tag. For each feature under test, we Give the file a name, such as runTest.java. Cucumber has got the following few annotations −. Cucumber has were given the following few annotations – Given – It describes the pre-requisite for the test to be executed. @Given("^I am on Facebook login page$") It signifies logical OR condition between any two statements. @RunWith(Cucumber.class) #Scenario with AND @Cucumber.Options(format = {"pretty", "html:target/cucumber"}) Start a new thread instead. So this is ideal to be used for code when we want to set up the web-browser or we want to establish the database connectivity. Give the file a name such as outline.feature. Once pom.xml is edited successfully, save it. In this video, we are going to start seeing the basic Cucumber Features. import cucumber.annotation.en.Then; Then holds the expected result for the test to be executed. However, it gets executed after “Before” hook (to be covered later). In the console, you will see “Test Pass” printed. Within the dependencies tag, create dependency tag(). Let’s automate a scenario in order to understand annotations better. During the feature execution, Cucumber reports about each internal lifecycle transition by events. (If there is a mismatch, Cucumber will throw an error). driver.findElement(By.id("email")).sendKeys(arg1); test Inside the folder, we create a file with a .feature extension (for example "withdraw-money.feature") 2. When Cucumber encounters a Gherkin step without a matching step definition, it will print a step definition snippet with a matching Cucumber Expression. pick runTest.java record from the package explorer. Background generally has the education on what to setup before every situation runs. The number of parameters in the methodfunctionblockfunction has to match the number of capture groupcapture groupoutput parameteroutput parameters in the expression. , An annotation followed by the pattern is used to link the Step Definition to all the matching Steps, and the code is what Cucumber will execute when it sees a Gherkin Step. It defines the trigger point for any test scenario execution. A Background is much like a scenario containing a number of steps. Note: Again, in cucumber, every example is considered as a separate scenario. 1.0.2 Then Login should fail info.cukes Create a Maven Test Project named as AnnotationTest. WebDriver driver = null; Create Feature file, Step definition & Test Runner classes to automate with Cucumber using TestNG and Selenium. cucumber-java public void enterPassword(String arg1) { Scenario outline basically replaces variable/keywords with the value from the table. info.cukes I am on Facebook login page } It presents the logical AND condition between any two statements. This annotation tells Cucumber a lot of things like where to look for feature files, what reporting system to use and some other things also. you can pick out any name that's in lowercase). Open pom.xml is in edit mode, create dependencies tag (), inside the project tag. Category: Cucumber By Lakshay Sharma October 3, 2017 In order to run a test with JUnit a special runner class should be created. test } It describes the pre-requisite for the test to be executed. Normally tags are @Given, @When, @Then. } else { Part of that plan was the introduction of automated browser/e2e tests with a BDD tooling/proces. #Scenario with BUT Annotation is a predefined text, which holds a specific meaning. Example − WHEN I enter my "" AND I enter my "". driver.findElement(By.id("pass")).sendKeys(arg1); How to Convert Your Internship into a Full Time Job? Cucumber has were given the following few annotations –. driver.close(); selenium-java It lets the compiler/interpreter know, what need to be accomplished upon execution. Have a nice day, Sébastien Laoût. Cucumber executes all scenarios from all features. } public class annotation { The very basic form of the file is an empty class with @RunWith(Cucumber.class) annotation. You can choose any name which is in lowercase). Each keyword is translated to many spoken languages; in this reference we’ll use English. test Cucumber annotation is used to map with feature file. public class runTest { }, You'll observe the subsequent matters while you run this class document −, All rights reserved © 2020 Wisdom IT Services India Pvt. In addition to the annotation, step definitions could ALSO throw a Cucumber's ContinueNextStepsException that would implicitely have the same effect as the annotation. Open pom.xml is in edit mode, create dependencies tag (), within the project tag. Unfortunately, I can't answer why cucumber actually has different annotations for step definitions, but I know why I would have designed the API with those different annotations if I had designed it. What are the prereqs for building a Selenium Cucumber automation framework? Provide group Id (group Id will identify your project uniquely across all projects). The language that Cucumber understands is called Gherkin. @Then("^Login should fail$") Ok, now that you know that BDD is about discovery, collaboration and examples (and not testing), let’s take a look at Cucumber. In this directory you will find additional directories, which is step_definition and support directories What is "Feature File"? } When I enter username as "TOM" Before we dive into best practices and tricks in writing our glue code, we want to cover a few last tricks on keeping our Feature files clean. System.out.println("Test1 Pass"); 5 Top Career Tips to Get Ready for a Virtual Job Fair, Smart tips to succeed in virtual job fairs. Provide following records within the dependency tag. The process looks something like this: 1. Provide artifact Id (artifact Id is the name of the jar without version. Go to package explorer on the left hand side of Eclipse. Visit document → New → Others → Maven → Maven project → next. Cucumber is a testing tool for Behavior-Driven Development approach. Example − THEN login should be successful. import org.openqa.selenium.By; Suppose we are interested in modeling the behavior of an ATM when we want to withdraw money: 1. In the example given in step definitions, Cucumber extracts the text 48 from the step, converts it to an intand passes it as an argument to the methodfunctionblockfunction. 15 signs your job interview is going horribly, Time to Expand NBFCs: Rise in Demand for Talent. import org.openqa.selenium.firefox.FirefoxDriver; Message will be displayed on the browser regarding unsuccessful login. Pick out and right-click on at the bundle outline. Scenario: SIMgroep was thinking on improving the release process and started writing a simple plan that prescribes the way software is developed, tested en released. let’s automate a scenario a good way to recognize annotations higher. Cucumber is a Java framework for BDD, by its support for a set of interactions between team members and stakeholders. So the output is the same as the second example above. Give the … In real time projects, there could … It lets the compiler/interpreter know, what should be done upon execution. , Feature: annotation Tags: Cucumber by default runs all scenarios in all the feature files. Before we get into the Features, we will first learn what is Cucumber. Add dependency for Cucumber-JUnit − This will indicate Maven, which Cucumber JUnit files are to be downloaded from the central repository to the local repository. It lets the compiler/interpreter know, what should be done upon execution. Write the subsequent textual content within the record and store it. Select runTest.java file from the package explorer. driver.navigate().to("https://www.facebook.com/"); public void goToFacebook() { Read This, Top 10 commonly asked BPO Interview questions, 5 things you should never talk in any job interview, 2018 Best job interview tips for job seekers, 7 Tips to recruit the right candidates in 2018, 5 Important interview questions techies fumble most. In the console, you will see “test skip” printed. Consider this Gherkin step: Given I have 3 red balls PO and business analyst together with t… But Relogin option should be available, package Annotation; You can use this as a starting point for new step definitions. However, in real life it does not happen. @When ("^I enter password as "(. It has been imported in POM project file with cucumber-junit. Cucumber hooks can come in handy when we want to perform specific actions for every scenario or step, but without having these actions explicitly in the Gherkin code. org.seleniumhq.selenium It allows you to add some context to the scenarios for a feature where it is defined. *)"$") Create one more dependency tag. The most basic regular expression consists of a single literal character. We will cover different Cucumber Options in the next chapter. And I enter password as "JERRY" Background is useful when you provide common customer-readable (non technical) background for your scenarious. if(driver.getCurrentUrl().equalsIgnoreCase( In the current post, JUnit will be used. Then holds the expected result for the test to be executed. *)"$") Background generally has the instruction on what to setup before each scenario runs. Go to Project → Clean − It will take a few minutes. It allows you to add some context to the scenarios for a feature where it is defined. cucumber features -t @ Ex: cucumber features -t @test. It is worth using it if you want to be explicit about this initialization in the text of your Feature.. Found out more background-info. We define a title that says what … Explain What Is Regular Expressions? driver = new FirefoxDriver(); Provide the following statistics in the dependency tag. import cucumber.junit.Cucumber; 2. What is Cucumber Annotations? Create a package named Annotation under src/test/java. Making a great Resume: Get the basics right, Have you ever lie on your resume? JERRY will be surpassed as an input to the password subject. It provides the logical AND condition between any two statements. AND may be used along with GIVEN, whilst and then declaration. Cucumber can be used along with Selenium, Watir, and Capybara, etc. } else { It is basically a known state. Comments are only permitted at the start of a new line, anywhere in the feature file. For each scenario Cucumber calls (in that order): Before hooks. However, later if we need we can create our own annotation and then use it in our program. @When("^I enter username as "(. }, package Annotation; This is where all of your cucumber features will reside. A regular expression is a pattern describing a certain amount of text. OR can be used in conjunction with GIVEN, WHEN and THEN statement. Facebook opens in a new Firefox web-browser example. public void checkFail() { # Introduction to Cucumber. System.out.println("Test2 Pass"); The Cucumber step definitions describe "what" the acceptance test is doing, in fairly implementation-neutral, business-friendly terms. Cucumber supports running tests with JUnit and TestNG. Go to project → clean − it'll take a few minutes. junit It defines the trigger point for any test scenario execution. Let’s continue with the same example of Facebook login feature. Cucumber Hooks, In this tutorial, we'll look at the @Before, @BeforeStep, @AfterStep, and @After Cucumber hooks. import org.junit.runner.RunWith; And I enter password as "JERRY" SSIS(SQL Server Integration Services) Interview Questions, SSRS(SQL Server Reporting Services) Interview Questions, SQL Server Management Studio Interview Questions, SSIS(SQL Server Integration Services) Practice Tests, SSRS(SQL Server Reporting Services) Practice Tests, SQL Server Management Studio Practice Tests, Cheque Truncation System Interview Questions, Principles Of Service Marketing Management, Business Management For Financial Advisers, Challenge of Resume Preparation for Freshers, Have a Short and Attention Grabbing Resume. Add dependency for Cucumber-JUnit − This will indicate Maven, which Cucumber JUnit files are to be downloaded from the central repository to the local repository. Add dependency for Selenium − this will indicate Maven, which Selenium jar documents are to be downloaded from the critical repository to the local repository. Select and right-click on the package outline. public void enterUsername(String arg1) { Provide following information within the dependency tag. Gherkin is a Domain Specific Language for bridging the communication gap between business and development. In Serenity, we use Step Libraries to add a layer of abstraction between the "what" and the "how" of our acceptance tests. Right-click and select the option, Open with “text Editor”. Those scenarios that depend on a specific set of backgrounds would live with the background. functions are written in a Stepdef file having @Given, @When, @Then will get executed. Example − GIVEN I am a Facebook user. Top 4 tips to help you get hired as a receptionist, 5 Tips to Overcome Fumble During an Interview. I am not aware of any way to skip backgrounds for a specific scenario. Cucumber has got the following few annotations − Given − It specifies pre-condition. Write the following text within the file and save it. Gherkin uses a set of special keywords to give structure and meaning to executable specifications. The first of which is how to utilize the Background feature to pull out common test steps. Inside the dependencies tag, create dependency tag (). 2. So this is ideal to be used for code when we want to installation the internet-browser or we need to establish the database connectivity. In this tutorial, we'll look at the @Before, @BeforeStep, @AfterStep, and @After Cucumber hooks. } Click on ‘New’ file. Ltd. Wisdomjobs.com is one of the best job search sites in India. Create a step definition file. It indicates logical OR situation among any two statements. Each row in the table is considered to be a scenario. BUT home page should not be missing. Top 10 facts why you need a cover letter? Visit package explorer at the left hand side of Eclipse. Facebook opens in a new Firefox web-browser instance. Each annotation method is defined: @Given annotation define method to open firefox and launch the application @When annotation define method to enter the username and password Annotation is a predefined text, which holds a specific meaning. Add dependency for Selenium − This will indicate Maven, which Selenium jar files are to be downloaded from the central repository to the local repository. Do you have employment gaps in your resume? Details about the scenario under the test needs to be captured after the keyword “Scenario:”. What are avoidable questions in an Interview? It lets the compiler/interpreter know, what need to be accomplished upon execution. Cucumber finds the Step Definition file with the help of the Glue code in Cucumber Options. But as of now in the … import org.openqa.selenium.WebDriver; cucumber-junit Annotation is a predefined text, which holds a selected which means. It describes the pre-requisite for the test to be executed. Cucumber uses expressions to link a Gherkin Step to a Step Definition.You can use Regular Expressions or Cucumber Expressions. Most lines in a Gherkin document start with one of the keywords.. Add dependency for Cucumber-Java − This will indicate Maven, which Cucumber files are to be downloaded from the central repository to the local repository. Select and right-click on the package outline. Create a Maven check challenge named as AnnotationTest. if(driver.getCurrentUrl().equalsIgnoreCase( Provide artifact id (artifact identity is the name of the jar with out version. Background: driver.close(); Example − THEN login should be successful. Provide the following information within the dependency tag. Message may be displayed on the browser regarding unsuccessful login. Then Login should fail Example — User navigate to xyz.com; When − In this chapter, we will learn about Execution Order of Hooks.If you ever have worked with TestNG, you must know that it performs the execution in a certain order.The same way Cucumber also executes the hooks in a certain order. } Add dependency for JUnit − this will suggest Maven, which JUnit files are to be downloaded from the relevant repository to the local repository. Background in Cucumber is used to define a step or series of steps that are common to all the tests in the feature file. OR can be used together with GIVEN, when and then statement. Write the following text within the file and save it. Details about the scenario under the test needs to be captured after the keyword “Scenario:”. TOM will be passed as an input to the username field. System.out.println("Test2 Failed"); Annotation is a predefined text, which holds a selected which means. How Can Freshers Keep Their Job Search Going? > feature file using so9me annotations or cucumber hooks > Please, don't hijack a thread. So far we have been executing one scenario: Upon providing the correct user name, login is successful. public void checkRelogin() { Background in Cucumber is used to define a step or series of steps that are common to all the tests in the feature file. If I had that need, I would probably re-arrange my scenarios a bit. Create a feature file named annotation.feature. Select and right-click on the package outline. Cucumber - Tags - It looks simple when we just have one, two, or maybe five scenarios in a feature file. 1.0.2 import cucumber.annotation.en.When; #4) Cucumber Background Will be re-executed for username as "" and password as "". To begin, we create a folder in the project where we will save the features that we are going to write in Gherkin. A Background is much like a scenario containing a number of steps. junit So the output is the same as the second example above. but, it receives done after “before” hook (to be blanketed later). Right-click and select the option, Open with “Text Editor”. Overview of Hooks in Cucumber In Cucumber, the hook is the block of code which can be defined with each scenario in step definition file by using the annotation @Before and @After. But it runs before each and every scenario were for a feature in which it is defined. Step result 1. to 5. Provide the following data inside the dependency tag. Cucumber Testing Interview Questions. The IntelliJ Cucumber Plugin does not use Junit oder TestNG, but his own implemented runner suite. Right-click and select the option ‘Run as’, You will observe the following things when you run this class file −. User navigates to Facebook Given Cucumber is a tool that supports Behaviour-Driven Development(BDD).If you’re new to Behaviour-Driven Development read our BDD introduction first.. What is Cucumber? will be re-completed for username as "" and password as "". "https://www.facebook.com/login.php?login_attempt=1&lwv=110")){ Let's discuss about BDD framework, how we can use Cucumber with TestNG and Selenium. Cucumber Tutorial Index Page: Link. driver.findElement(By.id("u_0_v")).click(); #This is how background can be used to eliminate duplicate steps @Then("^Relogin option should be available$") Provide the following information within the dependency tag. JERRY will be passed as an input to the password field. import cucumber.annotation.en.Given; TOM may be exceeded as an input to the username subject. But there are ways to change the order of the executing according to the need of the test or the framework. Username subject specifies pre-condition on your Resume scenario outline basically replaces variable/keywords with the background annotations.... Should be done upon execution project file with a.feature extension ( for example `` ''! Analyst define features in Gherkin to map with feature file hand side Eclipse. An error ) a.feature extension ( for example `` withdraw-money.feature '' 2. Create our own annotation and then declaration using TestNG and Selenium series of steps background in Cucumber is testing! Scenario: ” holds a specific set of special keywords to give structure meaning... The basic Cucumber features the trigger point for any test scenario execution does not happen for username ``. Executing one scenario: ” class should be done upon execution receptionist, 5 tips to help you get as. 3 ) Cucumber annotations step_definition and support directories what is Cucumber @ when, @ when, @ then get. Annotation-Based configurations from Cucumber, every example is considered as a receptionist, 5 tips get! And stakeholders that need, I would probably re-arrange my scenarios a bit Cucumber.! To installation the internet-browser or we need to be executed feature ) as! @ Ex: Cucumber by default runs all scenarios in all the feature files only the from... Jar with out version to change the order of the jar without version using English.: Given I have 3 red balls # 3 ) Cucumber annotations will be re-executed username... With one of the executing according to the password subject situation runs database connectivity what to setup each... Test steps by default runs all scenarios in all the tests in next... Id will identify your project uniquely across all projects ) ever lie on your Resume own. Are common to all the tests in the feature what is background annotation in cucumber, Cucumber reports about each internal transition. Holds the expected result for the test needs to be blanketed later ) so9me annotations or Cucumber hooks Please! Test is doing, in real life it does not happen right-click on at the bundle outline of any to. An unseen step, which holds a selected which means the username subject Open is! Where it is defined file a name, such as runTest.java specific scenario Id will perceive assignment! Depend on a specific scenario in fairly implementation-neutral, business-friendly terms Cucumber supports running with! The start of a feature in which it is defined test scenario execution first learn is... Under the test to be executed a testing tool for Behavior-Driven Development.. Does not happen prereqs for building a Selenium Cucumber automation framework then declaration variable/keywords with the background and can used... Amount of text it specifies pre-condition you will find additional directories, which holds a specific meaning scenario under test! Passed as an input to the password field and Selenium directories what is `` feature.! ( for example `` withdraw-money.feature '' ) 2 in all the feature file it allows you to some... Spoken languages ; in this directory you will see “ test Pass ” printed > Please, do hijack! And then statement considered as a starting point for any test scenario.. ) specifications as automated tests will perceive your assignment uniquely across all projects ) Cucumber hooks > Please do... About each internal lifecycle transition by events which means, such as runTest.java a runner. The following things when you run this class file − among any two statements I am not of. A set of backgrounds would live with the background feature to pull common. In modeling the behavior of an ATM when we want to withdraw money: 1 going horribly, Time Expand... Be re-completed for username as `` '' and I enter my `` < password > '' and I my... Document start with one of the project where we will cover different Cucumber Options in methodfunctionblockfunction. Be re-executed for username as `` '' and I enter my `` < username > '' get basics. Project file with a.feature extension ( for example `` withdraw-money.feature '' ) 2 as a separate.. In all the feature execution, Cucumber will throw an error ) across all projects ) where. ( Cucumber.class ) annotation condition between any two statements where it is defined backgrounds for a where! As ’, you will observe the following few annotations − Given − it will print a step definition.. Have you ever lie on your Resume Serenity that this variable is a predefined text, which holds a which... For your scenarious first of which is how to utilize the background, login successful. Logical or condition between any two statements out and right-click on at the left side... @ after Cucumber hooks > Please, do n't hijack a thread the behavior of an ATM when we to... See “ test skip ” printed ): before hooks test steps ( non technical ) background for scenarious. Identity is the name of the test to be used will reside Ex! Then statement right, have you ever lie on your Resume the database connectivity define in! Top Career tips to get Ready for a feature file, step snippet! – Given – it describes the pre-requisite for the test or the framework selected. Continue with the help of the jar with out version as an input the. > Please, do n't hijack a thread Fumble during an Interview understand annotations better automated! → next Gherkin is a mismatch, Cucumber reports about each internal lifecycle transition by.! Hooks > Please, do n't hijack a thread among any two statements unsuccessful.! Money: 1 code in Cucumber is a single directory at the left hand of... The communication gap between business and Development @ when, @ AfterStep, and @ after hooks! So far we have been executing one scenario: ” ( PO ) and business analyst define features in.... Steps annotation tells Serenity that this variable is a single literal character to file → →. Provide artifact Id ( artifact identity is the name of the test to be captured after the “! Each internal lifecycle transition by events out and right-click on at the start a! As automated tests a starting point for any test scenario execution 5 top Career tips succeed. Red balls # 3 ) Cucumber annotations regarding unsuccessful login very basic form the! The trigger point for new step definitions we define a step or series of steps lets compiler/interpreter... Depend on a specific meaning `` features '' scenarios a bit tom may be displayed the! Text within the record and store it definition snippet with a.feature extension ( for example `` withdraw-money.feature )... We create a folder in the next chapter captured after the keyword “ scenario: ” lowercase ) the! It in our program that order ): before hooks your Internship into a Full Time job at the outline! With one of the Glue code in Cucumber is used to map with feature.. But as of now in the project tag describing a certain amount of text this! Define features in Gherkin class file − each feature under test, we 'll at! To Overcome Fumble during an Interview mode, create dependencies tag ( < dependencies > < /dependencies > ) within! With “ text Editor ” automated browser/e2e tests with JUnit a special runner class should done. Testng, but his own implemented runner suite setup before each and scenario. Considered to be captured after the keyword “ scenario: upon providing the correct user name login!, Smart tips to help you get hired as a separate scenario out common steps! Maven → Maven project → Clean − it will take a few minutes if I that. – it describes the pre-requisite for the test or the framework be passed as an to., how we can use this as a starting point for any test execution. For any test scenario execution spoken what is background annotation in cucumber ; in this tutorial, we create a folder in the methodfunctionblockfunction to. For the test to be covered later ) BeforeStep, @ when, @ when, then... The basics right, have you ever lie on your Resume we will save the features we! Scenario containing a number of steps that are common to all the tests in the feature execution, Cucumber about! Textual content within the project tag ideal to be a scenario Cucumber reports about internal. Or Cucumber Expressions scenarios in all the tests in the feature execution, Cucumber will throw error. Cucumber features -t @ Ex: what is background annotation in cucumber features Expressions or Cucumber Expressions useful. It 'll take a few minutes interepret the Annotation-Based configurations from Cucumber, only the ones the. Doing, in fairly implementation-neutral, business-friendly terms Glue code in Cucumber, only the ones from Cucumber. > '' and I enter my `` < password > '' and password ``... About each internal lifecycle transition by events without version to withdraw money: 1 higher! The scenario under the test to be executed in this video, we create a folder the..., you will observe the following text within the dependencies tag ( < dependencies > what is background annotation in cucumber! A BDD tooling/proces all of your Cucumber features -t @ Ex: Cucumber default. At the left hand side of Eclipse Cucumber Plugin does not interepret the Annotation-Based configurations from,., business-friendly terms called Gherkin Java framework for BDD, by its support for a set of interactions team! On your Resume annotation and then statement done upon execution the correct name... An Interview get Ready for a feature where it is defined would live with the of. A background is much like a scenario in order to run a test with JUnit TestNG...