<?xml version="1.0"?>
<rss version="2.0">
  <channel>
    <title>PHPDeveloper.org</title>
    <link>http://www.phpdeveloper.org</link>
    <description>Up-to-the Minute PHP News, views and community</description>
    <language>en-us</language>
    <pubDate>Thu, 23 May 2013 17:17:29 -0500</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[Matt Frost: Starting with Selenium (and Headless on a VM)]]></title>
      <guid>http://www.phpdeveloper.org/news/18404</guid>
      <link>http://www.phpdeveloper.org/news/18404</link>
      <description><![CDATA[<p>
<i>Matt Frost</i> has posted a two part series of some of his experiences in <a href="http://shortwhitebaldguy.com/blog/2012/08/starting-with-selenium">setting up Selenium</a> to <a href="http://shortwhitebaldguy.com/blog/2012/08/headless-selenium-from-your-vm">execute it in a VM</a> and run tests on your application.
</p>
<blockquote>
I was a little scared when it came to setting up Selenium, I figured it was going to be difficult to setup and configure. So I was pleasantly surprised when it really wasn't. So here are a few of the mistakes I made; since I use Vagrant to do all my development I actually grabbed Selenium and started from there. Not a good place to start, although as I found out later; not a total dead end.
</blockquote>
<p>
He includes <a href="http://shortwhitebaldguy.com/blog/2012/08/starting-with-selenium">the initial setup</a> of things like PHPUnit and the <a href="http://seleniumhq.org/download/">Selenium .jar file</a> as well as a sample test that loads a page and checks the title of the page. His <a href="http://shortwhitebaldguy.com/blog/2012/08/headless-selenium-from-your-vm">second post</a> shows how to set it up in the VM (using Vagrant, <a href="http://en.wikipedia.org/wiki/Xvfb">xvfb</a> to capture the output and Firefox to execute the tests). 
</p>]]></description>
      <pubDate>Mon, 27 Aug 2012 08:16:55 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Shashikant Jagtap's Blog: Enjoy 'MinkExtension' for Behat]]></title>
      <guid>http://www.phpdeveloper.org/news/17923</guid>
      <link>http://www.phpdeveloper.org/news/17923</link>
      <description><![CDATA[<p>
In <a href="http://lestbddphp.wordpress.com/2012/05/07/enjoy-minkextension-for-behat/">this new post</a> to his blog <i>Shashikant Jagtap</i> talks about a new extension for <a href="http://behat.org">Behat</a> (the BDD testing tool) that makes working with Mink even easier - <a href="https://github.com/Behat/MinkExtension">MinkExtension</a>.
</p>
<blockquote>
'<a href="https://github.com/Behat/MinkExtension">MinkExtension</a>' has been just released which has additional services for <a href="http://behat.org/">Behat</a>. This extension has 'Mink' instance for your 'FeatureContext' and 'SubContext'. UI testers would be happy now, as they don't need to create Mink instance every time in order to use Mink API's.
</blockquote>
<p>
He points you to <a href="https://github.com/Behat/MinkExtension-example">an example application</a> you can use to follow along. He includes the commands needed to install the dependencies via Composer and get this extension working (note: it requires PHP 5.4 for some of the traits stuff. If you don't want to use that, comment out the "TraitedFeatureContext.php" file). Also included are the commands to execute the tests with a <a href="http://seleniumhq.org/download/">Selenium</a> server and a list of a few handy new things this extension enables.
</p>]]></description>
      <pubDate>Tue, 08 May 2012 10:55:55 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[DZone.com: Selenium on Android]]></title>
      <guid>http://www.phpdeveloper.org/news/17835</guid>
      <link>http://www.phpdeveloper.org/news/17835</link>
      <description><![CDATA[<p>
On DZone.com there's a recent post from <i>Giorgio Sironi</i> looking at <a href="http://css.dzone.com/articles/selenium-android">running Selenium tests on the Android platform</a> via the <a href="http://phpunit.de">PHPUnit</a> Selenium interface.
</p>
<blockquote>
Testing web applications is not only based on unit and functional tests for the server-side (PHP, Java) and client-side (JavaScript) components, but also on end-to-end tests like the ones performed with Selenium. Selenium is capable of driving a real browser like Firefox in the same way a user would do, letting you express a test with a series of page to load, element selections, clicks and typed characters. [...] In this tutorial, we'll experiment with the Android Driver and set up a couple of tests to run inside an Android virtual device.
</blockquote>
<p>
He walks you through the basic setup of an Android environment (based on the <a href="http://source.android.com/source/initializing.html">Android SDK</a>) and how to start up the Android driver installed from <a href="http://code.google.com/p/selenium/downloads/list">the Selenium site</a>. An example test is included, showing how to make a request for a test page and checking its title as well as checking that the input from the "keyboard" is successful.
</p>]]></description>
      <pubDate>Wed, 18 Apr 2012 12:43:04 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[DZone.com: The Page Object pattern]]></title>
      <guid>http://www.phpdeveloper.org/news/17795</guid>
      <link>http://www.phpdeveloper.org/news/17795</link>
      <description><![CDATA[<p>
On DZone.com today there's a new tutorial from <i>Giorgia Sironi</i> giving an example of <a href="http://css.dzone.com/articles/page-object-pattern">working with the PageObject pattern</a> and how it's implemented to help with testing in the PHPUnit_Selenium plugin.
</p>
<blockquote>
In the realm of acceptance testing, a possibility for hooking into the application and exercising it end-to-end is to work through a user interface, which nowadays is in more and more cases web-based. The Page Object pattern is a way to model pages (intended as screens) of a web application as independent objects, and give them several responsibilities.
</blockquote>
<p>
The pattern sets up the resources to let you make queries against the page's contents, interacting with elements on the page, running common assertions on the contents and moving around on the site. He gives a more practical example of it in action (again, using PHPUnit_Selenium) to test a login page and evaluate a successful login.
</p>]]></description>
      <pubDate>Tue, 10 Apr 2012 09:05:39 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[DZone.com: PHPUnit_Selenium]]></title>
      <guid>http://www.phpdeveloper.org/news/17424</guid>
      <link>http://www.phpdeveloper.org/news/17424</link>
      <description><![CDATA[<p>
On DZone.com today <i>Giorgio Sironi</i> has a quick tutorial showing you how to set up and use the <a href="http://css.dzone.com/articles/phpunitselenium">PHPUnit_Selenium</a> component in the latest releases of the <a href="http://phpunit.de">popular testing software</a>.
</p>
<blockquote>
With the 1.2 release, PHPUnit_Selenium supports (basically) for the first time the Selenium 2 WebDriver API. While PHPUnit_Selenium already worked with Selenium 2, it did so only by using the Selenium 1 emulation included in the jar; now it provides an object-oriented API right natively supported in a base PHPUnit test case, shipped in PHPUnit's PEAR channel.
</blockquote>
<p>
He includes the steps you'll need to pull it from the PEAR channel and how to set up a test case based on the PHPUnit_Extensions_Selenium2TestCase object. He gives a few examples of how to select various components on the page (via CSS selectors and XPath), assert that the right information is there and interact with forms.
</p>]]></description>
      <pubDate>Fri, 20 Jan 2012 09:12:18 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[DZone.com: Open/Closed Principle on real world code]]></title>
      <guid>http://www.phpdeveloper.org/news/17389</guid>
      <link>http://www.phpdeveloper.org/news/17389</link>
      <description><![CDATA[<p>
In a new post to DZone.com <i>Giorgio Sironi</i> talks about the "open/closed principle" in software development and shows an example based on the design of the <a href="https://github.com/giorgiosironi/phpunit-selenium">PHPUnit_Selenium</a> project.
</p>
<blockquote>
This article shows an example of how the application of the Open/Closed Principle improved the design of a real project, the open source library <a href="https://github.com/giorgiosironi/phpunit-selenium">PHPUnit_Selenium</a>. These design concepts apply to every object-oriented language, including Java, Ruby or even C++. The <a href="http://butunclebob.com/ArticleS.UncleBob.PrinciplesOfOod">Open Closed Principle</a>, part of SOLID set, states that software should be open for extension and at the same time closed for modification.
</blockquote>
<p>
He starts with a little background on the project, pointing out that there's a Session object it uses for all of its testing with a magic "__call" method that handles any kind of method call to the object. This method has issues (dependencies, strict requirements for use) but can be refactored according to the Open/Closed idea to set up an array of anonymous functions that can be called as a "command". Examples of these types of classes are also included (one for the "click" action on a button and another for getting the current location).
</p>]]></description>
      <pubDate>Fri, 13 Jan 2012 09:05:53 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[DZone.com: Selenium 2 from PHP code]]></title>
      <guid>http://www.phpdeveloper.org/news/17135</guid>
      <link>http://www.phpdeveloper.org/news/17135</link>
      <description><![CDATA[<p>
On DZone.com today <i>Girogio Sironi</i> <a href="http://css.dzone.com/articles/selenium-2-php-code">shares some of his experiences</a> testing out the PHP bindings currently offered to work with <a href="http://seleniumhq.org/">Selenium</a>, the web application frontend testing tool that's become a standard over the past few years.
</p>
<blockquote>
After trying out Selenium 2, it was natural for me to look for its support in PHP code; however, there isn't an official PHP Api distributed on Selenium's website. I tested all the PHP bindings I could find to see which is the best choice today.
</blockquote>
<p>
He tried out a few different technologies: 
</p>
<ul>
<li><a href="https://github.com/sebastianbergmann/phpunit-selenium">PHPUnit_Selenium</a>
<li>Facebook's <a href="https://github.com/facebook/php-webdriver">php-webdriver</a>
<li>the <a href="http://code.google.com/p/php-webdriver-bindings/">php-webdriver-bindings</a> project
<li><a href="https://github.com/chibimagic/WebDriver-PHP/">WebDriver-PHP</a>
</ul>
<p>
The finishes the post with a quick summary for each of the offerings including strengths each has and situations where you might want to use them.
</p>]]></description>
      <pubDate>Wed, 16 Nov 2011 10:06:01 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Till Klampaeckel's Blog: Selenium vs. Saucelenium]]></title>
      <guid>http://www.phpdeveloper.org/news/15097</guid>
      <link>http://www.phpdeveloper.org/news/15097</link>
      <description><![CDATA[<p>
In <a href="http://till.klampaeckel.de/blog/archives/111-Selenium-Saucelenium-installation-and-dbus-xorg-woes.html">this new post</a> to his blog <i>Till Klampaeckel</i> talks about two tools for front-end interface testing - Selenium and <a href="http://github.com/saucelabs/saucelenium">Saucelenium</a> - and how he used the latter in his application testing.
</p>
<blockquote>
Selenium and Saucelenium have the same root - in fact Saucelenium is a Selenium fork. While the Selenium project seems to focus on 2.x currently, stable 1.x  development seems to really happen at Saucelabs. That is if you call a commit from January 22nd of this year active development.
</blockquote>
<p>
He talks about the installation process (guided by the README from <a href="http://github.com/till/saucelenium">his fork</a>) and the tool he had to install to get it to work for him - xserver-xorg. He includes a sample test to give you an idea of what can be done with the testing tool. It loads the page imitating Chrome and looks for certain text on two different pages as well as check one of the links.
</p>]]></description>
      <pubDate>Wed, 08 Sep 2010 13:48:03 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Web Builder Zone: The different kinds of testing]]></title>
      <guid>http://www.phpdeveloper.org/news/15060</guid>
      <link>http://www.phpdeveloper.org/news/15060</link>
      <description><![CDATA[<p>
On the Web Builder Zone (from <a href="http://dzone.com">DZone</a>) <i>Giorgio Sironi</i> has posted <a href="http://css.dzone.com/articles/different-kinds-testing">a new article</a> that talks about the different kinds of testing you can do on your application - both on the frontend and backend.
</p>
<blockquote>
Automated testing supports your constant effort in design and refactoring, and besides that ensures that your application actually works in a reliable and repeatable way. [...] In this article I'll describe the different categories of testing, as applied to a Zend Framework 1 application, but this classification pertains to every web application based on object-oriented programming. Since this kind of applications is obviously PHP-based, PHPUnit will be the tool of choice along with some of its standard extensions. 
</blockquote>
<p>
He looks at five different types of testing you can do on your application:
</p>
<ul>
<li>Unit testing
<li>Pragmatic unit testing
<li>Functional testing
<li>Integration testing
<li>Acceptance testing
</ul>
<p>
Not all of these can be done with <a href="http://phpunit.de">PHPUnit</a> on the backend, but they (mostly) have automated tools of their own like Selenium for frontend interface testing.
</p>]]></description>
      <pubDate>Wed, 01 Sep 2010 12:09:35 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[NetBeans Blog: Selenium plugin for PHP]]></title>
      <guid>http://www.phpdeveloper.org/news/12090</guid>
      <link>http://www.phpdeveloper.org/news/12090</link>
      <description><![CDATA[<p>
A <a href="http://blogs.sun.com/netbeansphp/entry/selenium_plugin_for_php">quick new post</a> to the NetBeans blog today points out the support for Selenium in the IDE. The <a href="http://wiki.netbeans.org/SeleniumPluginPHP">NetBeans wiki</a> has more information:
</p>
<blockquote>
Before trying Selenium in PHP be sure to have PHPUnit and Selenium_Testing packages installed. The recommended way to install both is using <a href="http://pear.php.net/">PEAR</a>. 
</blockquote>
<p>
The <a href="http://wiki.netbeans.org/SeleniumPluginPHP">wiki page</a> guides you through the creation of a simple testing setup complete with screenshots of the interface the whole way through. The <a href="http://wiki.netbeans.org/SeleniumPlugin">plugin page</a> has more details on running the tests.
</p>]]></description>
      <pubDate>Mon, 09 Mar 2009 09:36:31 -0500</pubDate>
    </item>
  </channel>
</rss>
