BY: KYLE ROGAHN COMPUTER SCIENCE SEMINAR UW PLATTEVILLE 4/3/2012 Web Browser Automation - Geb.

Slides:



Advertisements
Similar presentations
Designing Reusable Frameworks for Test Automation
Advertisements

MICHAEL MARINO CSC 101 Whats New in Office Office Live Workspace 3 new things about Office Live Workspace are: Anywhere Access Store Microsoft.
Key-word Driven Automation Framework Shiva Kumar Soumya Dalvi May 25, 2007.
Web Applications Development Using Coldbox Platform Eddie Johnston.
AJAX Technologies KAUNAS UNIVERSITY OF TECHNOLOGY MODULE: INFORMATION TECHNOLOGY GROUP: IF - 4/9 GROUP: VENTILIATORIAI
1 GWT Google Web Toolkit Build AJAX apps in the Java language
Server-Side vs. Client-Side Scripting Languages
Do We Really Need Rich-Interface Technologies? Yifan Zhang
Cloud Computing Lecture #7 Introduction to Ajax Jimmy Lin The iSchool University of Maryland Wednesday, October 15, 2008 This work is licensed under a.
Web Page Behavior IS 373—Web Standards Todd Will.
Supplement 02CASE Tools1 Supplement 02 - Case Tools And Franchise Colleges By MANSHA NAWAZ.
Selenium – Testing Tool. What is Selenium? Selenium is a robust set of tools that supports rapid development of test automation for web-based applications.
© 2006, Cognizant Technology Solutions. All Rights Reserved. The information contained herein is subject to change without notice. Automation – How to.
Automation using Selenium Authored & Presented by : Chinmay Sathe & Amit Prabhu Cybage Software Pvt. Ltd.
Struts 2.0 an Overview ( )
UNIT-V The MVC architecture and Struts Framework.
Groovy WHAT IS IT? HOW DOES IT WORK? IS IT USEFUL?
Pittsburgh Java User Group– Dec Java PureFaces: A JSF Framework Extension.
A Scalable Application Architecture for composing News Portals on the Internet Serpil TOK, Zeki BAYRAM. Eastern MediterraneanUniversity Famagusta Famagusta.
Tony Nguyen.  Architecture  Advantages  Disadvantages  Setup JSF Environment  JSF & Database  Conclusion  Demo.
Basics of Web Databases With the advent of Web database technology, Web pages are no longer static, but dynamic with connection to a back-end database.
GENERAL CONCEPTS OF OOPS INTRODUCTION With rapidly changing world and highly competitive and versatile nature of industry, the operations are becoming.
Software Construction Lecture 10 Frameworks
Multi-agent Research Tool (MART) A proposal for MSE project Madhukar Kumar.
PHP TUTORIAL. HISTORY OF PHP  PHP as it's known today is actually the successor to a product named PHP/FI.  Created in 1994 by Rasmus Lerdorf, the very.
JavaScript II ECT 270 Robin Burke. Outline JavaScript review Processing Syntax Events and event handling Form validation.
Tutorial 121 Creating a New Web Forms Page You will find that creating Web Forms is similar to creating traditional Windows applications in Visual Basic.
The Effectiveness of Web Components Presented By: Geoffrey Zimmerman Computer Science Capstone Fall 2004/Spring 2005 Mentor: Dr. C. David Shaffer.
CMPD 434 MULTIMEDIA AUTHORING Chapter 06 Multimedia Authoring Process IV.
JSF Introduction Copyright © Liferay, Inc. All Rights Reserved. No material may be reproduced electronically or in print without written permission.
INTRODUCTION TO HTML5 Using jQuery with HTML5. Introducing jQuery  Although it is not a part of any W3C or WHATWG specification, jQuery performs an important.
Project Overview Graduate Selection Process Project Goal Automate the Selection Process.
Lecture Note 1: Getting Started With ASP.  Introduction to ASP  Introduction to ASP An ASP file can contain text, HTML tags and scripts. Scripts in.
Project Overview Graduate Selection Process Project Goal Automate the Selection Process.
Test Automation For Web-Based Applications Portnov Computer School Presenter: Ellie Skobel.
Automated Smoke Testing on the JVM with Geb João SILVA (GS-AIS-EB) 1st Forum 29th of September, 2015 e-Business Section AUTOMATED SMOKE.
Chapter 2 Part C – More on the Help System and The Object Browser (scan quickly for future reference)
Frameworks CompSci 230 S Software Construction.
Chapter 4: Working with ASP.NET Server Controls OUTLINE  What ASP.NET Server Controls are  How the ASP.NET run time processes the server controls on.
Model View Controller MVC Web Software Architecture.
Test Automation For Web-Based Applications Portnov Computer School Presenter: Ellie Skobel.
Selenium January Selenium course content  Introduction (Session-1)Session-  Automation  What is automation testing  When to go for automation.
Introduction Selenium IDE is a Firefox extension that allows you to record, edit, and debug tests for HTML Easy record and playback Intelligent field selection.
Scripting Languages Client Side and Server Side. Examples of client side/server side Examples of client-side side include: JavaScript Jquery (uses a JavaScript.
© FPT SOFTWARE – TRAINING MATERIAL – Internal use 04e-BM/NS/HDCV/FSOFT v2/3 JSP Application Models.
Plug-in Architectures Presented by Truc Nguyen. What’s a plug-in? “a type of program that tightly integrates with a larger application to add a special.
Intro to jQuery. What is jQuery? A JavaScript library Lightweight (about 31KB for the minified version) Simplifies HTML document traversing (DOM), event.
MNP1163/MANP1163 (Software Construction).  Minimizing complexity  Anticipating change  Constructing for verification  Reuse  Standards in software.
Unit 13 –JQuery Basics Instructor: Brent Presley.
Chapter 3 JSP Overview. The Problem with Servlets processing the request and generating the response are both handled by a single servlet class Java programming.
© 2012 LogiGear Corporation. All Rights Reserved FitNesseFitNesse Authors: Nghia Pham 1.
XML Tools (Chapter 4 of XML Book). What tools are needed for a complete XML application? n Fundamental components n Web infrasructure n XML development.
Testing Your Alfresco Add-ons Michael Suzuki Software Engineer.
Northwest Arkansas.Net User Group Jay Smith Tyson Foods, Inc. Unit Testing nUnit, nUnitAsp, nUnitForms.
Part 1 The Basics of Information Systems. Purpose of Information Systems Information systems ◦ Collects, stores and organizes information ◦ Retrieves.
Testing Your Alfresco Add-ons Michael Suzuki Software Engineer.
Pre-Production Meet with the client to create a project plan:
Leverage your Business with Selenium Automation Testing
Software Testing.
Understanding SOAP and REST calls The types of web service requests
ATLAS WEB JavaScript & the DOM.
AJAX.
Java Web Application Framework
Submitted By: Usha MIT-876-2K11 M.Tech(3rd Sem) Information Technology
jQuery The Easy JavaScript Nikolay Chochev Technical Trainer
Introduction to AppInventor
International Living Atlases Workshop Madrid 2018
An introduction to jQuery
An introduction to jQuery
VoiceXML An investigation Author: Mya Anderson
Presentation transcript:

BY: KYLE ROGAHN COMPUTER SCIENCE SEMINAR UW PLATTEVILLE 4/3/2012 Web Browser Automation - Geb

Introduction Geb is a web browser automation tool JQuery + Webdriver + Groovy Advantageous in certain web development projects New: not even at version 1.0

On Deck Browser Automation – Geb at a high level Advantages Disadvantages What is it – the details  Webdriver  Groovy  Jquery  Page Object Model Example code  testing

Web Browser Automation Programmatically control your web browser Use this ability to write tests for web applications Improved quality assurance process

Advantages Eliminate tedious manual testing  Good fit for large projects with many test cases  Unit tests not enough to catch errors  Integration of complex systems  MVC example  Data Access Objects – retrieving customer information

Advantages Save time (and money)  Speed up navigation through many pages  Reduce data entry  What takes a person minutes Geb can do in seconds

Advantages Easy to learn  Readability  Semantics easy to figure out  Going to the google home page  “To” keyword, google home page defined as an object  To GoogleHomePage  Low learning curve

Disadvantages Less useful on smaller projects  May cost more time than it saves  Manual testing may suffice  Could still use it if desired Guaranteed Learning curve  Since it’s new there’s a high chance developers will not know it  Comes down to affordability  Although, learning curve is not that high

Disadvantages Configuration issues  Specific environment needed  If using a compatible environment already it is easy  May be tough otherwise  Grails, Maven, Gradle are suggested  Switching environments may be too costly Software Engineering Management Decisions

What Makes Up Geb WebDriver  Handles automation JQuery  Used for content selection Groovy  Syntax based on this language Page Object Model  Architecture that makes Geb powerful

WebDriver Driving force behind browser automation  Modifies document object model (DOM) components  Control browser behavior DOM components  Interface content  Buttons, text fields…etc WebDriver by itself vs. Geb  Geb is simpler, more readable, and easier to learn

WebDriver Example

Groovy Dynamic programming language for the JVM Similar to Ruby  Combined with some of the powerful features of Java  Integrates well with all Java libraries Supports mocking for unit testing Easy to learn and read

Groovy Example

Comparing to Ruby Class HelloExample Def hello entity puts “Hello, #{entity}!” end End def main example = HelloExample.new() example.hello(‘world’) end

JQuery Content Selection  Improvement over WebDriver’s DOM content selector  Important to quickly locate desired objects on a page Ability to modify html code Event handlers and overwriting Support for all major browsers Some of its syntax makes its way into Geb

Jquery Example

Testing Frameworks Geb can be combined with many testing frameworks Or used in-line Spock is the recommended framework  Included in the Geb package  Configuration: Import geb.spock.GebSpec  Clearest and most concise way to write Geb tests

In-line Geb Go vs driver.get(…) Assert without test framework  Webdriver: driver.getTitle() then compare using.equals $ - Jquery  sendKeys() in WebDriver

Page Object Model Non inline Geb programs – preferred Increase maintainability and reusability Based on the notion of page objects  Define a class for each page of your application  Call on page components when needed  Only have to use JQuery for lookup once Powerful!

Typical Page Class

Geb Testing Using Page Classes Test specifications  Specific names  Readability/Maintainability Spock framework  Extra keywords to simplify tests  Do something then check the result  Are we on the right page?  Did a certain component change?

Testing Example Go to the login page Make sure we’re there Try to login as an admin Click login Check if we are at the admin page

Conclusion Geb is easy to read, write, learn, and modify. Saves a large amount of testing time Larger application test coverage Page object model is powerful Effective keywords Read The Book of Geb  Watch the selenium conference speech: 