SlideShare uma empresa Scribd logo
1 de 63
Baixar para ler offline
UA	
  Tes'ng	
  with
Selenium	
  and	
  PHPUnit
ZendCon	
  2013,	
  Santa	
  Clara
2
• PHP	
  Consultant
• President	
  PHPBenelux
• Conference	
  speaker
Michelangelo	
  van	
  Dam
3
Today’s	
  goal
• Set	
  up	
  and	
  use	
  Selenium	
  IDE
• Record	
  UA	
  tests
• Convert	
  to	
  PHPUnit
• Run	
  con'nuously
• Mul'	
  browser	
  support
4
5
DISCLAIMER
S E L E N I U M T E S T S A R E N OT A
REPLACEMENT FOR REGULAR UNIT
TESTING. THEY ONLY PROVIDE AN
ADDITIONAL SET OF TESTS FOCUSED
ON USER ACCEPTANCE AND USER
EXPERIENCE TESTING.
For more information about unit testing, please
see my other material on www.slideshare.net and
www.speakerdeck.com. Search for “dragonbe”!
User	
  Acceptance
6
7
“Acceptance testing is a test conducted to determine if
the requirements of a specification or contract are met.”
-- source: wikipedia
Checklist	
  for	
  web	
  applica'ons
8
9
Func'onal	
  tes'ng
• Test	
  func'onal	
  requirements
-­‐ e.g.	
  no	
  access	
  to	
  profile	
  without	
  authen'ca'on
• Test	
  UI	
  elements	
  on	
  the	
  web	
  interface
-­‐ e.g.	
  buTons,	
  form	
  elements,	
  AJAX	
  controls,	
  …
A	
  word	
  of	
  cau'on!
10
• UA	
  tests	
  only	
  test	
  generated	
  output
-­‐ not	
  a	
  replacement	
  for	
  unit	
  tes'ng
• UA	
  tests	
  are	
  heavily	
  depending	
  on	
  DOM
-­‐ changes	
  to	
  the	
  DOM	
  might	
  lead	
  to	
  failing	
  UAT
Browser	
  support
11
Selenium	
  to	
  the	
  rescue
12
Plugin	
  for	
  firefox
13
Get	
  the	
  plugin	
  (demo)
14
Let’s	
  get	
  started
16
Pick	
  a	
  test	
  case
17
Issue	
  #7
18
Verify	
  this	
  issue	
  on	
  PROD
19
20
Fix	
  the	
  issue
21
Run	
  test	
  to	
  see	
  it’s	
  fixed
22
23
24
Save	
  your	
  test	
  as	
  .html
It’s	
  that	
  easy!
25
Automated	
  Tes'ng
26
PHPUnit	
  to	
  the	
  rescue
27
Export	
  to	
  PHPUnit
28
The	
  PHPUnit	
  TestCase
29
<?php
class Example extends PHPUnit_Extensions_SeleniumTestCase
{
protected function setUp()
{
$this->setBrowser("*chrome");
$this->setBrowserUrl("http://www.theialive.com/");
}
public function testMyTestCase()
{
$this->open("/");
$this->click("link=login");
$this->waitForPageToLoad("30000");
$this->type("id=email", "dragonbe+tek13@gmail.com");
$this->type("id=password", "test1234");
$this->click("id=signin");
$this->waitForPageToLoad("30000");
$this->click("link=Test demo");
$this->waitForPageToLoad("30000");
$this->assertEquals("Done", $this->getText("xpath=//th[5]"));
$this->click("link=[EDIT]");
$this->waitForPageToLoad("30000");
$this->assertTrue($this->isElementPresent("id=done"));
$this->click("link=sign off");
$this->waitForPageToLoad("30000");
}
}
?>
Change	
  class	
  name
30
<?php
class Example extends PHPUnit_Extensions_SeleniumTestCase
{
protected function setUp()
{
$this->setBrowser("*chrome");
$this->setBrowserUrl("http://www.theialive.com/");
}
public function testMyTestCase()
{
$this->open("/");
$this->click("link=login");
$this->waitForPageToLoad("30000");
$this->type("id=email", "dragonbe+tek13@gmail.com");
$this->type("id=password", "test1234");
$this->click("id=signin");
$this->waitForPageToLoad("30000");
$this->click("link=Test demo");
$this->waitForPageToLoad("30000");
$this->assertEquals("Done", $this->getText("xpath=//th[5]"));
$this->click("link=[EDIT]");
$this->waitForPageToLoad("30000");
$this->assertTrue($this->isElementPresent("id=done"));
$this->click("link=sign off");
$this->waitForPageToLoad("30000");
}
}
?>
class MarkTaskDoneTest extends PHPUnit_Extensions_SeleniumTestCase
The	
  PHPUnit	
  TestCase
31
<?php
class MarkTaskDoneTest extends PHPUnit_Extensions_SeleniumTestCase
{
protected function setUp()
{
$this->setBrowser("*chrome");
$this->setBrowserUrl("http://www.theialive.com/");
}
public function testMyTestCase()
{
$this->open("/");
$this->click("link=login");
$this->waitForPageToLoad("30000");
$this->type("id=email", "dragonbe+tek13@gmail.com");
$this->type("id=password", "test1234");
$this->click("id=signin");
$this->waitForPageToLoad("30000");
$this->click("link=Test demo");
$this->waitForPageToLoad("30000");
$this->assertEquals("Done", $this->getText("xpath=//th[5]"));
$this->click("link=[EDIT]");
$this->waitForPageToLoad("30000");
$this->assertTrue($this->isElementPresent("id=done"));
$this->click("link=sign off");
$this->waitForPageToLoad("30000");
}
}
?>
protected function setUp()
{
$this->setBrowser("*iexplore");
$this->setBrowserUrl("http://www.theialive.com/");
$this->setHost('192.168.56.101');
$this->setPort(12666);
}
Meaningful	
  method	
  name
<?php
class MarkTaskDoneTest extends PHPUnit_Extensions_SeleniumTestCase
{
protected function setUp()
{
$this->setBrowser("*iexplore");
$this->setBrowserUrl("http://www.theialive.com/");
$this->setHost('192.168.56.101');
$this->setPort(12666);
}
public function testMyTestCase()
{
$this->open("/");
$this->click("link=login");
$this->waitForPageToLoad("30000");
$this->type("id=email", "dragonbe+tek13@gmail.com");
$this->type("id=password", "test1234");
$this->click("id=signin");
$this->waitForPageToLoad("30000");
$this->click("link=Test demo");
$this->waitForPageToLoad("30000");
$this->assertEquals("Done", $this->getText("xpath=//th[5]"));
$this->click("link=[EDIT]");
$this->waitForPageToLoad("30000");
$this->assertTrue($this->isElementPresent("id=done"));
$this->click("link=sign off");
$this->waitForPageToLoad("30000");
}
}
?>
32
public function testMarkTestAsDone()
startSeleniumStandAlone.BAT
33
"C:Program FilesJavajre7binjava.exe"
-jar "C:Jarselenium-server-standalone-2.28.0.jar"
-port 12666
Now	
  run	
  your	
  tests
34
How	
  it	
  runs	
  on	
  the	
  node
36
Advantages
38
• You	
  can	
  start	
  tes'ng	
  immediately
• Even	
  test	
  “hard	
  to	
  test”	
  kind	
  of	
  situa'ons
• More	
  nodes	
  for	
  parallel	
  tes'ng
• Tes'ng	
  different	
  browsers	
  and	
  plaforms
• Con'nuous	
  Integra'on	
  possible
Next	
  Steps
39
Mul'	
  Browser	
  support
40
Base	
  TestCase
41
<?php
require_once 'PHPUnit/Extensions/SeleniumTestCase.php';
class TestCase extends PHPUnit_Extensions_SeleniumTestCase
{
//const TEST_HUB = '217.21.179.192';
const TEST_HUB = '192.168.56.101';
const TEST_PORT = 12666;
const USERNAME = 'dragonbe+tek13@gmail.com';
const PASSWORD = 'test1234';
const BASURL = 'http://www.theialive.com';
public static $browsers = array (
array (
'name' => 'Internet Explorer 8 on Windows 7', 'browser' => '*iexplore',
'host' => self::TEST_HUB, 'port' => self::TEST_PORT,
),
array (
'name' => 'Firefox on Windows 7', 'browser' => '*firefox',
'host' => self::TEST_HUB, 'port' => self::TEST_PORT,
),
array (
'name' => 'Google Chrome on Windows 7', 'browser' => '*googlechrome',
'host' => self::TEST_HUB, 'port' => self::TEST_PORT,
),
);
protected function setUp()
{
$this->setBrowserUrl(self::BASURL);
}
}
Base	
  TestCase
42
<?php
require_once 'PHPUnit/Extensions/SeleniumTestCase.php';
class TestCase extends PHPUnit_Extensions_SeleniumTestCase
{
//const TEST_HUB = '217.21.179.192';
const TEST_HUB = '192.168.56.101';
const TEST_PORT = 12666;
const USERNAME = 'dragonbe+tek13@gmail.com';
const PASSWORD = 'test1234';
const BASURL = 'http://www.theialive.com';
public static $browsers = array (
array (
'name' => 'Internet Explorer 8 on Windows 7', 'browser' => '*iexplore',
'host' => self::TEST_HUB, 'port' => self::TEST_PORT,
),
array (
'name' => 'Firefox on Windows 7', 'browser' => '*firefox',
'host' => self::TEST_HUB, 'port' => self::TEST_PORT,
),
array (
'name' => 'Google Chrome on Windows 7', 'browser' => '*googlechrome',
'host' => self::TEST_HUB, 'port' => self::TEST_PORT,
),
);
protected function setUp()
{
$this->setBrowserUrl(self::BASURL);
}
}
array (
'name' => 'Internet Explorer 8 on Windows 7',
'browser' => '*iexplore',
'host' => self::TEST_HUB,
'port' => self::TEST_PORT,
),
Base	
  TestCase
43
<?php
require_once 'PHPUnit/Extensions/SeleniumTestCase.php';
class TestCase extends PHPUnit_Extensions_SeleniumTestCase
{
//const TEST_HUB = '217.21.179.192';
const TEST_HUB = '192.168.56.101';
const TEST_PORT = 12666;
const USERNAME = 'dragonbe+tek13@gmail.com';
const PASSWORD = 'test1234';
const BASURL = 'http://www.theialive.com';
public static $browsers = array (
array (
'name' => 'Internet Explorer 8 on Windows 7', 'browser' => '*iexplore',
'host' => self::TEST_HUB, 'port' => self::TEST_PORT,
),
array (
'name' => 'Firefox on Windows 7', 'browser' => '*firefox',
'host' => self::TEST_HUB, 'port' => self::TEST_PORT,
),
array (
'name' => 'Google Chrome on Windows 7', 'browser' => '*googlechrome',
'host' => self::TEST_HUB, 'port' => self::TEST_PORT,
),
);
protected function setUp()
{
$this->setBrowserUrl(self::BASURL);
}
}
array (
'name' => 'Firefox on Windows 7',
'browser' => '*firefox',
'host' => self::TEST_HUB,
'port' => self::TEST_PORT,
),
Base	
  TestCase
