Automated GUI Regression Testing Using AI Planning in Docker

Automated GUI Regression Testing Using AI Planning in Docker

Vitaq AI Test Automation Tool does automated GUI Regression Testing Using AI Planning and can be downloaded as a Docker Image.

In order to run Vitaq in a Docker container, you will need to have Docker installed. Make sure it is running you are able to execute Docker commands at a command prompt. If you do not have Docker installed, then please follow the installation guides at the Docker website https://www.docker.com/.

Before we jump into our Docker container and start the Vitaq JavaScript Client and Selenium Server.  We should take a few minutes to show you how easy it is to download and run Vitaq AI in a Docker Container. Let’s see the Vitaq AI installation journey. https://vitaq.io/docs/Appendix6_Docker.html

Working with Docker

1) Vitaq AI comes as a google drive link from where you can download the whole image at once. This download supports MacOS, Linux and Windows. Vitaq AI comes as a compressed tar Docker image file that can be directly loaded into Docker.

2) After Downloading the file, open a Terminal Window. Which for Linux can easily be done by pressing CTRL + ALT + T key from your keyboard. Or by clicking on Open in Terminal on the list displayed on right-clicking of mouse.

3) Now Run Command “docker load -i vitaq_evaluation_4_2_3.tar.gz” inside the folder. Where the vitaq_evaluation_4_2_3.tar.gz is the name of the docker image file you have downloaded using the link.

4) Now Run Command “docker image ls”

5) Now Run Command “docker volume create pgdata”

Docker Run

6) And Then Run Final Command :-

“docker run –name VitaqAI_4_2_3 -p 6080:80 –mount src=pgdata,dst=/var/lib/postgresql/9.6/main –mount type=bind,src=/home/,dst=/host –privileged –shm-size 512m vitaq_evaluation:4.2.3”

NOTE: You are mounting your host disk to the docker image disk at /host and your home directory /home on your Linux machine drive.

If you want to just mount a folder on your host machine, (i.e. where your working directory for Vitaq AI files will be stored, then you can change src:/home/ to /home/<LinuxUserName>/<FolderName>.   In this example, you have to change to your user name (remember: if your Linux user name has space then you have to ‘escape’ the space character) and change to the folder you will store your Vitaq AI files on your disk.)

7) Open your preferred web browser. Make sure it is grown to the full screen and then Navigate to 127.0.0.1:6080. You are now in your Docker Container which has a full release of Ubuntu 1804 desktop.

 

Inside the docker container

8) Go to Programming and select Vitaq Test Automation

9) Now we are able to run Vitaq AI Test Automation Tool Successfully. But To make absolutely sure it is working correctly after installation, let’s check it by trying the Installation test. From the Vitaq AI Test Automation Tool window, use File -> Open which will open the File browser. Click on Home and then the folder examples

 

Once you see the simple installation test Test Activity diagram, click the Vitaq AI run button to make sure Vitaq is auto-generating tests.

Automated GUI Regression Testing Using AI Planning with Selenium, JavaScript and WebdriverIO

10) Now let’s see Vitaq AI do automated GUI Regression Testing Using AI Planning by loading the example AutomationPractice Test Activity. By clicking on File -> Open and navigating to the examples -> VitaqAI_WebDriverIO_WebShoppingApp and selecting AutomationPractice_TestActivity_Part_Four.vtq

This is Vitaq AI JavaScript Test Activity Diagram which uses WebDriverIO and selenium server. So to run it successfully we need to run our Vitaq JavaScript client with WebDriverIO and start the Selenium Server.

For that you need to open a terminal from System Tools, LXTerminal.

Start the Vitaq JavaScript Client with WebDriverIO using the
command: “./vitaq_client.js -w webdriverio”

After starting the WebDriverIO on Vitaq JavaScript client, we now have to start the Selenium Server. For that open another terminal from System Tools, LXTerminal, and run the command “./selenium_server.sh”

Now Click on Run Button present on the top of Vitaq AI and see your Test Activity auto-generating tests. The tool is executing automated GUI Regression Testing using AI Planning. The tests are data-driven WebDriverIO JavaScript test scripts action after action. All driven by the user journey goals in the sequences and Vitaq AI machine learning algorithms.