View on GitHub

Sirius

Sirius Java Web Client Overview

Download this project as a .zip file Download this project as a tar.gz file

Introduction

This is the client for Sirius platform responsible for Web applications interaction. It provides the communication channel to Sirius Server Web module as well as provides high-level API for making convenient page objects definition and general interaction with web application under test.

Project Documentation

ResourceDescription
Project Documentation Home PageThe home page for generated Maven site containing major technical documentation for the module
Project Reports PageThe home page for generated Maven site containing major analysis reports for the module
Project Javadoc PageThe home page for generated Maven site containing major Javadoc documentation for the module

Installation

The Sirius Web client library is delivered in 2 ways:

  1. Self-contained Java library provided as jar file. It can be taken from downloads page. All we need to do is just unpack the archive and include appropriate jar file into the project.

  2. Maven dependencies. Each client module is also published to Maven repository. The list of available modules can be found on the following page. So, if we have Maven project where we’d like to use Sirius Java client libraries we should update Maven script with the entry like this:

1
2
3
4
5
	<dependency>
		<groupId>com.github.mkolisnyk</groupId>
		<artifactId>sirius.client.web</artifactId>
		<version>LATEST</version>
	</dependency>

or any similar for all the modules we’d like to include.

Usage Sample

After that we can use library classes, e.g:

1
2
3
4
5
6
	import org.sirius.client.web.classes.Page;
	import org.sirius.client.web.classes.WebButton;
	import org.sirius.client.web.classes.WebEdit;
	...
	
	WebClient client = new WebClient();

In this example we’ve just initialized main entry point for Sirius Win32 API and after that we can make window declarations like:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
	public class GoogleStart extends Page {
		
		public WebEdit edtQuery = null;
		public WebButton btnSearch = null;
		
		public GoogleStart(WebClient client){
			super(client);
			edtQuery = new WebEdit(this,"name=q");
			btnSearch = new WebButton(this,"name=btnG");
		}
	}	

and then use them within the test code like:

1
2
3
4
5
6
	client.start(WebClient.HTMLUNIT);
	GoogleStart main = new GoogleStart(client);
	
	main.open("http://google.com");
	main.edtQuery.type("Hello world!!!");
	main.btnSearch.click();

Detailed information about Sirius Web client API usage can be found on the project wiki page where all major concepts are described.

Documentation

Project Wiki

Releases

All available client modules can be found at the Maven repository.

Blog Links

Related blog entries

Authors

Myk Kolisnyk (kolesnik.nickolay@gmail.com)

View Mykola Kolisnyk's profile on LinkedIn

Google+