BBS Sahi Open Source

17
SAHI Open Source Automation Tool

Transcript of BBS Sahi Open Source

Page 1: BBS Sahi Open Source

SAHI Open Source Automation Tool

Page 2: BBS Sahi Open Source

What is SAHI?“Sahi OS” is an open source automation and testing tool for web applications, with the facility to record and playback scripts. Developed in Java and JavaScript, this tool uses simple JavaScript to execute events on the browser.

Page 3: BBS Sahi Open Source

SAHI runs as proxy server

Page 4: BBS Sahi Open Source

Advantages of SAHI OS -1• Using SAHI isn’t going to cost you much as it saves both

your time and money• SAHI is an open source tool, so it is available to everyone

easily• SAHI runs on all the browsers• SAHI scripts are fast to create and easy to maintain• SAHI has powerful recorder which works on across browsers• SAHI has powerful object spy• SAHI supports Apache Ant

Page 5: BBS Sahi Open Source

Advantages of SAHI OS -2• SAHI Suites can run in multiple threads thus reducing

the test execution time• No wait statements required even for AJAX and page

loads• External Proxy, HTTP and HTTPS support• Support to read and write on Database (MySQL, MSSQL

or Oracle), Excel and CSV file• Logging/reports• One can easily introduce SAHI to manual testers• Intuitive and simple APIs

Page 6: BBS Sahi Open Source

Advantages of SAHI OS -3

One significant point is that Sahi gives the visible text a higher priority than other code related properties like css style. This helps in two ways; •  Writing and maintaining test scripts become very easy.

What you see is what you script. •  It validates what a user sees and not what a developer

coded.

Page 7: BBS Sahi Open Source

Download And Installation• Download SAHI OS from https://sahipro.com/sahi-open-source/

Page 8: BBS Sahi Open Source

Run SAHI OS• On Windows you can use shortcut which is created by SAHI while

installation process.• On linux and Mac you need to go to <SAHI>\userdata\bin and run

start_dashboard.sh

Page 9: BBS Sahi Open Source

Recording on SAHI

Page 10: BBS Sahi Open Source

Start Coding on SAHI

Page 11: BBS Sahi Open Source

SAHI supports JS

• SAHI scripts are developed by JavaScripts. So JavaScripts can be used with SAHI scripts to prepare more powerful scenarios.

Page 12: BBS Sahi Open Source

SAHI APIs Documentationhttps://sahipro.com/docs/sahi-apis/index.html

Page 13: BBS Sahi Open Source

Let’s run our tests

Page 14: BBS Sahi Open Source

Running Tests on command line & terminal

• First need to up sahi server without its own dashboard../start_sahi.sh or ./start_sahi.bat

• On OS or Linux./testrunner.sh BBS/bbs.sah http://www.ebay.com/ firefox

• On Windows./testrunner.bat BBS/bbs.sah http://www.ebay.com/ firefox

Page 15: BBS Sahi Open Source

Multi Thread Testing• No need to install any other 3rd party program to run parallel tests.• Just create test.suite file which includes our .sah files.

• And run ./testrunner.sh BBS/bbs.suite http://www.ebay.com/ firefox

Page 16: BBS Sahi Open Source

Headless Browsers and SAHI• Sahi supports PhantomJS and X11 to run scripts via headless

browsers.

• First need to up sahi server without its own dashboard../start_sahi.sh

• Then./testrunner.sh BBS/bbs.sah http://www.ebay.com/ phantomjs

Page 17: BBS Sahi Open Source

Thanks !