44
<?php
require_once 'PHPUnit/Extensions/SeleniumTestCase.php';
class TestCase extends PHPUnit_Extensions_SeleniumTestCase
{
//const TEST_HUB = '217.21.179.192';
const TEST_HUB = '192.168.56.101';
const TEST_PORT = 12666;
const USERNAME = 'dragonbe+tek13@gmail.com';
const PASSWORD = 'test1234';
const BASURL = 'http://www.theialive.com';
public static $browsers = array (
array (
'name' => 'Internet Explorer 8 on Windows 7', 'browser' => '*iexplore',
'host' => self::TEST_HUB, 'port' => self::TEST_PORT,
),
array (
'name' => 'Firefox on Windows 7', 'browser' => '*firefox',
'host' => self::TEST_HUB, 'port' => self::TEST_PORT,
),
array (
'name' => 'Google Chrome on Windows 7', 'browser' => '*googlechrome',
'host' => self::TEST_HUB, 'port' => self::TEST_PORT,
),
);
protected function setUp()
{
$this->setBrowserUrl(self::BASURL);
}
}
array (
'name' => 'Google Chrome on Windows 7',
'browser' => '*googlechrome',
'host' => self::TEST_HUB,
'port' => self::TEST_PORT,
),
Modify	
  MarkTaskDoneTest	
  
<?php
/**
* Class MarkTaskDoneTest
*
* @group Selenium
*/
require_once 'TestCase.php';
class MarkTaskDoneTest extends TestCase
{
public function testMarkTestAsDone()
{
$this->open("/");
$this->click("link=login");
$this->waitForPageToLoad("30000");
$this->type("id=email", TestCase::USERNAME);
$this->type("id=password", TestCase::PASSWORD);
$this->click("id=signin");
$this->waitForPageToLoad("30000");
$this->click("link=Test demo");
$this->waitForPageToLoad("30000");
$this->assertEquals("Done", $this->getText("xpath=//th[5]"));
$this->click("link=[EDIT]");
$this->waitForPageToLoad("30000");
$this->assertTrue($this->isElementPresent("id=done"));
$this->click("link=sign off");
$this->waitForPageToLoad("30000");
}
}
45
Require the TestCase
and extend it
Running	
  test
46
47
Benefits
• run	
  your	
  tests	
  on	
  mul'ple	
  browsers
• detect	
  flaws	
  in	
  specific	
  browsers	
  (e.g.	
  IE6)
-­‐ adapt	
  your	
  apps	
  to	
  solve	
  these	
  flaws
48
Mul'ple	
  Node	
  Setup
49
The	
  GRID
50
• Procedure
-­‐ centralized	
  server	
  (HUB)
-­‐ commands	
  clients	
  (nodes)	
  registered
-­‐ and	
  executes	
  the	
  tests
• Goal
-­‐ allow	
  for	
  automa'on
-­‐ adding	
  clients	
  as	
  you	
  go
Selenium	
  Grid	
  Setup
51
Selenium Testing
CI Server Windows
"HUB"
Linux client
"NODE"
CI executes tests
Windows HUB launches
Selenium node clients
to execute tests
Windows Server collects
feedback from the Citrix
client nodes and reports
back to CI Server
Windows client
"NODE"
Mac OS X client
"NODE"
Continuous User Acceptance Testing
Star'ng	
  the	
  server	
  [HUB]
52
"C:Program FilesJavajre7binjava.exe"
-jar "C:Jarselenium-server-standalone-2.28.0.jar"
-role hub
-port 12666
Star'ng	
  the	
  client	
  [NODE]
53
"C:Program FilesJavajre7binjava.exe"
-jar "C:Jarselenium-server-standalone-2.28.0.jar"
-role node
-host 192.168.56.103
-port 13666
-hub http://192.168.56.101:12666/grid/register
Mul'ple	
  nodes
54
Problem
55
Modify	
  Base	
  TestCase
56
<?php
require_once 'PHPUnit/Extensions/SeleniumTestCase.php';
class TestCase extends PHPUnit_Extensions_SeleniumTestCase
{
const TEST_HUB_WIN = '192.168.56.101';
const TEST_HUB_MAC = '192.168.56.1';
const TEST_HUB_LINUX = '192.168.56.102';
const TEST_PORT = 13666;
const USERNAME = 'dragonbe+tek13@gmail.com';
const PASSWORD = 'test1234';
const BASURL = 'http://www.theialive.com';
public static $browsers = array (
array (
'name' => 'Internet Explorer 8 on Windows 7', 'browser' => '*iexplore',
'host' => self::TEST_HUB_WIN, 'port' => self::TEST_PORT,
),
array (
'name' => 'Firefox on Mac OS X', 'browser' => '*firefox',
'host' => self::TEST_HUB_MAC, 'port' => self::TEST_PORT,
),
array (
'name' => 'Google Chrome on Linux', 'browser' => '*googlechrome',
'host' => self::TEST_HUB_LINUX, 'port' => self::TEST_PORT,
),
);
protected function setUp()
{
$this->setBrowserUrl(self::BASURL);
}
}
More	
  informa'on
57
seleniumhq.org
58
phpunit.de
59
http://www.phpunit.de/manual/3.5/en/selenium.html
Credits
60
• michelangelo:	
  hTp://www.flickr.com/photos/akrabat/
8784318813
• apple	
  store:	
  hTp://www.flickr.com/photos/jtjdt/3571748777
• checklist:	
  hTp://www.flickr.com/photos/alancleaver/4439276478
• flat	
  're:	
  hTp://www.flickr.com/photos/anijdam/2468493546/
• first	
  place:	
  hTp://www.flickr.com/photos/evelynishere/
3417340248/
• gears:	
  hTp://www.flickr.com/photos/wwarby/4782904694
• steps:	
  hTp://www.flickr.com/photos/ben_salter/1407168763
• browsers:	
  hTp://www.flickr.com/photos/richoz/3791167457
• informa'on:	
  hTp://www.flickr.com/photos/twicepix/
