Hot answers tagged

4

Get rid of the trailing backslash and especially the trailing semi-colon: C:\Program Files\Java\jdk1.8.0_91 By the way, you can display the current setting with the shorthand of typing "set" at a command prompt followed by the minimal number of characters needed, i.e. on my system: set j JAVA_HOME=C:\Program Files\Java\jdk1.8.0_144


3

This is what you use Maven for. Maven manages and downloads your dependencies. Suggest you try to always use the latest stable version of Maven and you should be set. Example pom.xml: <dependencies> <dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> <version>4.10</...


3

Steps to install Maven: Install JDK and add path of JAVA_HOME Download Apache Maven Add M2_HOME and MAVEN_HOME Add To PATH Modify your System variables: Add both M2_HOME, JAVA_HOME and MAVEN_HOME variables in the Windows environment, and point it to your Maven folder. MAVEN_HOME :: C:\Users\hari\Downloads\apache-maven-3.3.9 JAVA_HOME : C:\Program Files\...


3

make sure you are importing org.testng.annotations.Test and not org.junit.Test


2

Take a look at Karate which easily integrates into a standard Java / Maven project. You can actually generate the standard JUnit XML report format which most CI tools understand. Or you have the option of integrating 3rd party reports via Maven. The test execution is via the Maven surefire plugin. And yes, Karate has excellent support for SOAP and XML. ...


2

It cant find your driver. You need to download the driver from here: https://www.soapui.org/jdbc/reference/jdbc-drivers.html and then save the .jar file to your c:\Program Files\SmartBear\Soapui5.x\lib folder. Then you should be ok.


2

Regarding question 1: You could give the Warnings Plugin a try. Regarding question 2: Configure your SonarQube project, to have a Leak Period since "previous build" The SonarQube Leak Period specifies the time frame of your usual development cycle. Quality Gate conditions can be specified to be specific to that time frame, to enforce your quality to "get ...


2

Solved File --> Settings--> Editor --> Inspection And Check all the options in Cucumber like following


2

@Mahesh, I have below suggestions:- # Solution 1 Go to your eclipse installation folder Run "eclipse.exe -clean" # Solution 2 Uninstall Netbeans because Eclipse and Netbeans are both might using the same workspace # Solution 3 Right click project, remove maven nature (or in newer eclipse, "Maven->Disable Maven Nature") mvn eclipse:clean (with project ...


2

The testng.xml should be located in your test resources. That way the testng.xml will be copied. You can also configure surefire plugin to explicitly run testng suite xml files. Should your maven plugins be configured as plugins not dependencies? Also seems like you should have other dependencies in test scope as well. Be sure to check that your test ...


2

You can add libraries to "lib/ext" folder as follows: <configuration> <jmeterExtensions> <artifact>kg.apc:jmeter-plugins-casutg:2.4</artifact> </jmeterExtensions> </configuration> Replace kg.apc:jmeter-plugins-casutg:2.4 with your own artifact in form of: groupId:artifactId:version References: Guide to ...


2

If you want to build so callled "fat jar" - a single executable .jar containing all dependencies and invoking TestNG main class I would recommend going for Maven Shade Plugin: Remove the following lines from your pom.xml <scope>provided</scope> Add the following Maven Shade plugin definition to create an executable jar: <plugin> <...


2

The initElements method second argument should be a page class, you feed it the driver. I think you should change the constructor of Homepage_ReCheck_Search to: PageFactory.initElements(driver, this); The search_box never gets initialized, because you do not init a page. Thus the search_box stays NULL its default value. Meaning you cannot interact with it.


1

You don't need to amend anything in pom.xml file, the changes need to be introduced in JMeter Test Plan, to wit: Add Backend Listener to your Test Plan Choose org.apache.jmeter.visualizers.backend.influxdb.InfluxdbBackendListenerClient as the "Backend Listener Implementation" Change influxdbUrl parameter to match your InfluxDB setup That should be it, ...


1

