Home
WSL Homepage - Welcome!
WATiR Scripting Language Overview
Written by Wadud Ruf   
wsl-logo

WSL is a Scripting Language that allows you to easily and quickly write scripts to test web application functionality through Internet Explorer. WSL scripts allow you to automate testing from the UI down. It can be used as a substitute to writing and executing manual test scripts, is designed to be as human readable as possible, and is complimentary to other testing techniques and tools such as TDD, unit testing, manual exploratory testing, performance testing. and tools like Cucumber. WSL can be used to test web applications written in any language.

The main objective of WSL is to lower the barrier of adoption for WATiR as a test tool by non-developers. Ideally testers and user acceptance testers should find it accessible enough to start using it. With this objective in mind WSL has one main guideline -

 

Accessibility, Simplicity and Ease of Use.

 

WSL is not intended to be a silver bullet when it comes to testing, on the contrary, it should be used with all the other good development practices you have at your disposal.

 

wsl getting started

 

WSL is an internal domain specific language built on top of the Ruby WATiR library. The real magic happens in WATiR; WSL merely makes that magic accessible to the non-developer masses. WSL contains keywords such as open_url click and select. Using keywords along with input values you build up scripts that mimic what a user would do through the browser, but because you do not need human intervention to execute the keywords in the script you remove any ambiguity that can occur through translation between user, developer, tester. You can practice techniques like using checked examples to ensure you are delivering what the user wants you to deliver.

I started developing WSL whilst working on an agile project. We wanted to automate as much testing in the sprints as possible, wanted something that was lightweight, cheap, and simple to use. I came across WATiR and was very impressed with it's functionality, however to start using WATiR you needed to know how to write Ruby code. This wasn't ideal if we wanted tester to use it! I explored the idea of using WSL as a facade that hides the complexity of WATiR, and as much complexity of Ruby as possible. The biggest barrier I found to its adoption was the apprehension that it is considered as writing code - non-developers don't want to do that! WSL is as human readable as possible; you should be able to follow it as easily as following a manual test script, and be able to execute it faster and easier to boot.

Last Updated on Tuesday, 23 June 2009 16:34
 
WSL Talk 30th June 2009 London

I am talking about WSL on the 30th June at Skillsmatter in London. it's a free event so come along and find out how WSL came about and how best to use it!

More information and registration can be found here.

Update - The video of the talk can be viewed here.

You can download the slides from here.

Last Updated on Wednesday, 14 October 2009 20:33
 
Google Search Example
Written by Administrator   

This is a simple example of a test that does the following -

  1. Opens a browser and navigates to the Google homepage
  2. Enters the term "pickaxe" in the search field, and clicks search
  3. Verifies that "Programming Ruby" is shown in the search results

We will search for the eponymous Pickaxe Ruby book. Here's the screencast showing how to write and execute this test.

Last Updated on Friday, 17 April 2009 15:09
 
Getting Started with WSL

WSL is written entirely in Ruby. To get started with WSL you need to have -

  • At least Ruby 1.8 installed, Download the latest from here.
  • Using a command prompt enter "gem install wsl" to install the gem from Rubyforge.
    • WSL requires the WATiR gem (version 1.6.2 as a minimum), if you do not already have WATiR installed WSL will install it for you.
    • Read the README.txt for fixes to any potential issues when running WSL scripts.

The following tools are what I use when writing WSL scripts -

  • A text editor - Notepad++ works great for me,
  • The command prompt to run the script,
  • And I find either the IE Developer Toolbar or Firebug for Firefox extremely useful - you'll need to inspect HTML pages to get the names of the attributes of various fields.

WSL has finally been open-sourced! you can find the code at Rubyforge here (http://rubyforge.org/projects/wsl/), and you can install via rubygems! If you are a developer looking to get involved head on over and register I look forward to seeing you there!

Last Updated on Tuesday, 23 June 2009 16:27
 
Copyright © 2012 wsl.xqoob.com. All Rights Reserved.
Joomla! is Free Software released under the GNU/GPL License.