2650241408/
• elephpant:	
  hTp://www.flickr.com/photos/drewm/3191872515
Contact
61
Michelangelo van Dam
Zend Certified Engineer
email: michelangelo@in2it.be
Contact us for
Consultancy - Training - QA - Webdesign
62
https://joind.in/9080
Thank	
  you
63

Mais conteúdo relacionado

Mais procurados

https://www.facebook.com/valdyna.monna?fref=ts
https://www.facebook.com/valdyna.monna?fref=tshttps://www.facebook.com/valdyna.monna?fref=ts
https://www.facebook.com/valdyna.monna?fref=ts
Arif Alexi
 
HTML5 & The Open Web - at Nackademin
HTML5 & The Open Web -  at NackademinHTML5 & The Open Web -  at Nackademin
HTML5 & The Open Web - at Nackademin
Robert Nyman
 
What the heck went wrong?
What the heck went wrong?What the heck went wrong?
What the heck went wrong?
Andy McKay
 
Creating the interfaces of the future with the APIs of today
Creating the interfaces of the future with the APIs of todayCreating the interfaces of the future with the APIs of today
Creating the interfaces of the future with the APIs of today
gerbille
 
Websockets talk at Rubyconf Uruguay 2010
Websockets talk at Rubyconf Uruguay 2010Websockets talk at Rubyconf Uruguay 2010
Websockets talk at Rubyconf Uruguay 2010
Ismael Celis
 

Mais procurados (20)

JavaScript & HTML5 - Brave New World
JavaScript & HTML5 - Brave New WorldJavaScript & HTML5 - Brave New World
JavaScript & HTML5 - Brave New World
 
Better Bullshit Driven Development [SeleniumCamp 2017]
Better Bullshit Driven Development [SeleniumCamp 2017]Better Bullshit Driven Development [SeleniumCamp 2017]
Better Bullshit Driven Development [SeleniumCamp 2017]
 
HTML5 JavaScript APIs
HTML5 JavaScript APIsHTML5 JavaScript APIs
HTML5 JavaScript APIs
 
Beyond PHP - it's not (just) about the code
Beyond PHP - it's not (just) about the codeBeyond PHP - it's not (just) about the code
Beyond PHP - it's not (just) about the code
 
soft-shake.ch - Hands on Node.js
soft-shake.ch - Hands on Node.jssoft-shake.ch - Hands on Node.js
soft-shake.ch - Hands on Node.js
 
HTML5: friend or foe (to Flash)?
HTML5: friend or foe (to Flash)?HTML5: friend or foe (to Flash)?
HTML5: friend or foe (to Flash)?
 
Send.php
Send.phpSend.php
Send.php
 
Getting started with TDD - Confoo 2014
Getting started with TDD - Confoo 2014Getting started with TDD - Confoo 2014
Getting started with TDD - Confoo 2014
 
https://www.facebook.com/valdyna.monna?fref=ts
https://www.facebook.com/valdyna.monna?fref=tshttps://www.facebook.com/valdyna.monna?fref=ts
https://www.facebook.com/valdyna.monna?fref=ts
 
My app is secure... I think
My app is secure... I thinkMy app is secure... I think
My app is secure... I think
 
HTML5 & The Open Web - at Nackademin
HTML5 & The Open Web -  at NackademinHTML5 & The Open Web -  at Nackademin
HTML5 & The Open Web - at Nackademin
 
YUI 3
YUI 3YUI 3
YUI 3
 
What the heck went wrong?
What the heck went wrong?What the heck went wrong?
What the heck went wrong?
 
Continuous testing In PHP
Continuous testing In PHPContinuous testing In PHP
Continuous testing In PHP
 
Sane Async Patterns
Sane Async PatternsSane Async Patterns
Sane Async Patterns
 
The Screenplay Pattern: Better Interactions for Better Automation
The Screenplay Pattern: Better Interactions for Better AutomationThe Screenplay Pattern: Better Interactions for Better Automation
The Screenplay Pattern: Better Interactions for Better Automation
 
Commencer avec le TDD
Commencer avec le TDDCommencer avec le TDD
Commencer avec le TDD
 
My app is secure... I think
My app is secure... I thinkMy app is secure... I think
My app is secure... I think
 
Creating the interfaces of the future with the APIs of today
Creating the interfaces of the future with the APIs of todayCreating the interfaces of the future with the APIs of today
Creating the interfaces of the future with the APIs of today
 
Websockets talk at Rubyconf Uruguay 2010
Websockets talk at Rubyconf Uruguay 2010Websockets talk at Rubyconf Uruguay 2010
Websockets talk at Rubyconf Uruguay 2010
 

Semelhante a UA Testing with Selenium and PHPUnit - ZendCon 2013

symfony on action - WebTech 207
symfony on action - WebTech 207symfony on action - WebTech 207
symfony on action - WebTech 207
patter
 
Quality Assurance for PHP projects - ZendCon 2012
Quality Assurance for PHP projects - ZendCon 2012Quality Assurance for PHP projects - ZendCon 2012
Quality Assurance for PHP projects - ZendCon 2012
Michelangelo van Dam
 
EPHPC Webinar Slides: Unit Testing by Arthur Purnama
EPHPC Webinar Slides: Unit Testing by Arthur PurnamaEPHPC Webinar Slides: Unit Testing by Arthur Purnama
EPHPC Webinar Slides: Unit Testing by Arthur Purnama
Enterprise PHP Center
 
Phpne august-2012-symfony-components-friends
Phpne august-2012-symfony-components-friendsPhpne august-2012-symfony-components-friends
Phpne august-2012-symfony-components-friends
Michael Peacock
 
Selenium rc presentation_20110104
Selenium rc presentation_20110104Selenium rc presentation_20110104
Selenium rc presentation_20110104
Michael Salvucci
 
