< script src="https://unpkg.com/@highlightjs/cdn-assets@11.0.0/highlight.min.js">

Tech Blog

Facebook Icon Twitter Icon Linkedin Icon

AnyMind Group

Facebook Icon Twitter Icon Linkedin Icon

[Tech Blog] How to automate using UIlicious

Hi! I am Alyssa Andrea, QA Engineer of the engineering department at Anymind Group.

I’ve been a manual functional tester for 5 years. Unparalleled in my abilities to find those crazy bugs and the only happy (not sure about devs) on the team to find them. I like doing regression testing of a whole project although I run into problems doing the same job every time. So, I’ve looked for a tool that will help reduce the repetition of the work. It’s called UIlicious.

Oh cool Automation!

The questions are: Do I know how to code? No. But this tool doesn’t need you to know the complexity of programming languages which most QAs are afraid of “coding”.

Would you repetitively click multiple times and fill in different fields when creating new users when doing regression testing or make a script and click once and do something else?

I think this is where automation would help us. Let me show the basics:

To begin with, UIlicious runs from Javascript underneath. Let me guide you through a simple login functionality using UIlicious:

A sample cool project called AnyFactory

A sample script where the user can login:

// Given that user is in the login page
I.goTo("https://crazydeveloplinkhere.com/");
I.fill("Email", "myprivateworkemail.com");
I.fill("Password", "somebasicpass123");
I.click("Log in");

Let’s get complicated and note that it can be a powerful tool too if you can code: In this scenario, let’s create a function where an admin user logs in and creates another user.

Creating cool functions:

  • Set up variables so the user doesn’t have to input email and password everytime
  • Added function LOGIN that we will call in different test cases

Login Function 1.1 (login_as_admin)

// Login function as admin
// Your variable here
LOGIN = {
  userLogin fuction() {
    // Given that user is in the login page
    I.goTo("https://crazydeveloplinkhere.com/");
    I.fill("Email", "myprivateworkemail.com");
    I.fill("Password", "somebasicpass123");
    I.click("Log in");
  }
}

How to call Login Function 1.1 First, we have to import the function here:

// For importing function
TEST.run("Functions/login_as_admin")

Second, call the function login:

// For importing function
TEST.run("Functions/login_as_admin")
// Login as admin
LOGIN.userLogin()

Third, add the script where the admin user can add another user: This would be the way the user navigates to the User module and creates a new user.

User module list

Creating new User

In these images, we create a script that will navigate users from the user list and create a new user:

// Creating User
I.goTo("https://staging.app.any-factory.com/users");
I.must.see("+ Add User"); // Validation if button text translation is showing correctly
I.click("+ Add User"); // Clicking the button

User module list sample script

// Fill user field and create new admin user
I.select("Admin");
I.fill("First Name", "New");
I.fill("Last Name", "User");
I.fill("Email", "newuser@sample.com");
I.click("Country");
I.click("Thailand");
I.click("Create");

Creating new User sample script

To be honest, for me automation and manual testing has its own pros and cons. Here are some:

Automated Pros:

  • Can help find more bugs
  • It can increase speed and accurate testing in regards with results
  • Processes are recorded and allows to reuse and perform the test/s in daily basis

Automated Cons:

  • Difficult to check the UI colors, sizes, fonts and button sizes.
  • Test maintenance and tools might be expensive and increase the cost of the project.
  • It has limitations which lessens the scope of automation.

Manual Pros:

  • Can get fast and precise feedback in terms of UI
  • Less expensive
  • Not time consuming compare to automation that requires coding

Manual Cons:

  • More open to errors where tester can missed
  • It cannot be re-use. Tester can only track by defect or project management tools
  • Requires more time

It also depends on the product/project you are working on. The latter, the UI always changes to that means we also have to change/update the script we made and test it manually.

From the examples above, I may not be an expert but I think doing some simple scripts and exploring the different automation tools would make our QA lives easier, better and more productive. To add, UIlicious is not the only tool that can help us. We have selenium, katalon and many more.

Latest News