<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>cakebaker &#187; pear</title>
	<atom:link href="http://cakebaker.42dh.com/tags/pear/feed/" rel="self" type="application/rss+xml" />
	<link>http://cakebaker.42dh.com</link>
	<description>baking cakes with CakePHP</description>
	<lastBuildDate>Tue, 20 Dec 2011 15:29:40 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>How to use Selenium with SimpleTest</title>
		<link>http://cakebaker.42dh.com/2006/11/16/how-to-use-selenium-with-simpletest/</link>
		<comments>http://cakebaker.42dh.com/2006/11/16/how-to-use-selenium-with-simpletest/#comments</comments>
		<pubDate>Thu, 16 Nov 2006 09:39:52 +0000</pubDate>
		<dc:creator>cakebaker</dc:creator>
				<category><![CDATA[cakephp]]></category>
		<category><![CDATA[pear]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[selenium]]></category>
		<category><![CDATA[simpletest]]></category>
		<category><![CDATA[testing]]></category>

		<guid isPermaLink="false">http://cakebaker.42dh.com/2006/11/16/how-to-use-selenium-with-simpletest/</guid>
		<description><![CDATA[Up to now there was no PHP support for Selenium Remote Control, i.e. you couldn&#8217;t integrate your Selenium tests with a testing framework like SimpleTest. On PEAR there is now a package called Testing_Selenium which makes it easy to use PHP and Selenium Remote Control together. To use them you need PHP5 and a JRE [...]]]></description>
			<content:encoded><![CDATA[<p>Up to now there was no PHP support for <a href="http://www.openqa.org/selenium-rc/">Selenium Remote Control</a>, i.e. you couldn&#8217;t integrate your Selenium tests with a testing framework like <a href="http://www.lastcraft.com/simple_test.php">SimpleTest</a>. On PEAR there is now a package called <a href="http://pear.php.net/package/Testing_Selenium">Testing_Selenium</a> which makes it easy to use PHP and Selenium Remote Control together. To use them you need PHP5 and a JRE (Java Runtime Environment) version 1.5 or higher. The installation itself is simple. Here the installation instructions for CakePHP:</p>
<ul>
<li><a href="http://pear.php.net/package/Testing_Selenium/download">Download</a> the package</li>
<li>Put Selenium.php to your &#8220;vendors&#8221; folder</li>
<li>Create a folder &#8220;Testing&#8221; in your &#8220;vendors&#8221; folder</li>
<li>Put the &#8220;Selenium&#8221; folder from the archive to the &#8220;Testing&#8221; folder</li>
<li>Put selenium-server.jar to a folder of your choice</li>
</ul>
<p>Ok, as the installation is done, let&#8217;s write a simple testcase. We want to verify that the title of the cake website is correct.</p>
<pre>
vendor('Selenium');

class SeleniumTest extends UnitTestCase
{
    function setUp()
    {
        $this-&gt;selenium = new Testing_Selenium("*firefox /usr/lib/firefox/firefox-bin", "http://cakephp.org");
        $result = $this-&gt;selenium-&gt;start();
    }

    function tearDown()
    {
        $this-&gt;selenium-&gt;stop();
    }

    function testCakePHPTitle()
    {
        $this-&gt;selenium-&gt;open("/");
        $this-&gt;assertEqual('CakePHP : the rapid development php framework', $this-&gt;selenium-&gt;getTitle());
    }
}
</pre>
<p>What does this do? In the setUp() function we start a Firefox browser (we could also use a different browser). With that browser we open in the test function the cake homepage and get the page title. And in tearDown() we close the browser.</p>
<p>Before we can run this test, we have to start the Selenium server with:</p>
<pre>
java -jar selenium-server.jar
</pre>
<p>Now, we should get a green bar when we run the test. </p>
<p>Happy testing :)</p>
<p>Update (2006-11-29): If you don&#8217;t want to put the exception class to the vendors folder, you can replace in Selenium.php </p>
<pre>
require_once 'Testing/Selenium/Exception.php';
</pre>
<p>with</p>
<pre>
class Testing_Selenium_Exception extends Exception {}
</pre>
]]></content:encoded>
			<wfw:commentRss>http://cakebaker.42dh.com/2006/11/16/how-to-use-selenium-with-simpletest/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>CakePHP as Pear Package II</title>
		<link>http://cakebaker.42dh.com/2006/01/22/cakephp-as-pear-package-ii/</link>
		<comments>http://cakebaker.42dh.com/2006/01/22/cakephp-as-pear-package-ii/#comments</comments>
		<pubDate>Sun, 22 Jan 2006 10:36:36 +0000</pubDate>
		<dc:creator>cakebaker</dc:creator>
				<category><![CDATA[cakephp]]></category>
		<category><![CDATA[pear]]></category>

		<guid isPermaLink="false">http://www.cakebaker.42dh.com/?p=71</guid>
		<description><![CDATA[It seems that Mustapha had success with creating a Pear package for CakePHP (here my earlier post about his attempts). He writes in his post: I created a pear package from all files in CakePHP project and added some scripts to make the creation and the deployment of projects and applications easier. The package is [...]]]></description>
			<content:encoded><![CDATA[<p>It seems that Mustapha had success with creating a <a href="http://pear.php.net">Pear</a> package for CakePHP (here my earlier <a href="http://cakebaker.wordpress.com/2006/01/16/cakephp-soon-as-pear-package/">post</a> about his attempts). He writes in his <a href="">post</a>:</p>
<blockquote><p>
I created a pear package from all files in CakePHP project and added some scripts to make the creation and the deployment of projects and applications easier.
</p></blockquote>
<p>The package is not available yet due to a problem:</p>
<blockquote><p>
Now, I have a problem to make it available to CakePHP users because I haven&#8217;t my own server to install a pear channel. The problem will be solved very soon. I hope so.
</p></blockquote>
<p>So you have to be patient until the CakePHP pear package will be made publicly available.</p>
]]></content:encoded>
			<wfw:commentRss>http://cakebaker.42dh.com/2006/01/22/cakephp-as-pear-package-ii/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>CakePHP soon as Pear Package?</title>
		<link>http://cakebaker.42dh.com/2006/01/16/cakephp-soon-as-pear-package/</link>
		<comments>http://cakebaker.42dh.com/2006/01/16/cakephp-soon-as-pear-package/#comments</comments>
		<pubDate>Mon, 16 Jan 2006 09:20:15 +0000</pubDate>
		<dc:creator>cakebaker</dc:creator>
				<category><![CDATA[cakephp]]></category>
		<category><![CDATA[ideas]]></category>
		<category><![CDATA[pear]]></category>

		<guid isPermaLink="false">http://www.cakebaker.42dh.com/?p=62</guid>
		<description><![CDATA[Mustapha tries to create a Pear package of CakePHP. Up to now he was not successful. He writes in his post: &#8230;I tried to see if it is easy to make cakephp into a pear package. The first problem I see is the ROOT constant which is used in many places in the framework (32 [...]]]></description>
			<content:encoded><![CDATA[<p>Mustapha tries to create a <a href="http://pear.php.net/">Pear</a> package of CakePHP. Up to now he was not successful. He writes in his <a href="http://www.mustap.com/phpzone_post_116_pearing-the-cake">post</a>:</p>
<blockquote><p>
&#8230;I tried to see if it is easy to make cakephp into a pear package. The first problem I see is the ROOT constant which is used in many places in the framework (32 times in 7 files. I&#8217;m using the latest version: 0.10.5.1790 RC 1). It makes the separation between the application and cake not easy because it is used by both.
</p></blockquote>
<p>Personally, I do not know if it will be possible to create such a package since CakePHP was not designed for such a scenario. Anyway, good luck, Mustapha!</p>
]]></content:encoded>
			<wfw:commentRss>http://cakebaker.42dh.com/2006/01/16/cakephp-soon-as-pear-package/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>