09 - express nodes on the right angle - vitaliy basyuk - it event 2013 (5)
09 - express nodes on the right angle - vitaliy basyuk - it event 2013 (5)09 - express nodes on the right angle - vitaliy basyuk - it event 2013 (5)
09 - express nodes on the right angle - vitaliy basyuk - it event 2013 (5)
Igor Bronovskyy
 

Semelhante a UA Testing with Selenium and PHPUnit - ZendCon 2013 (20)

UA testing with Selenium and PHPUnit - PFCongres 2013
UA testing with Selenium and PHPUnit - PFCongres 2013UA testing with Selenium and PHPUnit - PFCongres 2013
UA testing with Selenium and PHPUnit - PFCongres 2013
 
Better Testing With PHP Unit
Better Testing With PHP UnitBetter Testing With PHP Unit
Better Testing With PHP Unit
 
DrupalCon Dublin 2016 - Automated browser testing with Nightwatch.js
DrupalCon Dublin 2016 - Automated browser testing with Nightwatch.jsDrupalCon Dublin 2016 - Automated browser testing with Nightwatch.js
DrupalCon Dublin 2016 - Automated browser testing with Nightwatch.js
 
Selenium
SeleniumSelenium
Selenium
 
Browser testing with nightwatch.js - Drupal Europe
Browser testing with nightwatch.js - Drupal EuropeBrowser testing with nightwatch.js - Drupal Europe
Browser testing with nightwatch.js - Drupal Europe
 
Workshop quality assurance for php projects tek12
Workshop quality assurance for php projects tek12Workshop quality assurance for php projects tek12
Workshop quality assurance for php projects tek12
 
symfony on action - WebTech 207
symfony on action - WebTech 207symfony on action - WebTech 207
symfony on action - WebTech 207
 
Quality Assurance for PHP projects - ZendCon 2012
Quality Assurance for PHP projects - ZendCon 2012Quality Assurance for PHP projects - ZendCon 2012
Quality Assurance for PHP projects - ZendCon 2012
 
EPHPC Webinar Slides: Unit Testing by Arthur Purnama
EPHPC Webinar Slides: Unit Testing by Arthur PurnamaEPHPC Webinar Slides: Unit Testing by Arthur Purnama
EPHPC Webinar Slides: Unit Testing by Arthur Purnama
 
Join the darkside: Selenium testing with Nightwatch.js
Join the darkside: Selenium testing with Nightwatch.jsJoin the darkside: Selenium testing with Nightwatch.js
Join the darkside: Selenium testing with Nightwatch.js
 
Charla EHU Noviembre 2014 - Desarrollo Web
Charla EHU Noviembre 2014 - Desarrollo WebCharla EHU Noviembre 2014 - Desarrollo Web
Charla EHU Noviembre 2014 - Desarrollo Web
 
Phpne august-2012-symfony-components-friends
Phpne august-2012-symfony-components-friendsPhpne august-2012-symfony-components-friends
Phpne august-2012-symfony-components-friends
 
Unit testing after Zend Framework 1.8
Unit testing after Zend Framework 1.8Unit testing after Zend Framework 1.8
Unit testing after Zend Framework 1.8
 
20160905 - BrisJS - nightwatch testing
20160905 - BrisJS - nightwatch testing20160905 - BrisJS - nightwatch testing
20160905 - BrisJS - nightwatch testing
 
Unit testing with zend framework tek11
Unit testing with zend framework tek11Unit testing with zend framework tek11
Unit testing with zend framework tek11
 
Selenium RC Presentation 20110104
Selenium RC Presentation 20110104Selenium RC Presentation 20110104
Selenium RC Presentation 20110104
 
Selenium rc presentation_20110104
Selenium rc presentation_20110104Selenium rc presentation_20110104
Selenium rc presentation_20110104
 
Leveling Up With Unit Testing - php[tek] 2023
Leveling Up With Unit Testing - php[tek] 2023Leveling Up With Unit Testing - php[tek] 2023
Leveling Up With Unit Testing - php[tek] 2023
 
Symfony2 from the Trenches
Symfony2 from the TrenchesSymfony2 from the Trenches
Symfony2 from the Trenches
 
09 - express nodes on the right angle - vitaliy basyuk - it event 2013 (5)
09 - express nodes on the right angle - vitaliy basyuk - it event 2013 (5)09 - express nodes on the right angle - vitaliy basyuk - it event 2013 (5)
09 - express nodes on the right angle - vitaliy basyuk - it event 2013 (5)
 

Mais de Michelangelo van Dam

Mais de Michelangelo van Dam (20)

GDPR Art. 25 - Privacy by design and default
GDPR Art. 25 - Privacy by design and defaultGDPR Art. 25 - Privacy by design and default
GDPR Art. 25 - Privacy by design and default
 
Moving from app services to azure functions
Moving from app services to azure functionsMoving from app services to azure functions
Moving from app services to azure functions
 
Privacy by design
Privacy by designPrivacy by design
Privacy by design
 
DevOps or DevSecOps
DevOps or DevSecOpsDevOps or DevSecOps
DevOps or DevSecOps
 
Privacy by design
Privacy by designPrivacy by design
Privacy by design
 
Continuous deployment 2.0
Continuous deployment 2.0Continuous deployment 2.0
Continuous deployment 2.0
 
Let your tests drive your code
Let your tests drive your codeLet your tests drive your code
Let your tests drive your code
 
General Data Protection Regulation, a developer's story
General Data Protection Regulation, a developer's storyGeneral Data Protection Regulation, a developer's story
General Data Protection Regulation, a developer's story
 
Leveraging a distributed architecture to your advantage
Leveraging a distributed architecture to your advantageLeveraging a distributed architecture to your advantage
Leveraging a distributed architecture to your advantage
 
The road to php 7.1
The road to php 7.1The road to php 7.1
The road to php 7.1
 
