Skip to content

PHP Facebook Webdriver & PHPUnit Example Project with Page Object Model

Notifications You must be signed in to change notification settings

sridharbandi/Selenium-PHPUnit-Template

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PHP Facebook Webdriver & PHPUnit Example Project with Page Object Model

How to use?

Create the Page Objects of your Web application under pageobjects package, call those Page Objects in PHPUnit tests under tests package (Sample Page Objects, testcase included in this template)

How to run?

To install the dependencies issue the below commands in project root directory

composer update

PHP and Composer to be installed as prerequisite.

Run Selenium Server with required Webdriver binaries, example with chromedriver as below

java  -Dwebdriver.chrome.driver=/path/to/chromedriver  -jar /path/to/selenium server/selenium-server-standalone-x.x.x.jar

To run the tests issue the below command in project root directory

./vendor/bin/phpunit tests

By default it runs in Chrome browser, you can specify which browser to use as well

./vendor/bin/phpunit tests firefox

Browsers added in this template are

  • chrome
  • firefox
  • ie
  • opera
  • edge
  • safari
  • phantomjs

Feel free to modify it to your own needs :)

About

PHP Facebook Webdriver & PHPUnit Example Project with Page Object Model

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages