SlideShare a Scribd company logo
Galen Framework
- Responsive Design Look and Feel Automation
Why Galen Framework ?
• Layout Testing
• Responsive Design Testing
• Cross Browser Testing
Pros and Cons with Galen
• Pros:
• Open Source
• Easy to install
• Error Reporting with screenshots for Pass & Fail
• Easy to Write/Read syntax
• Multiple Browsers support
• Supports Functional Testing
• Cons:
• Lack of Test Editor.
• Code maintenance is costly when there are lot of UI changes.
Sample web page layout
How it works?
• Describe any layout using special syntax – Spec Language.
• It uses Selenium
• For interacting with elements on page and getting their locations and
dimensions.
• Once it sees that something is wrong
• Reports the error
• Makes a screenshot and highlights the misbehaving element on it.
• How it Runs?
• Open a page in browser
• Resizes it to specified size
• Test the layout according to user-defined specs
Getting Started with Galen
• Define Galen Specs
• Objects Definition
• Object specs
• Run individual Spec files
• Inject JavaScript code
• Create Test suite
• Run Test suite
Objects Definition
@objects
Header id header
Logo-box css .logo-box
Search-bar xpath //input[@class=‘searchBar’]
• Indentation is 1 to 8 spaces but not tab.
• xpath is not preferable unless css cannot be used.
• Syntax for Object definition depends on the Galen Framework
version. ( Ref: http://galenframework.com/docs/specslang-2.0-difference/)
Object Specs
=Test Global Header=
@ on desktop
Header:
height 40px
width 900px
centered horizontally inside screen
@ on mobile, desktop
Logo-box:
css color is “rgba(51, 51, 51, 1)”
css background-color is “rgba(120, 190, 32, 1)”
Search-bar:
below: header 0px
Object Specs ( cont.…)
• Object Definition
• http://galenframework.com/docs/reference-galen-spec-language-guide/#Objectdefinition
• Multiple objects definition
• http://galenframework.com/docs/reference-galen-spec-language-guide/#Multipleobjectsdefinition
• Object Groups
• http://galenframework.com/docs/reference-galen-spec-language-guide/#ObjectGroups
• Many more:
• Tagging and Sections
• Variables
• Conditional checks ( If, Else)
• Loops ( For, ForEach)
• Element locations relative to other elements
• http://galenframework.com/docs/reference-galen-spec-language-guide/#SpecsReference
Run Individual Spec file
galen check homepage.gspec
--url "http://example.com"
--size "640x480"
--javascript "some.js"
--include "mobile,all"
--exclude "toexclude"
--htmlreport "htmlreport-dir"
--testngreport "testng-report.xml"
--jsonreport "jsonreport-dir"
--junitreport "junit-report.xml“
Example:
galen check specs/galen.spec --url "http://www.example.com"
--size "1366x768" --include "desktop" --htmlreport "reports"
Test Suite
• Grouping Test Specs
• Create Global Variables
• Import Test Suites
• Run Specs on different browsers
• Run in Selenium Grid
• Parameterization
• Disabling tests
Test Suite Syntax
@@ set
domain http://www.example.com
@@table devices
@@parameterized using devices
Home page on ${device} device
selenium chrome ${domain} ${size}
check specs/galen.spec --include "${tags}"
|Device| |Tags| |Size|
|Mobile| |Mobile| |400x600|
|Tablet| |Tablet| |720x480|
|Desktop| |Desktop| |1364x800|
Run Test Suite
• galen test mytest01.test
--htmlreport "htmlreport-dir"
--testngreport "report/testng.xml"
--jsonreport "jsonreport-dir"
--junitreport "junit-report.xml"
--parallel-tests 4
--filter "Home page on * device“
• Example:
galen test tests/galen.test --htmlreport "reports"
Reports
• Report for individual Test cases
• Screenshots for each Test case (Pass/Fail)
• Report for Test suite executed
Capabilities of Galen
• Testing relative location of elements in web page.
• Checking visible text.
• Integration with Selenium Grid.
• Inject JavaScript into code.
• Color scheme testing.
• Integration with Appium.
• Can be integrated with Browser Stack, Sauce labs.
Additional Features
• Creating Page Dump
• Creates information about all test objects on page with image
samples.
• Image Comparison
• Java API
• JavaScript API
• Galen Extras
• Advanced expressions which extends Galen specs language.
Installation
• System Requirements:
• Java 1.7 or higher.
• Text Editor.
• Drivers for Respective browsers.
• Galen Framework binary
• http://galenframework.com/download/
• Add Galen folder to “PATH” environment variable.
References
Tutorials
http://mindengine.net/
Documents
http://galenframework.com/docs/all/
Sample Project
http://galenframework.com/docs/tutorial-first-project/
Galen Spec Language
http://galenframework.com/docs/reference-galen-spec-language-
guide/
Thank You

More Related Content

PDF
XpDays - Automated testing of responsive design (GalenFramework)
PPTX
Galen Framework - Responsive Design Automation
PPTX
Automated layout testing using Galen Framework
PPTX
Get responsive with Galen
PPTX
Visual Regression Testing
PDF
Quick start with AngularJS
PPTX
Escape from the automation hell
PPTX
Geb with spock
XpDays - Automated testing of responsive design (GalenFramework)
Galen Framework - Responsive Design Automation
Automated layout testing using Galen Framework
Get responsive with Galen
Visual Regression Testing
Quick start with AngularJS
Escape from the automation hell
Geb with spock

What's hot (20)

PPTX
2011 NetUG HH: ASP.NET MVC & HTML 5
PPTX
[Srijan Wednesday Webinars] Developing Large Scale Applications in AngularJS
PDF
PLAT-8 Spring Web Scripts and Spring Surf
PDF
Geb for testing your grails application
PPTX
5 x HTML5 worth using in APEX (5)
PDF
Introduction to Selenium and Ruby
KEY
Sizzle jQCon San Francisco 2012
PDF
JavaLand 2014 - Ankor.io Presentation
PPTX
Ankor Presentation @ JavaOne San Francisco September 2014
PDF
Modern Functional Fluent ColdFusion REST Apis
PDF
Three Simple Chords of Alternative PageObjects and Hardcore of LoadableCompon...
PPTX
Cloud browser testing with Gradle and Geb
PPTX
Angular js
PPTX
Angular js tutorial slides
PPTX
Spring.new hope.1.3
PDF
How angularjs saves rails
PDF
JavaScript straight from the Oracle Database
PPT
Angular js
PPT
Spring Boot. Boot up your development
PPTX
Setting up Page Object Model in Automation Framework
2011 NetUG HH: ASP.NET MVC & HTML 5
[Srijan Wednesday Webinars] Developing Large Scale Applications in AngularJS
PLAT-8 Spring Web Scripts and Spring Surf
Geb for testing your grails application
5 x HTML5 worth using in APEX (5)
Introduction to Selenium and Ruby
Sizzle jQCon San Francisco 2012
JavaLand 2014 - Ankor.io Presentation
Ankor Presentation @ JavaOne San Francisco September 2014
Modern Functional Fluent ColdFusion REST Apis
Three Simple Chords of Alternative PageObjects and Hardcore of LoadableCompon...
Cloud browser testing with Gradle and Geb
Angular js
Angular js tutorial slides
Spring.new hope.1.3
How angularjs saves rails
JavaScript straight from the Oracle Database
Angular js
Spring Boot. Boot up your development
Setting up Page Object Model in Automation Framework
Ad

Similar to Galenframework (14)

PDF
[Srijan Wednesday Webinars] Automating Visual Regression using ‘Galen’
PPTX
Responsive testing
PPTX
Layout testing with galen framework
PDF
Berlin Selenium Meetup - Galen Framework
PDF
Responsive testing in Drupal - Drupal Developer Days
PPTX
Rare frontend testing
PPTX
Using galen framework for automated cross browser layout testing
PPTX
Responsive Web Design Automation using Galen
PPT
Responsive WebDesign Testing Using Galen
PPT
Responsive WebDesign Testing Using Galen
PPT
Responsive Web Design testing using Galen Framework
PDF
Rapid tests development
PDF
Automating Responsiveness of your Websites
PPTX
3 Ways to test your ColdFusion API - 2017 Adobe CF Summit
[Srijan Wednesday Webinars] Automating Visual Regression using ‘Galen’
Responsive testing
Layout testing with galen framework
Berlin Selenium Meetup - Galen Framework
Responsive testing in Drupal - Drupal Developer Days
Rare frontend testing
Using galen framework for automated cross browser layout testing
Responsive Web Design Automation using Galen
Responsive WebDesign Testing Using Galen
Responsive WebDesign Testing Using Galen
Responsive Web Design testing using Galen Framework
Rapid tests development
Automating Responsiveness of your Websites
3 Ways to test your ColdFusion API - 2017 Adobe CF Summit
Ad

Recently uploaded (20)

PDF
Assigned Numbers - 2025 - Bluetooth® Document
PDF
Video forgery: An extensive analysis of inter-and intra-frame manipulation al...
PDF
NewMind AI Weekly Chronicles - August'25-Week II
PDF
Heart disease approach using modified random forest and particle swarm optimi...
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PPTX
1. Introduction to Computer Programming.pptx
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
PDF
Machine learning based COVID-19 study performance prediction
PPTX
TechTalks-8-2019-Service-Management-ITIL-Refresh-ITIL-4-Framework-Supports-Ou...
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PDF
Empathic Computing: Creating Shared Understanding
PDF
Univ-Connecticut-ChatGPT-Presentaion.pdf
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PPTX
cloud_computing_Infrastucture_as_cloud_p
PDF
Accuracy of neural networks in brain wave diagnosis of schizophrenia
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
Network Security Unit 5.pdf for BCA BBA.
PPT
Teaching material agriculture food technology
Assigned Numbers - 2025 - Bluetooth® Document
Video forgery: An extensive analysis of inter-and intra-frame manipulation al...
NewMind AI Weekly Chronicles - August'25-Week II
Heart disease approach using modified random forest and particle swarm optimi...
Agricultural_Statistics_at_a_Glance_2022_0.pdf
1. Introduction to Computer Programming.pptx
Per capita expenditure prediction using model stacking based on satellite ima...
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
Machine learning based COVID-19 study performance prediction
TechTalks-8-2019-Service-Management-ITIL-Refresh-ITIL-4-Framework-Supports-Ou...
Diabetes mellitus diagnosis method based random forest with bat algorithm
Empathic Computing: Creating Shared Understanding
Univ-Connecticut-ChatGPT-Presentaion.pdf
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
cloud_computing_Infrastucture_as_cloud_p
Accuracy of neural networks in brain wave diagnosis of schizophrenia
Reach Out and Touch Someone: Haptics and Empathic Computing
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
Network Security Unit 5.pdf for BCA BBA.
Teaching material agriculture food technology

Galenframework

  • 1. Galen Framework - Responsive Design Look and Feel Automation
  • 2. Why Galen Framework ? • Layout Testing • Responsive Design Testing • Cross Browser Testing
  • 3. Pros and Cons with Galen • Pros: • Open Source • Easy to install • Error Reporting with screenshots for Pass & Fail • Easy to Write/Read syntax • Multiple Browsers support • Supports Functional Testing • Cons: • Lack of Test Editor. • Code maintenance is costly when there are lot of UI changes.
  • 5. How it works? • Describe any layout using special syntax – Spec Language. • It uses Selenium • For interacting with elements on page and getting their locations and dimensions. • Once it sees that something is wrong • Reports the error • Makes a screenshot and highlights the misbehaving element on it. • How it Runs? • Open a page in browser • Resizes it to specified size • Test the layout according to user-defined specs
  • 6. Getting Started with Galen • Define Galen Specs • Objects Definition • Object specs • Run individual Spec files • Inject JavaScript code • Create Test suite • Run Test suite
  • 7. Objects Definition @objects Header id header Logo-box css .logo-box Search-bar xpath //input[@class=‘searchBar’] • Indentation is 1 to 8 spaces but not tab. • xpath is not preferable unless css cannot be used. • Syntax for Object definition depends on the Galen Framework version. ( Ref: http://galenframework.com/docs/specslang-2.0-difference/)
  • 8. Object Specs =Test Global Header= @ on desktop Header: height 40px width 900px centered horizontally inside screen @ on mobile, desktop Logo-box: css color is “rgba(51, 51, 51, 1)” css background-color is “rgba(120, 190, 32, 1)” Search-bar: below: header 0px
  • 9. Object Specs ( cont.…) • Object Definition • http://galenframework.com/docs/reference-galen-spec-language-guide/#Objectdefinition • Multiple objects definition • http://galenframework.com/docs/reference-galen-spec-language-guide/#Multipleobjectsdefinition • Object Groups • http://galenframework.com/docs/reference-galen-spec-language-guide/#ObjectGroups • Many more: • Tagging and Sections • Variables • Conditional checks ( If, Else) • Loops ( For, ForEach) • Element locations relative to other elements • http://galenframework.com/docs/reference-galen-spec-language-guide/#SpecsReference
  • 10. Run Individual Spec file galen check homepage.gspec --url "http://example.com" --size "640x480" --javascript "some.js" --include "mobile,all" --exclude "toexclude" --htmlreport "htmlreport-dir" --testngreport "testng-report.xml" --jsonreport "jsonreport-dir" --junitreport "junit-report.xml“ Example: galen check specs/galen.spec --url "http://www.example.com" --size "1366x768" --include "desktop" --htmlreport "reports"
  • 11. Test Suite • Grouping Test Specs • Create Global Variables • Import Test Suites • Run Specs on different browsers • Run in Selenium Grid • Parameterization • Disabling tests
  • 12. Test Suite Syntax @@ set domain http://www.example.com @@table devices @@parameterized using devices Home page on ${device} device selenium chrome ${domain} ${size} check specs/galen.spec --include "${tags}" |Device| |Tags| |Size| |Mobile| |Mobile| |400x600| |Tablet| |Tablet| |720x480| |Desktop| |Desktop| |1364x800|
  • 13. Run Test Suite • galen test mytest01.test --htmlreport "htmlreport-dir" --testngreport "report/testng.xml" --jsonreport "jsonreport-dir" --junitreport "junit-report.xml" --parallel-tests 4 --filter "Home page on * device“ • Example: galen test tests/galen.test --htmlreport "reports"
  • 14. Reports • Report for individual Test cases • Screenshots for each Test case (Pass/Fail) • Report for Test suite executed
  • 15. Capabilities of Galen • Testing relative location of elements in web page. • Checking visible text. • Integration with Selenium Grid. • Inject JavaScript into code. • Color scheme testing. • Integration with Appium. • Can be integrated with Browser Stack, Sauce labs.
  • 16. Additional Features • Creating Page Dump • Creates information about all test objects on page with image samples. • Image Comparison • Java API • JavaScript API • Galen Extras • Advanced expressions which extends Galen specs language.
  • 17. Installation • System Requirements: • Java 1.7 or higher. • Text Editor. • Drivers for Respective browsers. • Galen Framework binary • http://galenframework.com/download/ • Add Galen folder to “PATH” environment variable.