Open source for a successful business
Open source for a successful businessOpen source for a successful business
Open source for a successful business
 
Decouple your framework now, thank me later
Decouple your framework now, thank me laterDecouple your framework now, thank me later
Decouple your framework now, thank me later
 
Deploy to azure in less then 15 minutes
Deploy to azure in less then 15 minutesDeploy to azure in less then 15 minutes
Deploy to azure in less then 15 minutes
 
Azure and OSS, a match made in heaven
Azure and OSS, a match made in heavenAzure and OSS, a match made in heaven
Azure and OSS, a match made in heaven
 
Getting hands dirty with php7
Getting hands dirty with php7Getting hands dirty with php7
Getting hands dirty with php7
 
Create, test, secure, repeat
Create, test, secure, repeatCreate, test, secure, repeat
Create, test, secure, repeat
 
The Continuous PHP Pipeline
The Continuous PHP PipelineThe Continuous PHP Pipeline
The Continuous PHP Pipeline
 
PHPUnit Episode iv.iii: Return of the tests
PHPUnit Episode iv.iii: Return of the testsPHPUnit Episode iv.iii: Return of the tests
PHPUnit Episode iv.iii: Return of the tests
 
Easily extend your existing php app with an api
Easily extend your existing php app with an apiEasily extend your existing php app with an api
Easily extend your existing php app with an api
 
Your code are my tests
Your code are my testsYour code are my tests
Your code are my tests
 

Último

Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 

Último (20)

2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of Brazil
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 

