<?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>Sun, 19 May 2013 05:26:00 -0500</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[QaFoo.com: Webinar: Behavior Driven Development with Behat]]></title>
      <guid>http://www.phpdeveloper.org/news/19473</guid>
      <link>http://www.phpdeveloper.org/news/19473</link>
      <description><![CDATA[<p>
The QaFoo folks have <a href="http://qafoo.com/blog/042_webinar_bdd_behat.html">posted information about a webinar</a> they're putting on for those interested in using Behat for doing functional testing on their applications:
</p>
<blockquote>
I've already written two blog posts here about Behat: <a href="http://qafoo.com/blog/036_behavior_driven_development.html">Behavior Driven Development</a> and <a href="http://qafoo.com/blog/040_code_coverage_with_behat.html">Code Coverage with Behat</a>. If that made you curious or you wanted to learn about Behat anyway, I can highly recommend to join the free <a href="https://www.zend.com/en/company/news/event/1246_webinar-behavior-driven-development-with-behat">webinar on Behavior Driven Development with Behat</a> I'll be giving on May 8th 2013 on behalf of Qafoo in cooperation with Zend.
</blockquote>
<p>
As mentioned, the webinar is free to attend, but you'll need to <a href="http://www.zend.com/webinar/register/?eventNumber=575435768">sign up</a> to be able to attend.
</p>
Link: http://qafoo.com/blog/042_webinar_bdd_behat.html]]></description>
      <pubDate>Wed, 17 Apr 2013 10:44:21 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[QaFoo.com: Behavior Driven Development]]></title>
      <guid>http://www.phpdeveloper.org/news/19291</guid>
      <link>http://www.phpdeveloper.org/news/19291</link>
      <description><![CDATA[<p>
On the QaFoo blog today there's a new post looking at <a href="http://qafoo.com/blog/036_behavior_driven_development.html">behavior driven development</a> and a PHP-based tool that makes implementing it in your workflow simpler (<a href="http://behat.org/">Behat</a>).
</p>
<blockquote>
While unit, integration and system tests - especially combined with the methodology of Test Driven Development (TDD) - are great ways to push the technical correctness of an application forward, they miss out one important aspect: the customer. None of these methods verify that developers actually implement what the customer desires. <a href="https://en.wikipedia.org/wiki/Behavior-driven_development">Behavior Driven Development</a> (BDD) can help to bridge this gap.
</blockquote>
<p>
The introduce some of the basic concepts behind behavior driven development and include an example of a Gherkin-formatted test example checking a page to ensure if has the correct content. They briefly define the structure of the test then take it into a Behat context and show how it would be implemented.
</p>
<blockquote>
Of course, the examples shown above are only very rudimentary, missing e.g. variables and other advanced features. However, they should have explained what BDD is all about: Communication
</blockquote>]]></description>
      <pubDate>Fri, 08 Mar 2013 11:54:21 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Project: Major Codeception Update (BDD in PHP)]]></title>
      <guid>http://www.phpdeveloper.org/news/18333</guid>
      <link>http://www.phpdeveloper.org/news/18333</link>
      <description><![CDATA[<p>
The Codeception project (BDD testing in PHP) has gotten a <a href="http://codeception.com/08-07-2012/major-codeception-update.html">major update</a> to its feature set and has bumped up to v1.1:
</p>
<blockquote>
Many core classes were refactored to solve the common issues and reduce the level of dark magic inside. Only white magic left. And that's really cool 'cause you don't need to study to source code to implement your custom hooks now. Codeception is rapidly evolving to be the professional testing tool, ready to use by testsers and developers through out the PHP world.
</blockquote>
<p>
Improvements in this large update include an update to the method of test execution, "grabbers" (helper methods that can extract content from tests), the introduction of XPath support to locate items in the content pulled into the test and the integration with unit testing. Upgrade instructions are also included.
</p>]]></description>
      <pubDate>Wed, 08 Aug 2012 11:09:11 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Chris Hartjes' Blog: Simple API Testing Using Behat]]></title>
      <guid>http://www.phpdeveloper.org/news/17589</guid>
      <link>http://www.phpdeveloper.org/news/17589</link>
      <description><![CDATA[<p>
<i>Chris Hartjes</i> has taken some of his first steps to testing a web service with the help of the <a href="http://behat.org">Behat</a> BDD testing framework. In <a href="http://www.littlehart.net/atthekeyboard/2012/02/26/simple-api-testing-with-behat/">this new post</a> he shares some of that knowledge and a bit of code to help guide you if you'd like to get started yourself.
</p>
<blockquote>
I have been trying to push my JavaScript skills lately by first playing around with Node.js to get a feel for event-driven server-side coding and by trying to build something semi-useful using <a href="http://knockoutjs.com/">Knockout</a>. [...] After working with PHPUnit's "assert that the result matches expectations" philosophy, switching to using a behavioural approach has changed how I decide to approach actually testing something. 
</blockquote>
<p>
He shows how to define a "scenario" in a more recognizable sort of English. His example is testing a web service to ensure of a few things:
</p>
<ul>
<li>the response is JSON
<li>it contains at least one transaction
<li>the first transaction has an ID, contains two teams and has a description
</ul>
<p>
Included in the post is the resulting Behat test code (generated and modified with his testing details) and an example of the execution of the test.
</p>
<blockquote>
I think that the BDD approach maps better to a results-oriented methodology when it comes to testing: you are using real-life scenarios to make sure that you are getting back the results you are expecting. In the end. that is still the goal of testing.
</blockquote>]]></description>
      <pubDate>Mon, 27 Feb 2012 10:09:18 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Codeception Blog: Introduction to Codeception]]></title>
      <guid>http://www.phpdeveloper.org/news/17447</guid>
      <link>http://www.phpdeveloper.org/news/17447</link>
      <description><![CDATA[<p>
On the Codeception blog there's <a href="http://codeception.com/01-20-2012/starting-acceptance.html">an introduction to the Codeception tool</a>, a behavior-driven framework written in PHP (in the spirit of <a href="http://behat.org/">Behat</a>).
</p>
<blockquote>
How often do you see PHP projects with no line of test written? From my experience, this situation happens quite often. We should state the unpleasant fact that tests are not so popular around the PHP world. Surely, the advanced developers with 5+ years of experience in PHP and other programming languages understand importance of testing and PHPUnit usage. But juniors and seniors are just skipping testing and, therefore, produce unstable web applications.
</blockquote>
<p>
A code example of the framework in use is included in the post - a test on a class using methods like "wantTo", "amOnPage", "fillField" and "click". The <a href="http://codeception.com/install">installation</a> is pretty simple and it gives you a quick way to start working on acceptance, functional and unit tests. In BDD fashion, the tests are written in a more "natural language" than traditional <a href="http://phpunit.de">unit tests</a> making them easier for the non-developers (like QA) to write. Their example loads a page, fills in some form fields and submits the form to check the result.
</p>]]></description>
      <pubDate>Wed, 25 Jan 2012 10:19:59 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Alessandro Nadalin's Blog: Behaviour what?]]></title>
      <guid>http://www.phpdeveloper.org/news/16789</guid>
      <link>http://www.phpdeveloper.org/news/16789</link>
      <description><![CDATA[<p>
In a recent post to his blog <i>Alessandro Nadalin</i> looks at a <a href="http://www.odino.org/378/behaviour-driven-development-in-php">different approach to development</a> than the usual code-first, ask questions later style, behavior-driven development, and a tool that can help you follow this method - <a href="http://behat.org">Behat</a>.
</p>
<blockquote>
Although this requirement is not mandatory, BDD's power is leveraged by using stories. It basically assumes that instead of focusing on tests, we should start our development process writing down a story that a parser can translate into a test (a customer cares about features, not tests) a programmer can implement in order to verify that our software respects that story.
</blockquote>
<p>
He talks about installing Behat <a href="http://pear.behat.org/">via PEAR</a>, how it can integrate with Symfony (1.4) and an example of a sample story/test file that checks a few things against a basic page. He also points out an interesting and quite useful feature of Behat - outputting the tests in a HTML-formatted result that makes for easy reading by non-developers.
</p>]]></description>
      <pubDate>Tue, 30 Aug 2011 09:22:15 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Ibuildings techPortal: Beyond TDD with PHPSpec]]></title>
      <guid>http://www.phpdeveloper.org/news/16667</guid>
      <link>http://www.phpdeveloper.org/news/16667</link>
      <description><![CDATA[<p>
On the Ibuildings techPortal today there's a new post from <i>Marcello Duarte</i> following up on his previous post looking at behavior driven development (<a href="http://phpdeveloper.org/news/16640">here</a>) with <a href="http://techportal.ibuildings.com/2011/08/03/outside-in-behaviour-driven-development-in-php-part-2/">a look at PHPSpec</a>, a <a href="http://www.phpspec.net/">port of RSpec</a> that is the first PHP BDD framework.
</p>
<blockquote>
<a href="http://www.phpspec.net/">PHPSpec</a> is the first ever PHP BDD framework. It is a port of <a href="http://rspec.info/">RSpec</a> to PHP created back in 2007 by Padraic Brady and Travis Swicegood. Development in this framework stopped for a while and was reignited last August (2010).
</blockquote>
<p>
He goes over how to get it installed via PEAR and how to write some sample tests following along the topic from his previous post (handing videos and reviews). He gets into a bit more detail by describing how MVC is handled with PHPSpec and how the Zend Framework command line tool can be used to create a controller that satisfies the test.
</p>]]></description>
      <pubDate>Wed, 03 Aug 2011 09:41:20 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Ibuildings techPortal: Behavior Driven Development in PHP With Behat]]></title>
      <guid>http://www.phpdeveloper.org/news/16640</guid>
      <link>http://www.phpdeveloper.org/news/16640</link>
      <description><![CDATA[<p>
On the Ibuildings techPortal today there's a new post from <i>Marcello Duarte</i> looking at a different sort of software development methodology - behavior driven development - and <a href="http://techportal.ibuildings.com/2011/07/27/behaviour-driven-development-in-php-with-behat/">using Behat in a sample project</a>.
</p>
<blockquote>
Because of the emphasis on test, developers tend to focus on class structure as opposed to how the system should behave. Ironically the focus on test moves developers away from TDD as it was intended. Quite often, because of the tendency to try to test everything, our tests end up tightly coupled with our implementation. If we change our code, we break our tests, even if the behaviour remains unchanged.
</blockquote>
<p>
He talks about the option to use the <a href="http://agiledox.sourceforge.net/">agiledox</a> method in PHPUnit tests and how it can help with test output readability. He takes it a step further with a look at Gherkin, the language for the <a href="http://cukes.info/">Cucumber</a> testing tool in Ruby. The next obvious step in the process comes with <a href="http://behat.org/">Behat</a>, a sort of PHP version of the Cucumber testing tool. He includes a sample project and shows how to update it with sample steps and create a few basic tests to check video rental information.
</p>]]></description>
      <pubDate>Wed, 27 Jul 2011 10:48:20 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Project: ArrBDD - a Behavior-Driven Development Library for PHP 5]]></title>
      <guid>http://www.phpdeveloper.org/news/16602</guid>
      <link>http://www.phpdeveloper.org/news/16602</link>
      <description><![CDATA[<p>
<i>Leng Sheng Hong</i> has submitted about a project posted recently he's developed to make behavior-driven development in PHP easier - <a href="http://code.google.com/p/arr-bdd/">ArBDD</a>.
</p>
<blockquote>
ArBDD is a simple yet powerful BDD library for PHP to get you started with BDD in PHP. Excellent for those who have no previous experience with BDD.
</blockquote>
<p>
The <a href="http://code.google.com/p/arr-bdd/">project's page</a> includes some basic code definitions of behaviors the code should follow, the creation of a simple mock object and the JSON-based results that come out when the tool is executed. They've also created an AIR-based viewing tool to see the results outside the browser. The code requires PHP 5.3+ because of its use of closures.
</p>
<p>
For another example of BDD testing in action, look at the <a href="http://behat.org/">Behat framework</a>, based on the Ruby Cucumber syntax.
</p>]]></description>
      <pubDate>Mon, 18 Jul 2011 11:14:29 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[DZone.com: PHPSpec: BDD for your classes]]></title>
      <guid>http://www.phpdeveloper.org/news/16422</guid>
      <link>http://www.phpdeveloper.org/news/16422</link>
      <description><![CDATA[<p>
In <a href="http://css.dzone.com/articles/phpspec-bdd-your-classes">a new post</a> to the "PHP on Windows" section of DZone.com, <i>Giorgio Sironi</i> looks at another testing tool to add to your arsenal - <a href="http://code.google.com/p/phpspec/">PHPSpec</a>, a behavior-driven development testing tool similar to Ruby's RSpec.
</p>
<blockquote>
Behavior-Driven Development can be seen as an evolution of Test-Driven Development, stricly in its outside-in version and with a refined language. In the case of the tool I'm reviewing today, BDD is implemented with code instead of with textual feature files (e.g. written in Gherkin) like in Behat. PHPSpec is similar to (or a port of) RSpec, the original BDD Ruby tool. It fills the need for an approach different from the classical xUnit at the class level.
</blockquote>
<p>
He points out the place he thinks PHPSpec has in the software testing world as it fits with things like Behat and PHPUnit. He also includes some sample code to show it at work - a sample test that checks against an object for things like "should be an object" or "should not return the same number for multiples of three" for the basic class FizzBuzz.
</p>]]></description>
      <pubDate>Fri, 03 Jun 2011 08:57:12 -0500</pubDate>
    </item>
  </channel>
</rss>
