Member-only story

My Innovative Solution to Test Automation: Keep the Browser Open after Executing an Individual Test

Two Execution modes: an individual test → keep the browser open; all tests in one test script file → close the browser as normal

Zhimin Zhan
7 min readMay 18, 2022

This is included in my “My Innovative Solution to Test Automation and Continuous Testing” series.

Table of Contents:
· Background
· The Problem
· First Solution
· Improvement
· Three Important Lessons I learned
· FAQ

Background

I started Automated UI Testing with JWebUnit in 2005 (learned from a world-renown programmer). I used IntellijIDEA, my favourite Java IDE, to develop and run tests. The automated functional tests were very similar to unit tests in many ways:

  • Headless, unable to view actual test execution in browser
    (it is actually simulation, not real browser rendering)
  • In the JUnit syntax framework

As a programmer, I took it for granted. One day, I showed (with pride) the execution of one test to a manual tester; the poor tester was confused. He asked: “Where is the execution?” At that moment, I realized that headless testing was not good simply because it was not convincing to everyone.

Then, I found out Watir, a true web test automation framework that can drive an IE browser.

Tip: The test scripting language does NOT need to be the same as the language your developers are using.

One problem, Watir is in the Ruby language. There was no IDE (that I was aware of) like IntellijIDEA. I decided to create my Testing Tool (iTest2, renamed to TestWise later) in my spare time. Frankly, I did not have much hope for it. Rather, it was a pet project to practise my Ruby programming. (I was so happy to discover Ruby, after programming Java for nine years. TestWise v1-v4 was coded in Ruby; TestWise 6 is coded in C++)

When I started using the initial version of my tool at work, frankly, I was a bit embarrassed by its poor and simplistic user interface. To my surprise, one business analyst liked it. He said: “It is simple”. By watching him using iTest2, I got some ideas for improvements.

--

--

Zhimin Zhan
Zhimin Zhan

Written by Zhimin Zhan

Test automation & CT coach, author, speaker and award-winning software developer. Help teams succeed with Agile/DevOps by implementing real Continuous Testing.

Responses (1)

Write a response