Delete .m2 folder which contains all the dependencies form your user-home.Then re-build your package using "mvn clean package" command.All your dependencies will be removed and when you run a maven project ,the required dependencies will get downloaded and again stored in your local repository(.m2).


1

You can do Data-driven testing using these, Scenario Outline with Examples keyword Using external Files: Excel, Json, XML For more details check below links: 1. Data-driven-framework-with-excel 2. Adding_source_to_gherkin_script


1

There is a feature called Scenario Outline for data driven tests in cucumber. It can be used in this scenario to pass different user/passwords as data to the test as parameters.


1

you can read the topic about enums and interfaces in Java. Maybe it will help you to create something as you want. There are a lot of decisions. The xml file can be created with different accounts as well then you pass it through your Interfaces, Classes and etc. <users> <user> <lastname>John</lastname> <...


1

As far as I know, the only tool that allows you to run in parallel something written in robot framework is pabot. Things you should know: Pabot will split test execution from suite files and not from individual test level. The order of tests execution in each suite file is sequential and you can't randomize The only way to parallelize each test is to use ...


1

mvn clean means you're executing the clean phase of maven which would not run any tests. You should probably try test or verify, e.g. mvn clean verify. More to read: https://maven.apache.org/guides/introduction/introduction-to-the-lifecycle.html


1

You are right that pabot is the way to do this unless you want to hack robot internals, you just have to find a way to have it run outside maven. I would do this by configuring Jenkins to preserve the artifacts from the maven build and then trigger another job that runs pabot against those artifacts. Another benefit of this approach is that you can easily ...


1

I assume you're talking about java You wouldn't be able to achieve your goal without writing some extra code. Below is the example of how you can to that: Example pre-conditions: your property file is called "test.properties" the property that you want to take is called "somepropname" environement variable you want to take propertyvalue from is "some-prop-...


1

I hope -D option will help to some extent. But directly java won't interpret the environment variables. You need to handle it. The below link have more insight on implementation of the similar option. https://stackoverflow.com/questions/2263929/regarding-application-properties-file-and-environment-variable


1

Maven Surefire plugin can handle any tests written with JUnit or TestNG. This means whatever your JUnit/TestNG are doing, including SOAP Web servce testing, they can be run with Maven Surefire plugin. Maven Surefire can be used in CI environment (e.g. Jenkins). You just define your CI job with mvn test to execute tests.


1

You forgot to connect to the channel, e.g. channel.connect(); Then you need to read the response. There is an example at http://www.jcraft.com/jsch/examples/Exec.java.html InputStream in=channel.getInputStream(); byte[] tmp=new byte[1024]; while(true){ while(in.available()>0){ int i=in.read(tmp, 0, 1024); if(i<0)break; System.out....


1

This is my favorite getting started guide for maven and Jenkins, it is with selenium, but should also work with soapui java code. http://www.guru99.com/maven-jenkins-with-selenium-complete-tutorial.html


1

Change @RunWith(StepDefinition.class) to @RunWith(Cucumber.class). The Cucumber runner needs to run with a class that extends Runner.class; StepDefinition.class does not extends Runner.class.


1

Beside Jenkins, there are other CI tools. In this article - Jenkins vs other Open source continuous integration servers - you may find the quick review of the top Open source CI tools. And although the review in this post is made from the performance testing perspective, these tools are used for the integrating Selenium tests into the continuous integration ...


1

Maven is most used as build and dependency management tool. The pom.xml is its configuration file, which also contains the dependencies. Apache Maven is a software project management and comprehension tool. Based on the concept of a project object model (POM), Maven can manage a project's build, reporting and documentation from a central piece of ...


1

As Niels noted, it might not actually be using a headless driver, it's probably just not running under your main desktop environment. This will happen when using Task Scheduler if you don't have the correct Security options on the General tab of your task properties. They should look something like this: If you set those options differently you won't be ...


Only top voted, non community-wiki answers of a minimum length are eligible