UA Testing with Selenium and PHPUnit - ZendCon 2013

  • 1. UA  Tes'ng  with Selenium  and  PHPUnit ZendCon  2013,  Santa  Clara
  • 2. 2 • PHP  Consultant • President  PHPBenelux • Conference  speaker Michelangelo  van  Dam
  • 3. 3
  • 4. Today’s  goal • Set  up  and  use  Selenium  IDE • Record  UA  tests • Convert  to  PHPUnit • Run  con'nuously • Mul'  browser  support 4
  • 5. 5 DISCLAIMER S E L E N I U M T E S T S A R E N OT A REPLACEMENT FOR REGULAR UNIT TESTING. THEY ONLY PROVIDE AN ADDITIONAL SET OF TESTS FOCUSED ON USER ACCEPTANCE AND USER EXPERIENCE TESTING. For more information about unit testing, please see my other material on www.slideshare.net and www.speakerdeck.com. Search for “dragonbe”!
  • 7. 7 “Acceptance testing is a test conducted to determine if the requirements of a specification or contract are met.” -- source: wikipedia
  • 8. Checklist  for  web  applica'ons 8
  • 9. 9 Func'onal  tes'ng • Test  func'onal  requirements -­‐ e.g.  no  access  to  profile  without  authen'ca'on • Test  UI  elements  on  the  web  interface -­‐ e.g.  buTons,  form  elements,  AJAX  controls,  …
  • 10. A  word  of  cau'on! 10 • UA  tests  only  test  generated  output -­‐ not  a  replacement  for  unit  tes'ng • UA  tests  are  heavily  depending  on  DOM -­‐ changes  to  the  DOM  might  lead  to  failing  UAT
  • 12. Selenium  to  the  rescue 12
  • 14. Get  the  plugin  (demo) 14
  • 15.
  • 17. Pick  a  test  case 17
  • 19. Verify  this  issue  on  PROD 19
  • 20. 20
  • 22. Run  test  to  see  it’s  fixed 22
  • 23. 23
  • 24. 24 Save  your  test  as  .html
  • 27. PHPUnit  to  the  rescue 27
  • 29. The  PHPUnit  TestCase 29 <?php class Example extends PHPUnit_Extensions_SeleniumTestCase { protected function setUp() { $this->setBrowser("*chrome"); $this->setBrowserUrl("http://www.theialive.com/"); } public function testMyTestCase() { $this->open("/"); $this->click("link=login"); $this->waitForPageToLoad("30000"); $this->type("id=email", "dragonbe+tek13@gmail.com"); $this->type("id=password", "test1234"); $this->click("id=signin"); $this->waitForPageToLoad("30000"); $this->click("link=Test demo"); $this->waitForPageToLoad("30000"); $this->assertEquals("Done", $this->getText("xpath=//th[5]")); $this->click("link=[EDIT]"); $this->waitForPageToLoad("30000"); $this->assertTrue($this->isElementPresent("id=done")); $this->click("link=sign off"); $this->waitForPageToLoad("30000"); } } ?>
  • 30. Change  class  name 30 <?php class Example extends PHPUnit_Extensions_SeleniumTestCase { protected function setUp() { $this->setBrowser("*chrome"); $this->setBrowserUrl("http://www.theialive.com/"); } public function testMyTestCase() { $this->open("/"); $this->click("link=login"); $this->waitForPageToLoad("30000"); $this->type("id=email", "dragonbe+tek13@gmail.com"); $this->type("id=password", "test1234"); $this->click("id=signin"); $this->waitForPageToLoad("30000"); $this->click("link=Test demo"); $this->waitForPageToLoad("30000"); $this->assertEquals("Done", $this->getText("xpath=//th[5]")); $this->click("link=[EDIT]"); $this->waitForPageToLoad("30000"); $this->assertTrue($this->isElementPresent("id=done")); $this->click("link=sign off"); $this->waitForPageToLoad("30000"); } } ?> class MarkTaskDoneTest extends PHPUnit_Extensions_SeleniumTestCase
  • 31. The  PHPUnit  TestCase 31 <?php class MarkTaskDoneTest extends PHPUnit_Extensions_SeleniumTestCase { protected function setUp() { $this->setBrowser("*chrome"); $this->setBrowserUrl("http://www.theialive.com/"); } public function testMyTestCase() { $this->open("/"); $this->click("link=login"); $this->waitForPageToLoad("30000"); $this->type("id=email", "dragonbe+tek13@gmail.com"); $this->type("id=password", "test1234"); $this->click("id=signin"); $this->waitForPageToLoad("30000"); $this->click("link=Test demo"); $this->waitForPageToLoad("30000"); $this->assertEquals("Done", $this->getText("xpath=//th[5]")); $this->click("link=[EDIT]"); $this->waitForPageToLoad("30000"); $this->assertTrue($this->isElementPresent("id=done")); $this->click("link=sign off"); $this->waitForPageToLoad("30000"); } } ?> protected function setUp() { $this->setBrowser("*iexplore"); $this->setBrowserUrl("http://www.theialive.com/"); $this->setHost('192.168.56.101'); $this->setPort(12666); }
  • 32. Meaningful  method  name <?php class MarkTaskDoneTest extends PHPUnit_Extensions_SeleniumTestCase { protected function setUp() { $this->setBrowser("*iexplore"); $this->setBrowserUrl("http://www.theialive.com/"); $this->setHost('192.168.56.101'); $this->setPort(12666); } public function testMyTestCase() { $this->open("/"); $this->click("link=login"); $this->waitForPageToLoad("30000"); $this->type("id=email", "dragonbe+tek13@gmail.com"); $this->type("id=password", "test1234"); $this->click("id=signin"); $this->waitForPageToLoad("30000"); $this->click("link=Test demo"); $this->waitForPageToLoad("30000"); $this->assertEquals("Done", $this->getText("xpath=//th[5]")); $this->click("link=[EDIT]"); $this->waitForPageToLoad("30000"); $this->assertTrue($this->isElementPresent("id=done")); $this->click("link=sign off"); $this->waitForPageToLoad("30000"); } } ?> 32 public function testMarkTestAsDone()
  • 34. Now  run  your  tests 34
  • 35.
  • 36. How  it  runs  on  the  node 36
  • 37.
  • 38. Advantages 38 • You  can  start  tes'ng  immediately • Even  test  “hard  to  test”  kind  of  situa'ons • More  nodes  for  parallel  tes'ng • Tes'ng  different  browsers  and  plaforms • Con'nuous  Integra'on  possible
  • 41. Base  TestCase 41 <?php require_once 'PHPUnit/Extensions/SeleniumTestCase.php'; class TestCase extends PHPUnit_Extensions_SeleniumTestCase { //const TEST_HUB = '217.21.179.192'; const TEST_HUB = '192.168.56.101'; const TEST_PORT = 12666; const USERNAME = 'dragonbe+tek13@gmail.com'; const PASSWORD = 'test1234'; const BASURL = 'http://www.theialive.com'; public static $browsers = array ( array ( 'name' => 'Internet Explorer 8 on Windows 7', 'browser' => '*iexplore', 'host' => self::TEST_HUB, 'port' => self::TEST_PORT, ), array ( 'name' => 'Firefox on Windows 7', 'browser' => '*firefox', 'host' => self::TEST_HUB, 'port' => self::TEST_PORT, ), array ( 'name' => 'Google Chrome on Windows 7', 'browser' => '*googlechrome', 'host' => self::TEST_HUB, 'port' => self::TEST_PORT, ), ); protected function setUp() { $this->setBrowserUrl(self::BASURL); } }
  • 42. Base  TestCase 42 <?php require_once 'PHPUnit/Extensions/SeleniumTestCase.php'; class TestCase extends PHPUnit_Extensions_SeleniumTestCase { //const TEST_HUB = '217.21.179.192'; const TEST_HUB = '192.168.56.101'; const TEST_PORT = 12666; const USERNAME = 'dragonbe+tek13@gmail.com'; const PASSWORD = 'test1234'; const BASURL = 'http://www.theialive.com'; public static $browsers = array ( array ( 'name' => 'Internet Explorer 8 on Windows 7', 'browser' => '*iexplore', 'host' => self::TEST_HUB, 'port' => self::TEST_PORT, ), array ( 'name' => 'Firefox on Windows 7', 'browser' => '*firefox', 'host' => self::TEST_HUB, 'port' => self::TEST_PORT, ), array ( 'name' => 'Google Chrome on Windows 7', 'browser' => '*googlechrome', 'host' => self::TEST_HUB, 'port' => self::TEST_PORT, ), ); protected function setUp() { $this->setBrowserUrl(self::BASURL); } } array ( 'name' => 'Internet Explorer 8 on Windows 7', 'browser' => '*iexplore', 'host' => self::TEST_HUB, 'port' => self::TEST_PORT, ),
  • 43. Base  TestCase 43 <?php require_once 'PHPUnit/Extensions/SeleniumTestCase.php'; class TestCase extends PHPUnit_Extensions_SeleniumTestCase { //const TEST_HUB = '217.21.179.192'; const TEST_HUB = '192.168.56.101'; const TEST_PORT = 12666; const USERNAME = 'dragonbe+tek13@gmail.com'; const PASSWORD = 'test1234'; const BASURL = 'http://www.theialive.com'; public static $browsers = array ( array ( 'name' => 'Internet Explorer 8 on Windows 7', 'browser' => '*iexplore', 'host' => self::TEST_HUB, 'port' => self::TEST_PORT, ), array ( 'name' => 'Firefox on Windows 7', 'browser' => '*firefox', 'host' => self::TEST_HUB, 'port' => self::TEST_PORT, ), array ( 'name' => 'Google Chrome on Windows 7', 'browser' => '*googlechrome', 'host' => self::TEST_HUB, 'port' => self::TEST_PORT, ), ); protected function setUp() { $this->setBrowserUrl(self::BASURL); } } array ( 'name' => 'Firefox on Windows 7', 'browser' => '*firefox', 'host' => self::TEST_HUB, 'port' => self::TEST_PORT, ),
  • 44. Base  TestCase 44 <?php require_once 'PHPUnit/Extensions/SeleniumTestCase.php'; class TestCase extends PHPUnit_Extensions_SeleniumTestCase { //const TEST_HUB = '217.21.179.192'; const TEST_HUB = '192.168.56.101'; const TEST_PORT = 12666; const USERNAME = 'dragonbe+tek13@gmail.com'; const PASSWORD = 'test1234'; const BASURL = 'http://www.theialive.com'; public static $browsers = array ( array ( 'name' => 'Internet Explorer 8 on Windows 7', 'browser' => '*iexplore', 'host' => self::TEST_HUB, 'port' => self::TEST_PORT, ), array ( 'name' => 'Firefox on Windows 7', 'browser' => '*firefox', 'host' => self::TEST_HUB, 'port' => self::TEST_PORT, ), array ( 'name' => 'Google Chrome on Windows 7', 'browser' => '*googlechrome', 'host' => self::TEST_HUB, 'port' => self::TEST_PORT, ), ); protected function setUp() { $this->setBrowserUrl(self::BASURL); } } array ( 'name' => 'Google Chrome on Windows 7', 'browser' => '*googlechrome', 'host' => self::TEST_HUB, 'port' => self::TEST_PORT, ),
  • 45. Modify  MarkTaskDoneTest   <?php /** * Class MarkTaskDoneTest * * @group Selenium */ require_once 'TestCase.php'; class MarkTaskDoneTest extends TestCase { public function testMarkTestAsDone() { $this->open("/"); $this->click("link=login"); $this->waitForPageToLoad("30000"); $this->type("id=email", TestCase::USERNAME); $this->type("id=password", TestCase::PASSWORD); $this->click("id=signin"); $this->waitForPageToLoad("30000"); $this->click("link=Test demo"); $this->waitForPageToLoad("30000"); $this->assertEquals("Done", $this->getText("xpath=//th[5]")); $this->click("link=[EDIT]"); $this->waitForPageToLoad("30000"); $this->assertTrue($this->isElementPresent("id=done")); $this->click("link=sign off"); $this->waitForPageToLoad("30000"); } } 45 Require the TestCase and extend it
  • 47. 47
  • 48. Benefits • run  your  tests  on  mul'ple  browsers • detect  flaws  in  specific  browsers  (e.g.  IE6) -­‐ adapt  your  apps  to  solve  these  flaws 48
  • 50. The  GRID 50 • Procedure -­‐ centralized  server  (HUB) -­‐ commands  clients  (nodes)  registered -­‐ and  executes  the  tests • Goal -­‐ allow  for  automa'on -­‐ adding  clients  as  you  go
  • 51. Selenium  Grid  Setup 51 Selenium Testing CI Server Windows "HUB" Linux client "NODE" CI executes tests Windows HUB launches Selenium node clients to execute tests Windows Server collects feedback from the Citrix client nodes and reports back to CI Server Windows client "NODE" Mac OS X client "NODE" Continuous User Acceptance Testing
  • 52. Star'ng  the  server  [HUB] 52 "C:Program FilesJavajre7binjava.exe" -jar "C:Jarselenium-server-standalone-2.28.0.jar" -role hub -port 12666
  • 53. Star'ng  the  client  [NODE] 53 "C:Program FilesJavajre7binjava.exe" -jar "C:Jarselenium-server-standalone-2.28.0.jar" -role node -host 192.168.56.103 -port 13666 -hub http://192.168.56.101:12666/grid/register
  • 56. Modify  Base  TestCase 56 <?php require_once 'PHPUnit/Extensions/SeleniumTestCase.php'; class TestCase extends PHPUnit_Extensions_SeleniumTestCase { const TEST_HUB_WIN = '192.168.56.101'; const TEST_HUB_MAC = '192.168.56.1'; const TEST_HUB_LINUX = '192.168.56.102'; const TEST_PORT = 13666; const USERNAME = 'dragonbe+tek13@gmail.com'; const PASSWORD = 'test1234'; const BASURL = 'http://www.theialive.com'; public static $browsers = array ( array ( 'name' => 'Internet Explorer 8 on Windows 7', 'browser' => '*iexplore', 'host' => self::TEST_HUB_WIN, 'port' => self::TEST_PORT, ), array ( 'name' => 'Firefox on Mac OS X', 'browser' => '*firefox', 'host' => self::TEST_HUB_MAC, 'port' => self::TEST_PORT, ), array ( 'name' => 'Google Chrome on Linux', 'browser' => '*googlechrome', 'host' => self::TEST_HUB_LINUX, 'port' => self::TEST_PORT, ), ); protected function setUp() { $this->setBrowserUrl(self::BASURL); } }
  • 60. Credits 60 • michelangelo:  hTp://www.flickr.com/photos/akrabat/ 8784318813 • apple  store:  hTp://www.flickr.com/photos/jtjdt/3571748777 • checklist:  hTp://www.flickr.com/photos/alancleaver/4439276478 • flat  're:  hTp://www.flickr.com/photos/anijdam/2468493546/ • first  place:  hTp://www.flickr.com/photos/evelynishere/ 3417340248/ • gears:  hTp://www.flickr.com/photos/wwarby/4782904694 • steps:  hTp://www.flickr.com/photos/ben_salter/1407168763 • browsers:  hTp://www.flickr.com/photos/richoz/3791167457 • informa'on:  hTp://www.flickr.com/photos/twicepix/ 2650241408/ • elephpant:  hTp://www.flickr.com/photos/drewm/3191872515
  • 61. Contact 61 Michelangelo van Dam Zend Certified Engineer email: michelangelo@in2it.be Contact us for Consultancy - Training - QA - Webdesign