Archive for December, 2009

Test Automation and Selenium

Using a software to execute number of tests without human interaction is known as test automation. This involves comparing of predicted result to the actual result obtained, checking of GUI components and actions, and other testing control and creating test reports to indicate the summery of the tests. Although manual testing can find more defects compared to automation, test automation is a very efficient and cost effective process when doing quality assurance for software products which have a long maintenance life. The most important thing of test automation for products having long maintenance life is, when introducing new patches to upgrade the product, it may cause some other features to fail which were working properly before introducing the patch. Therefore to identify such defects we can say, test automation is the most efficient method.

Test automation is another software developing or coding process. Therefore it may also have bugs which cause properly working software functions may be considered as buggy. Because of that when doing test automation, we should make it a point to develop a bug free test framework for our requirement. And we should know automation is not always advantageous process in software quality assurance. Manual testing may be more appropriate in cases when the application or GUI get changed time to time, there is no time to automate tests, etc. Therefore we should carefully decide whether to automate or not our tests.


Selenium is a web application software testing framework which consists of set of tools for test automation. Selenium provides a rich set of testing functions for testing of a web application. There three major tools which power the selenium framework.

Selenium-IDE :

Selenium-IDE is the Integrated Development Environment use to develop Selenium test cases. It is implemented as a Firefox add-on and can be used to record, edit, and debug tests. For more details of how to install and use selenium IDE refer

Selenium-RC :

Selenium-RC can be used for tests that need more than simple browser actions and linear execution. This can be used to create more complex tests such as database accessing, file accessing, emailing test results, etc. For more details, refer


Selenium-Grid coordinates multiple instances of Selenium-RC are running on various operating system and browser configurations. Tests can be run on lot of platforms at the same time saving lot of time and allowing wider testing. For more details, refer

Beginning to the world of Web Services…

As I am a new to the software world, I have to learn from very basic level of software stuff. I got the opportunity to get knowledge on C language, basics of OOP with C++ during my university life and have done self studying on C# and Java.

And with my carrier opportunity at WSO2, I’m stepping in to the path of Web Services. At the beginning I had no idea about web services, but with the time I realized it is very interesting topic and thought to write this simple blog for the beginners to the web services world.

Revolution is the key of keeping computer industry in the highest demanding position. When we looked in to several years back very few people had access or used computers and applications of computers are very few. The introduction of Internet began to a new era of computer industry. Since then, standards such as HTML (the base protocol for viewing content on the Web) and HTTP (the associated software for browsing this content) have exponentially increased people’s use of the Internet and grew Web usage to what we are familiar with today. The Web became a key activity in the daily lives of businesses, employees, and consumers.

As a result of this, the industry wanted to have a standard way of building applications and processes to connect and exchange information over the Web. Because of that, web services was introduced to share data, integrate their processes, and join forces to offer customized , comprehensive solutions to their customers. The information of you or your business need will be available wherever you are, and whatever computing device, platform, or application you are using. Therefore web services enables a standard way of building applications and processes to connect and exchange information over the Web. Because of that, web services can convert our applications into web-applications which can be published, found, and used through the Web.

The heart of the web services solution is XML which is an open industry standard managed by the World Wide Web. It enables developers to describe data exchanged between PCs, smart devices, applications, and Web sites. Since the data is separated from the format of the data, it can be easily organized, programmed, edited, and exchanged between any Web sites, applications, and devices.

These are the basic elements of web services,

-A network

To make the web service to be available in web. Generally, this network is based on Hypertext Transfer Protocol (HTTP), but it can also be based on other protocols.

-XML-based messaging

To enable the communication between the web service and clients. Communication is done by exchanging XML-based messages. These messages are called SOAP messages. SOAP stands for Simple Object Access Protocol. SOAP is a specification that defines the XML format for messages. An XML fragment enclosed in a couple of SOAP elements is a SOAP message. In web services scenario, a SOAP message is sent inside an HTTP message. There’s no standard f or how a SOAP message is carried, and SOAP doesn’t care what the transport is. The SOAP specification defines what an HTTP message containing a SOAP message must look like. This is just like, print a SOAP message, fax it to a remote location, and type it into the remote machine without violating the SOAP standard.

-Web Service Description (WSD)

To describe the web service, where can it be found, what messages are accepted / generated what syntax and how those are encoded. Basically it provides a standard format to describe the web service. It represents an agreement of the mechanics of interacting with the service. WSDL (an XML-based language) is used to write WSD.

-Universal Description, Discovery and Integration (UDDI)

A directory service for storing information about web services described by WSDL where companies can register and search for Web services. UDDI communicates via SOAP messages.

The figure bellow shows a very basic architecture of web service

Service provider:

Provides the interface for the Web service and the implementation of the web application. The service provider is also responsible for creating the definition of the service and publishing that definition to meet the Universal Description, Discovery.

Discovery Agency:

A discovery agency is a way in which Web services are formally published. The discovery agency is based on the UDDI specification and contains information about services provided by the service provider. The discovery agency provides a service requester with a Web Services Description Language (WSDL) service description and a Uniform Resource Locator (URL) that points to the service.

Service requester:

A service requester is the consumer of a Web service and uses the service registry to gain information about, and access to, a Web service.

A service requester and service provider interact based on the service’s description information (WSDL) published by the provider and discovered by the requester through a discovery agency. Service requesters and providers interact by exchanging messages. XML messages with the SOAP specification are exchanged between the requester and provider. The provider publishes a WSDL file that contains a description of the message and endpoint information to allow the requester to generate the SOAP message and send it to the correct destination.

The service requester sends a message in the form of a request for information, or to perform an operation. Then the service provider receives the request, processed the message and sends a response. Then the service requester receives a message from the service provider that contains the result of the request or operation. This is the basic high level picture of web services.