How to use Hiptest publisher executing test scripts using selenium webdriver - selenium

I have written scenario using gherkins keyword and exported the script using Java/TestNg framework, now I have zip file containing actionword, project test and yml config file. Now I want to run my script through selenium web driver but I am not able to do so as I have done whatever mentioned in https://github.com/hiptest/hiptest-publisher#hiptest-publisher and some post but I'm stuck. Can anybody please help me how to run scenario using selenium webdriver by Step By Step, it would be grateful as I am just a beginner in both selenium and hiptest and my project looking into Hiptest for automation.

Related

Selenium IDE - exporting test scripts

I'm trying to export my test automation created in Selenium IDE, but I can't find the option to export. I have a few test scenarios where the tests are the same but I need to make a copy of an existing test and swap some IDs for it to work.
I can only save it as a .side file and not as individual Python scripts for Selenium. I'd like to export an existing script and re import it into Selenium IDE as a copy (where I can make some changes, while keeping the majority of the commands the same).
My Selenium IDE looks like this:
How can I export my test scripts (to Python) or how can I make a copy of an existing test script inside Selenium IDE (ex. make a copy of UAT FCC-A Application, such that it makes another Test with all the same commands)?
I'm on Chrome.
You have Export option on Selenium IDE
But only Java JUnit at the moment.
I hope that helps.
The newest Katalon Recorder (Selenium IDE for Chrome) has covered the feature of exporting test script to Javaļ¼ŒC#,Python 2,Ruby and so on.
Followed is the link to view these features.
Katalon Automation Recorder Quickstart

Can we execute/trigger selenium automation scripts through UFT

Using Webdriver, I have automated web based Application in eclipse and using QTP, I have automated Power Builder application(like desktop App).
Now both become depended module for me, from PB data's are flowing to web base application.
so, how can I achieve this. please someone provide me how to proceed with situation and give me some strategy to proceed
We have exactly the same situation where powerbuilder application is integrating with the web application, below is the solution we have followed
We are using jenkins for executions, but this can be done without jenkins also.
We have one jenkins job which executes a UFT test first and then executes the selenium test if UFT test is successfull.
At the end of test execution UFT test will generate a file with the information required by selenium test and then jenkins will trigger selenium test, selenium test will read this file to gather any required information.
Results are interpreted in the following way
If UFT test fails then jenkins will not trigger the selenium test. If the whole jenkins job is executed successfully then integration is working, if the UFT part failed then Powerbuilder is having issue and if selenium part failed then web application is having issue.

Build selenium-server-standalone executable jar

I did a patch in the HtmlUnitDriver.java file, as explained here:
Is it possible to ignore JavaScript exceptions when working with WebDriver (HtmlUnit, Ruby bindings)
I've followed the explanations on the selenium build wiki and in the readme, also the tip given here:
Building the Selenium Server Project
Still, I don't have a jar file like selenium-server-standalone-2.25.0.jar which can be run and used as a headless browser for selenium tests.
... So I'm trying to recreate the selenium-server-standalone-2.xx.jar file with my patch, and use it to run my headless tests.
Can anyone explain to me how to do this? Thanks!
The best way I found is to do:
go //java/server/src/org/openqa/selenium/remote/server:server:uber //java/client/src/org/openqa/selenium:client-combined:uber
This will create a single jar for the selenium server
Then run go release.
The resulting .jar should be found in build\dist folder of the selenium source folder. (ex. ./build/java/server/src/org/openqa/grid/selenium/selenium-standalone.jar)
See also https://github.com/SeleniumHQ/selenium/wiki/Building-WebDriver#tips.
Here is a step by step building guide for selenium standalone server. The build process of selenium projects may be not so strait forward to newbies, so I recommend this detailed guide on how to create a runnable standalone jar.
http://shengwangi.blogspot.com/2014/08/how-to-build-selenium-from-source.html
Also you can refer to the official document on build selenium.
https://code.google.com/p/selenium/wiki/BuildingWebDriver#Building_Selenium_Server

Using selenium grid to execute remote code

We looking to use Selenium grid to parallelize our tests but some of our tests need to run java code local to the testing machine. In other words as well as automating the browser we also need to run some java code on the test machine. Are there hooks in Selenium Grid that will allow us to do this?
PS we are also looking at Jenkins to setup our environment.
EDIT: To be clearer, the java code I need to execute does a get from the web application, downloading pdf files that we cannot do with selenium alone. It then does some processing on those PDF files. I suppose the processing could be done on the server hub but the downloading can't. Unless someone can explain how to download a pdf using selenium and save it to a given location?
Selenium cannot execute your java code in the remote control machine. It will get executed only in the hub machine. However, taking screenshot, deal with popup, uploading the files in a specific path can be taken care by Grid.

Unable to use few Selenium commands while writing scripts

There are some Selenium commands that I am unable to use in a script that I'm writing and I do not have any idea as to whether I am missing an import of required library files or packages.
For example - selenium.browserbot, selenium.waitForElementPresent.
I am using Selenium IDE to record the script and working in Eclispe Junit platform.
Use isElementPresent instead of waitForElementPresent.