How to run UFT script without having UFT installed - vbscript

I want to know whether is there any way to run script written in UFT without having UFT installed in your PC.
Can we export Script to some .vbs or .exe file? Or is there any alternate way through which we can execute scripts?

If you had developed the scripts using Object hierarchy, then you cannot run it without UFT. Scripts having only VBScript commands can be executed as .vbs, but we cannot do activities on Objects then.
But you can run UFT in Remote Desktop by providing it as parameters in 'CreateObject("Quicktest.Application",Remote Ip)'. Other than this, it is not possible to execute a UFT script outside UFT.

You can't execute scripts without UFT installed. That being said, from UFT 12.50 onwards, HP is providing a standalone component called as "Run Time Engine". Here is the snapshot.
The HP Unified Functional Testing (UFT) Runtime Engine is a core component
of UFT which enables you to run various tests (GUI, API and BPT) in functional
testing. In previous UFT versions, this feature was only available with the full
UFT installation. However, beginning with version 12.50, you can use the Runtime Engine as a standalone installation option for your automated testing environment.
Reference

Definately possible.
UFT has introduced a new feature called LeanFT . It just requires installation of LeanFT jars and requires a method to call them

You now can with the UFT Runtime Engine. More information can be found at this link.
From that site:
The UFTRuntime Engine enables you to run UFT tests (both GUI and API)
and business process tests on your computer without installing the
entire UFT IDE. In addition, you can also install the Runtime Engine
without the Run Results Viewer, UFT Add-in for ALM, sample
applications, or Help documentation. This can potentially save you
valuable disk space on your computer

You need UFT 14 v or above to make it use.
UFT 12 doesn't have that this feature

Related

Jenkins GUI Automaion script execution

I am new to Jenkins. My query is
What I am trying to achieve.
1) We have automation framework (GUI kindoff). Which will trigger UFT / Selenium Scripts.
2) I have installed Jenkins.
3) I need to run some batch commands which will execute UFT scripts via built in framework.
4) When running via command line I am able to trigger scripts (UFT).
5) From Jenkins I am not able to run GUI commands.(It should trigger my framework and start UFT script execution)
Please note:
Build is success. I am doing all this from Master Jenkins. no slave machine.
Is it necessary to have slave machine to run GUI
I tried almost all settings by searching google.
Please help.
thanks in advance.
Abhijit
if you are using webdriver in your selecium script thats requires UI to be success than you have to consider using Slave which will have UI support and you need to connect there via Xvnc or something similar
if you are using webdriver which does not require UI (for example google chrome headless) then there should be some miss configuration in jenkins side, therefor to help you figure it out you need to provide more details

How to write a program to run same script using multiple external tools in eclipse

I write automated tests. We have different environments we run the tests in for different customers that we provide the same services to before they can be pushed to out automated testing servers. To ensure a test is working we need to run the tests using different external tools in eclipse each time and record and report on it passing/failing. To do this we need to click the green play button with the red toolbox and select an external tool individually each time.
I'm looking for a way that I can write a script that will let me specify which external tools to run the test with and then it'll run the test over and over with the different tools and output some kind of report. I'm not familiar with this kind of thing so any kind of direction would be a huge help.
I'm using Eclipse Keplar on Ubuntu 16.04. The test is a ruby script.
You can use scheduler of ubuntu system and execute shell script command to trigger automation.

Jasmine in windows command-line

How to run jasmine from command-line using a Windows machine ? I have seen jasmine scripts run in Linux. I want jasmine standalone in command-line without phantomjs or any other javascript code that mocks the server(I need jasmine only, if possible with maven).
I'm lost... Assuming the question is "can I run JavaScript on default Windows install, can I run tests with Jasmine this way"?
CScript/WScript will run JavaScript, both a part of default Windows install (I believe starting W2K or WinXP).
You can also compile JavaScript with .Net compiler (JSC.exe) again available on most machines (.Net is not default on WinXP - so may not be present, Windows Vista/7/8 come with a version .Net by default).
Note that JavaScript by itself has nothing to do with browser and both above tools are not going to provide you any support for browser objects. You can run logic code/manipulate files and configuration, output text.
There is some chance that Jasmine can be run from command line without browser objects - try yourself if you goal is running non-browser related JavaScript from Windows command prompt.
There is also option to automate IE and run script there (again default IE may not be latest version - but Windows 8 comes with IE 10 - should be enough for most browser related tests). You should be able to write your own automation framework (similar to Selenium) if needed, even using JavaScript...
Sample JavaScript to run with CScript /nologo launchIE.js from command prompt:
// save as launchIE.js
WScript.Echo("Launching IE to Bing"); // outputs text to console
var oIE = new ActiveXObject("InternetExplorer.Application.1");
oIE.Visible=1;
oIE.Navigate("http://www.bing.com");

What solution exists to run installation of applications that have an installation wizard in windows

I am trying to automate the entire process of clicking next , next next .. etc which is needed to install a application on windows. Is this possible ? How can it be achieved ?
I need a software that installs other software on its own, once it is given the installation file.
In what scripting language is it possible to do this ?
If I were to develop such an application myself, where would I need to start ?
Some allow for silent switches, in which case google the software used to create the installer and run it with particular switches from the command line.
If no such switches are offered then the only solution is software that allows automation of windows. AutoIt is great for this as it allows you to click buttons directly, not by automating the mouse, allowing the automation to happen in the background.

How to automatically run a VB6 compiled software as Administrator and in Compatibility mode

We have an ERP application which is built in VB6 and it was running just fine till a few of our customer upgraded all their systems to Win7.
This software is programmed in such a way that it registers a few plugins (found in plugin folder) which are COM based at runtime. Now when the software is run by user without setting Compatibility Mode and Run as Administrator setting it fails and crashes.
I know we can manually set both Compatibility Mode as well as Run a Administrator by right clicking on program executable and then going to its properties. But this looks very unprofessional.
I think there will be some way to tell Win 7 to automatically run a software in Compatibility Mode and Run as Administrator.
Please help me.
Compatibility is an administrative function, not a development or deployment function. It is better to fix the application where possible, especially to remove any requirement for elevation.
There are plenty of tools for investigating the issues so you can correct them. However globally registering "plug ins" at runtime is a nasty one. VB6 component self-registration is always global unless registry virtualization can redirect it. Why not create installers for the plug-ins that can run elevated once during installation?
There are ways to set compatibility less manually, even as part of installation - though Microsoft discourages this. Maybe take a look at:
Compatibility Fix Database Management Strategies and Deployment
However the effort required might be better spent on remediating the problem. Support costs will be less over time.
As the other answers have said, you shouldn't need to run all the time elevated.
If you want to register the plugins after its started (as a normal user), you can use ShellExecute() with the "runas" verb to run regsvr32.exe, or use COM elevation which has been discussed many times before.
You can indicate that an application must run as admin by specifying it in the Application Manifest, which in an xml file that you can either embed or deploy with your application.
Once your application is running with admin rights it should be able to register and load the plugins. You should not need to run in compatibility mode to access the COM plugins.

Resources