<?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>distributedlife &#187; cakephp</title>
	<atom:link href="http://distributedlife.com/blog/category/cakephp/feed" rel="self" type="application/rss+xml" />
	<link>http://distributedlife.com/blog</link>
	<description>passionate about everything</description>
	<lastBuildDate>Sun, 31 Jul 2011 03:32:56 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>It&#8217;s a long way to the cache&#8230;</title>
		<link>http://distributedlife.com/blog/2008/12/its-a-long-way-to-the-cache.html</link>
		<comments>http://distributedlife.com/blog/2008/12/its-a-long-way-to-the-cache.html#comments</comments>
		<pubDate>Mon, 15 Dec 2008 13:55:29 +0000</pubDate>
		<dc:creator>Ryan Boucher</dc:creator>
				<category><![CDATA[cakephp]]></category>
		<category><![CDATA[coding]]></category>
		<category><![CDATA[cache]]></category>
		<category><![CDATA[database table not found]]></category>
		<category><![CDATA[performance]]></category>

		<guid isPermaLink="false">http://distributedlife.com/blog/?p=182</guid>
		<description><![CDATA[I had fun last night. I didn’t manage to waste too much time on this problem but I wasted more than none which is enough. CakePHP has a feature where it maintains a cached list of database tables it is aware of.
So I created a new table and the requisite model, controller, view files and [...]]]></description>
			<content:encoded><![CDATA[<p>I had fun last night. I didn’t manage to waste too much time on this problem but I wasted more than none which is enough. CakePHP has a <em>feature</em> where it maintains a cached list of database tables it is aware of.</p>
<p class="MsoNormal">So I created a new table and the requisite model, controller, view files and was ready to test it when CakePHP claimed my database table didn’t exist. It did and I spent plenty of time checking database connection strings and removing all but the simplest of code. I eventually found <a href="http://www.jroller.com/agileanswers/entry/missing_database_table_in_cake">this blog post by Eric Simmerman.</a></p>
<p class="MsoNormal">Delete the cache database table list and it all works fine. A simple fix and part of the reason for this post is to get Eric’s post closer to number one on a Google search. It wasn’t when I searched.</p>
<p class="MsoNormal">The answer I want to know is at what point did a cache become the final word? Caches are about performance enhancement and nothing else. You cache data so that you don’t have to go as far to get the answer. Distance is time is performance in computers. If you miss the cache then you go to your level two cache or you go to the persistent storage and get the data. The bottom line is that you keep going till you get an answer.</p>
<p class="MsoNormal">At no point in a cache do you ever say: “Well I don’t have it so you can bloody well sod off. No, I&#8217;m not going to ask around. I can’t see it, my eyes are closed and my fingers are in my ears. LA LA LA LA. ”</p>
<div style="border: 1pt solid windowtext; padding: 1pt 4pt; background: #e5b8b7 none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial;">
<p class="MsoNormal" style="border: medium none; padding: 0cm; background: #e5b8b7 none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial;"><strong>Note:</strong> Don’t make me get my big red book of caching.</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://distributedlife.com/blog/2008/12/its-a-long-way-to-the-cache.html/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>CakePHP Unit Testing Gripe #703</title>
		<link>http://distributedlife.com/blog/2008/10/cakephp-unit-testing-gripe-703.html</link>
		<comments>http://distributedlife.com/blog/2008/10/cakephp-unit-testing-gripe-703.html#comments</comments>
		<pubDate>Sun, 19 Oct 2008 13:57:04 +0000</pubDate>
		<dc:creator>Ryan Boucher</dc:creator>
				<category><![CDATA[cakephp]]></category>
		<category><![CDATA[deployment]]></category>
		<category><![CDATA[testing]]></category>
		<category><![CDATA[configuration management]]></category>
		<category><![CDATA[database]]></category>

		<guid isPermaLink="false">http://distributedlife.com/blog/?p=162</guid>
		<description><![CDATA[Next up in my problems with testing with CakePHP, database management. CakePHP supports the ability for models to specify which database configuration to use. This allows you to define two separate database instances for development, test or whatever.
The problem I have is when I test my controller it uses the real versions of the model, [...]]]></description>
			<content:encoded><![CDATA[<p>Next up in my problems with testing with CakePHP, database management. CakePHP supports the ability for models to specify which database configuration to use. This allows you to define two separate database instances for development, test or whatever.</p>
<p>The problem I have is when I test my controller it uses the real versions of the model, not the unit test versions. It has no concept of a unit test model (created purely for configuration management). Therefore it never gets the message to use the test database and the test cases fail.</p>
<p>In the end I feel it is safer and a lot less painful if you use your default database for development (or have a continuous integration server run the unit tests) and then when you have a build you want to move out of development; change your database configuration file so it affects the site as whole. When you do deploy to the next environment up I suggest you write a script to build the database configuration accordingly. <a href="http://distributedlife.com/blog/2008/05/automated-deployment-why-it-is-a-good-idea.html">We all know how I feel about manual steps in deployments.</a></p>
]]></content:encoded>
			<wfw:commentRss>http://distributedlife.com/blog/2008/10/cakephp-unit-testing-gripe-703.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>CakePHP Model Testing Addendum</title>
		<link>http://distributedlife.com/blog/2008/10/cakephp-model-testing-addendum.html</link>
		<comments>http://distributedlife.com/blog/2008/10/cakephp-model-testing-addendum.html#comments</comments>
		<pubDate>Sun, 19 Oct 2008 13:55:43 +0000</pubDate>
		<dc:creator>Ryan Boucher</dc:creator>
				<category><![CDATA[cakephp]]></category>
		<category><![CDATA[testing]]></category>
		<category><![CDATA[model]]></category>

		<guid isPermaLink="false">http://distributedlife.com/blog/?p=161</guid>
		<description><![CDATA[Something that I didn’t think of the other day is that there is an even better solution to what I posted. Override the query method in the AppModel so that whenever your Models call query the useCache parameter is automatically included.
The query signature is different to what I typed above. It uses func_get_args to support [...]]]></description>
			<content:encoded><![CDATA[<p>Something that I didn’t think of <a href="http://distributedlife.com/blog/2008/10/cakephp-unit-testing-gotchas.html">the other day</a> is that there is an even better solution to what I posted. Override the query method in the AppModel so that whenever your Models call query the useCache parameter is automatically included.</p>
<pre class="chili"><code class="php""""""""""">
class AppModel extends Model
{
  var $useCache = &#039;true&#039; ;

  function query ($sql)
  {
    return parent::query ($sql, $this-&gt;useCache) ;
  }
}
</code></pre>
<p>The query signature is different to what I typed above. It uses <a href="http://au2.php.net/func_get_args">func_get_args</a> to support any number of parameters. I don’t use query that way and have taken the shortcut of expecting a fully formed SQL statement and nothing more.</p>
]]></content:encoded>
			<wfw:commentRss>http://distributedlife.com/blog/2008/10/cakephp-model-testing-addendum.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>CakePHP Unit Testing Gotchas</title>
		<link>http://distributedlife.com/blog/2008/10/cakephp-unit-testing-gotchas.html</link>
		<comments>http://distributedlife.com/blog/2008/10/cakephp-unit-testing-gotchas.html#comments</comments>
		<pubDate>Thu, 16 Oct 2008 13:55:41 +0000</pubDate>
		<dc:creator>Ryan Boucher</dc:creator>
				<category><![CDATA[cakephp]]></category>
		<category><![CDATA[coding]]></category>
		<category><![CDATA[testing]]></category>
		<category><![CDATA[tips]]></category>
		<category><![CDATA[unit testing]]></category>

		<guid isPermaLink="false">http://distributedlife.com/blog/?p=158</guid>
		<description><![CDATA[CakePHP has caused me some grief in the past week. Seemingly simple unit testing tasks were made much harder than they should have been. This post is for anyone else who encounters these problems.
The first relates to the testAction method used to test controllers. When putting a querystring in the url doesn&#8217;t cause it to [...]]]></description>
			<content:encoded><![CDATA[<p>CakePHP has caused me some grief in the past week. Seemingly simple unit testing tasks were made much harder than they should have been. This post is for anyone else who encounters these problems.<br />
The first relates to the testAction method used to test controllers. When putting a querystring in the url doesn&#8217;t cause it to be automatically parsed and split like it normally is when the controller is directly invoked.</p>
<p>For example:</p>
<pre class="chili"><code class="c++""""""""""""""">
$this-&gt;testAction(&#039;/testing/post?company=utCompany&#039;, array(&#039;return&#039; =&gt; &#039;vars&#039;)) ;
</code></pre>
<p>will result in:</p>
<pre class="chili"><code class="c++""""""""""""""">
[url] =&gt; /testing/post?company=utCompany
</code></pre>
<p>While invoking the url directly via the web browser results in:</p>
<pre class="chili"><code class="php""""""""""""""""""""">
[url] =&gt; Array
(
[url] =&gt; testing/post
[company] =&gt; utCompany
)
</code></pre>
<p>The solution I found is a bit of a hack. There is meant to be a fix in the pipeline but it’s not in my build and I am not ready to update to RC3 (and I’m not even sure if the fix is in RC3). Either way there is no guarantee this feature will work beyond RC2</p>
<p>If the second testAction parameter includes a named array called &#8216;url&#8217; then the values will be placed in the $this-&gt;params object in the controller. This gives us the same net result as when the controller is directly invoked. This is not documented in the CakePHP manual.</p>
<pre class="chili"><code class="php""""""""""""""""">
$data = array (&#039;company&#039; =&gt; &#039;utCompany&#039;) ;

$result = $this-&gt;testAction(&#039;/testing/post&#039;, array
(
&#039;return&#039; =&gt; &#039;vars&#039;,
&#039;method&#039; =&gt; &#039;get&#039;,
&#039;url&#039; =&gt; $data
)) ;
</code></pre>
<p>I originally asked this question on <a href="http://stackoverflow.com/questions/200925/how-to-pass-querystring-to-testaction-in-cakephp-12">StackOverflow</a> but had to answer it myself. Still I got four achievements out of that one question. Not a bad return on my investment.</p>
<p>The second problem relates to caching. It is summed up in this post by Wil Clouser called <a href="http://micropipes.com/blog/2008/01/07/cakephps-cache-that-wouldnt-quit/">The Cache that wouldn’t quit</a>. My problem was that I was taking a snapshot of my table before my query ran so I could validate the results. The query had only run just beforehand so CakePHP went to the cache and got my previously unchanged dataset. This one drove me spare. I always forget the cache when I test because my policy is that <strong>unless I am testing the cache, the cache is turned off.</strong></p>
<p>The solution is fairly simple. The query command (of which I use a lot rather than CakePHP’s “automagic”) accepts a second parameter called “false”. When supplied it turns caching off.</p>
<p>This still leaves you with a problem because you want to call methods in your model. Your model can’t default to no-cache otherwise your prod code wouldn’t have any caching. The easiest solution I came up with is the following.</p>
<p>All of your model code inherits from AppModel. Update AppModel with the following property.</p>
<pre class="chili"><code class="php""""""""""""""""">
class AppModel extends Model
{
var $useCache = &#039;true&#039; ;
}
</code></pre>
<p>Then in your test model override the attribute with a value of false.</p>
<pre class="chili"><code class="php""""""""""""""""">
class UserTest extends User
{
var $name = &#039;UserTest&#039;;
var $useTable = &#039;users&#039; ;
var $useDbConfig = &#039;test&#039;;
var $useCache = &#039;false&#039; ;
}
</code></pre>
<p>In between those two snippets is your User model. User inherits from AppModel but has no need to manage caching. When you write a method on your model you will need to add one more chunk of code.</p>
<pre class="chili"><code class="php""""""""""""""""">
$result = parent::query
(
&#039;SELECT
users.id
FROM
users
WHERE
users.name = \&#039;&#039; . $name . &#039;\&#039;
AND
users.suspended = 0&#039;,
$this-&gt;useCache
) ;
</code></pre>
<p>Note that $this-&gt;useCache is used as the second parameter. This then gives you the ability to ensure caching is turned off while your test your model.<br />
<!--[if gte mso 9]><xml> <w:WordDocument> <w:View>Normal</w:View> <w:Zoom>0</w:Zoom> <w:TrackMoves /> <w:TrackFormatting /> <w:PunctuationKerning /> <w:ValidateAgainstSchemas /> <w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid> <w:IgnoreMixedContent>false</w:IgnoreMixedContent> <w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText> <w:DoNotPromoteQF /> <w:LidThemeOther>EN-AU</w:LidThemeOther> <w:LidThemeAsian>X-NONE</w:LidThemeAsian> <w:LidThemeComplexScript>X-NONE</w:LidThemeComplexScript> <w:Compatibility> <w:BreakWrappedTables /> <w:SnapToGridInCell /> <w:WrapTextWithPunct /> <w:UseAsianBreakRules /> <w:DontGrowAutofit /> <w:SplitPgBreakAndParaMark /> <w:DontVertAlignCellWithSp /> <w:DontBreakConstrainedForcedTables /> <w:DontVertAlignInTxbx /> <w:Word11KerningPairs /> <w:CachedColBalance /> </w:Compatibility> <w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel> <m:mathPr> <m:mathFont m:val="Cambria Math" /> <m:brkBin m:val="before" /> <m:brkBinSub m:val="&#45;-" /> <m:smallFrac m:val="off" /> <m:dispDef /> <m:lMargin m:val="0" /> <m:rMargin m:val="0" /> <m:defJc m:val="centerGroup" /> <m:wrapIndent m:val="1440" /> <m:intLim m:val="subSup" /> <m:naryLim m:val="undOvr" /> </m:mathPr></w:WordDocument> </xml><![endif]--><!--[if gte mso 9]><xml> <w:LatentStyles DefLockedState="false" DefUnhideWhenUsed="true"   DefSemiHidden="true" DefQFormat="false" DefPriority="99"   LatentStyleCount="267"> <w:LsdException Locked="false" Priority="0" SemiHidden="false"    UnhideWhenUsed="false" QFormat="true" Name="Normal" /> <w:LsdException Locked="false" Priority="9" SemiHidden="false"    UnhideWhenUsed="false" QFormat="true" Name="heading 1" /> <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 2" /> <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 3" /> <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 4" /> <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 5" /> <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 6" /> <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 7" /> <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 8" /> <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 9" /> <w:LsdException Locked="false" Priority="39" Name="toc 1" /> <w:LsdException Locked="false" Priority="39" Name="toc 2" /> <w:LsdException Locked="false" Priority="39" Name="toc 3" /> <w:LsdException Locked="false" Priority="39" Name="toc 4" /> <w:LsdException Locked="false" Priority="39" Name="toc 5" /> <w:LsdException Locked="false" Priority="39" Name="toc 6" /> <w:LsdException Locked="false" Priority="39" Name="toc 7" /> <w:LsdException Locked="false" Priority="39" Name="toc 8" /> <w:LsdException Locked="false" Priority="39" Name="toc 9" /> <w:LsdException Locked="false" Priority="35" QFormat="true" Name="caption" /> <w:LsdException Locked="false" Priority="10" SemiHidden="false"    UnhideWhenUsed="false" QFormat="true" Name="Title" /> <w:LsdException Locked="false" Priority="1" Name="Default Paragraph Font" /> <w:LsdException Locked="false" Priority="11" SemiHidden="false"    UnhideWhenUsed="false" QFormat="true" Name="Subtitle" /> <w:LsdException Locked="false" Priority="22" SemiHidden="false"    UnhideWhenUsed="false" QFormat="true" Name="Strong" /> <w:LsdException Locked="false" Priority="20" SemiHidden="false"    UnhideWhenUsed="false" QFormat="true" Name="Emphasis" /> <w:LsdException Locked="false" Priority="59" SemiHidden="false"    UnhideWhenUsed="false" Name="Table Grid" /> <w:LsdException Locked="false" UnhideWhenUsed="false" Name="Placeholder Text" /> <w:LsdException Locked="false" Priority="1" SemiHidden="false"    UnhideWhenUsed="false" QFormat="true" Name="No Spacing" /> <w:LsdException Locked="false" Priority="60" SemiHidden="false"    UnhideWhenUsed="false" Name="Light Shading" /> <w:LsdException Locked="false" Priority="61" SemiHidden="false"    UnhideWhenUsed="false" Name="Light List" /> <w:LsdException Locked="false" Priority="62" SemiHidden="false"    UnhideWhenUsed="false" Name="Light Grid" /> <w:LsdException Locked="false" Priority="63" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Shading 1" /> <w:LsdException Locked="false" Priority="64" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Shading 2" /> <w:LsdException Locked="false" Priority="65" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium List 1" /> <w:LsdException Locked="false" Priority="66" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium List 2" /> <w:LsdException Locked="false" Priority="67" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 1" /> <w:LsdException Locked="false" Priority="68" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 2" /> <w:LsdException Locked="false" Priority="69" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 3" /> <w:LsdException Locked="false" Priority="70" SemiHidden="false"    UnhideWhenUsed="false" Name="Dark List" /> <w:LsdException Locked="false" Priority="71" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful Shading" /> <w:LsdException Locked="false" Priority="72" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful List" /> <w:LsdException Locked="false" Priority="73" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful Grid" /> <w:LsdException Locked="false" Priority="60" SemiHidden="false"    UnhideWhenUsed="false" Name="Light Shading Accent 1" /> <w:LsdException Locked="false" Priority="61" SemiHidden="false"    UnhideWhenUsed="false" Name="Light List Accent 1" /> <w:LsdException Locked="false" Priority="62" SemiHidden="false"    UnhideWhenUsed="false" Name="Light Grid Accent 1" /> <w:LsdException Locked="false" Priority="63" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Shading 1 Accent 1" /> <w:LsdException Locked="false" Priority="64" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Shading 2 Accent 1" /> <w:LsdException Locked="false" Priority="65" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium List 1 Accent 1" /> <w:LsdException Locked="false" UnhideWhenUsed="false" Name="Revision" /> <w:LsdException Locked="false" Priority="34" SemiHidden="false"    UnhideWhenUsed="false" QFormat="true" Name="List Paragraph" /> <w:LsdException Locked="false" Priority="29" SemiHidden="false"    UnhideWhenUsed="false" QFormat="true" Name="Quote" /> <w:LsdException Locked="false" Priority="30" SemiHidden="false"    UnhideWhenUsed="false" QFormat="true" Name="Intense Quote" /> <w:LsdException Locked="false" Priority="66" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium List 2 Accent 1" /> <w:LsdException Locked="false" Priority="67" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 1 Accent 1" /> <w:LsdException Locked="false" Priority="68" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 2 Accent 1" /> <w:LsdException Locked="false" Priority="69" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 3 Accent 1" /> <w:LsdException Locked="false" Priority="70" SemiHidden="false"    UnhideWhenUsed="false" Name="Dark List Accent 1" /> <w:LsdException Locked="false" Priority="71" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful Shading Accent 1" /> <w:LsdException Locked="false" Priority="72" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful List Accent 1" /> <w:LsdException Locked="false" Priority="73" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful Grid Accent 1" /> <w:LsdException Locked="false" Priority="60" SemiHidden="false"    UnhideWhenUsed="false" Name="Light Shading Accent 2" /> <w:LsdException Locked="false" Priority="61" SemiHidden="false"    UnhideWhenUsed="false" Name="Light List Accent 2" /> <w:LsdException Locked="false" Priority="62" SemiHidden="false"    UnhideWhenUsed="false" Name="Light Grid Accent 2" /> <w:LsdException Locked="false" Priority="63" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Shading 1 Accent 2" /> <w:LsdException Locked="false" Priority="64" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Shading 2 Accent 2" /> <w:LsdException Locked="false" Priority="65" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium List 1 Accent 2" /> <w:LsdException Locked="false" Priority="66" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium List 2 Accent 2" /> <w:LsdException Locked="false" Priority="67" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 1 Accent 2" /> <w:LsdException Locked="false" Priority="68" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 2 Accent 2" /> <w:LsdException Locked="false" Priority="69" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 3 Accent 2" /> <w:LsdException Locked="false" Priority="70" SemiHidden="false"    UnhideWhenUsed="false" Name="Dark List Accent 2" /> <w:LsdException Locked="false" Priority="71" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful Shading Accent 2" /> <w:LsdException Locked="false" Priority="72" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful List Accent 2" /> <w:LsdException Locked="false" Priority="73" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful Grid Accent 2" /> <w:LsdException Locked="false" Priority="60" SemiHidden="false"    UnhideWhenUsed="false" Name="Light Shading Accent 3" /> <w:LsdException Locked="false" Priority="61" SemiHidden="false"    UnhideWhenUsed="false" Name="Light List Accent 3" /> <w:LsdException Locked="false" Priority="62" SemiHidden="false"    UnhideWhenUsed="false" Name="Light Grid Accent 3" /> <w:LsdException Locked="false" Priority="63" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Shading 1 Accent 3" /> <w:LsdException Locked="false" Priority="64" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Shading 2 Accent 3" /> <w:LsdException Locked="false" Priority="65" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium List 1 Accent 3" /> <w:LsdException Locked="false" Priority="66" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium List 2 Accent 3" /> <w:LsdException Locked="false" Priority="67" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 1 Accent 3" /> <w:LsdException Locked="false" Priority="68" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 2 Accent 3" /> <w:LsdException Locked="false" Priority="69" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 3 Accent 3" /> <w:LsdException Locked="false" Priority="70" SemiHidden="false"    UnhideWhenUsed="false" Name="Dark List Accent 3" /> <w:LsdException Locked="false" Priority="71" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful Shading Accent 3" /> <w:LsdException Locked="false" Priority="72" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful List Accent 3" /> <w:LsdException Locked="false" Priority="73" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful Grid Accent 3" /> <w:LsdException Locked="false" Priority="60" SemiHidden="false"    UnhideWhenUsed="false" Name="Light Shading Accent 4" /> <w:LsdException Locked="false" Priority="61" SemiHidden="false"    UnhideWhenUsed="false" Name="Light List Accent 4" /> <w:LsdException Locked="false" Priority="62" SemiHidden="false"    UnhideWhenUsed="false" Name="Light Grid Accent 4" /> <w:LsdException Locked="false" Priority="63" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Shading 1 Accent 4" /> <w:LsdException Locked="false" Priority="64" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Shading 2 Accent 4" /> <w:LsdException Locked="false" Priority="65" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium List 1 Accent 4" /> <w:LsdException Locked="false" Priority="66" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium List 2 Accent 4" /> <w:LsdException Locked="false" Priority="67" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 1 Accent 4" /> <w:LsdException Locked="false" Priority="68" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 2 Accent 4" /> <w:LsdException Locked="false" Priority="69" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 3 Accent 4" /> <w:LsdException Locked="false" Priority="70" SemiHidden="false"    UnhideWhenUsed="false" Name="Dark List Accent 4" /> <w:LsdException Locked="false" Priority="71" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful Shading Accent 4" /> <w:LsdException Locked="false" Priority="72" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful List Accent 4" /> <w:LsdException Locked="false" Priority="73" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful Grid Accent 4" /> <w:LsdException Locked="false" Priority="60" SemiHidden="false"    UnhideWhenUsed="false" Name="Light Shading Accent 5" /> <w:LsdException Locked="false" Priority="61" SemiHidden="false"    UnhideWhenUsed="false" Name="Light List Accent 5" /> <w:LsdException Locked="false" Priority="62" SemiHidden="false"    UnhideWhenUsed="false" Name="Light Grid Accent 5" /> <w:LsdException Locked="false" Priority="63" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Shading 1 Accent 5" /> <w:LsdException Locked="false" Priority="64" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Shading 2 Accent 5" /> <w:LsdException Locked="false" Priority="65" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium List 1 Accent 5" /> <w:LsdException Locked="false" Priority="66" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium List 2 Accent 5" /> <w:LsdException Locked="false" Priority="67" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 1 Accent 5" /> <w:LsdException Locked="false" Priority="68" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 2 Accent 5" /> <w:LsdException Locked="false" Priority="69" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 3 Accent 5" /> <w:LsdException Locked="false" Priority="70" SemiHidden="false"    UnhideWhenUsed="false" Name="Dark List Accent 5" /> <w:LsdException Locked="false" Priority="71" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful Shading Accent 5" /> <w:LsdException Locked="false" Priority="72" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful List Accent 5" /> <w:LsdException Locked="false" Priority="73" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful Grid Accent 5" /> <w:LsdException Locked="false" Priority="60" SemiHidden="false"    UnhideWhenUsed="false" Name="Light Shading Accent 6" /> <w:LsdException Locked="false" Priority="61" SemiHidden="false"    UnhideWhenUsed="false" Name="Light List Accent 6" /> <w:LsdException Locked="false" Priority="62" SemiHidden="false"    UnhideWhenUsed="false" Name="Light Grid Accent 6" /> <w:LsdException Locked="false" Priority="63" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Shading 1 Accent 6" /> <w:LsdException Locked="false" Priority="64" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Shading 2 Accent 6" /> <w:LsdException Locked="false" Priority="65" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium List 1 Accent 6" /> <w:LsdException Locked="false" Priority="66" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium List 2 Accent 6" /> <w:LsdException Locked="false" Priority="67" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 1 Accent 6" /> <w:LsdException Locked="false" Priority="68" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 2 Accent 6" /> <w:LsdException Locked="false" Priority="69" SemiHidden="false"    UnhideWhenUsed="false" Name="Medium Grid 3 Accent 6" /> <w:LsdException Locked="false" Priority="70" SemiHidden="false"    UnhideWhenUsed="false" Name="Dark List Accent 6" /> <w:LsdException Locked="false" Priority="71" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful Shading Accent 6" /> <w:LsdException Locked="false" Priority="72" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful List Accent 6" /> <w:LsdException Locked="false" Priority="73" SemiHidden="false"    UnhideWhenUsed="false" Name="Colorful Grid Accent 6" /> <w:LsdException Locked="false" Priority="19" SemiHidden="false"    UnhideWhenUsed="false" QFormat="true" Name="Subtle Emphasis" /> <w:LsdException Locked="false" Priority="21" SemiHidden="false"    UnhideWhenUsed="false" QFormat="true" Name="Intense Emphasis" /> <w:LsdException Locked="false" Priority="31" SemiHidden="false"    UnhideWhenUsed="false" QFormat="true" Name="Subtle Reference" /> <w:LsdException Locked="false" Priority="32" SemiHidden="false"    UnhideWhenUsed="false" QFormat="true" Name="Intense Reference" /> <w:LsdException Locked="false" Priority="33" SemiHidden="false"    UnhideWhenUsed="false" QFormat="true" Name="Book Title" /> <w:LsdException Locked="false" Priority="37" Name="Bibliography" /> <w:LsdException Locked="false" Priority="39" QFormat="true" Name="TOC Heading" /> </w:LatentStyles> </xml><![endif]--> <!--[if gte mso 10]></p>
<style>
 /* Style Definitions */
 table.MsoNormalTable
	{mso-style-name:"Table Normal";
	mso-tstyle-rowband-size:0;
	mso-tstyle-colband-size:0;
	mso-style-noshow:yes;
	mso-style-priority:99;
	mso-style-qformat:yes;
	mso-style-parent:"";
	mso-padding-alt:0cm 5.4pt 0cm 5.4pt;
	mso-para-margin-top:0cm;
	mso-para-margin-right:0cm;
	mso-para-margin-bottom:10.0pt;
	mso-para-margin-left:0cm;
	line-height:115%;
	mso-pagination:widow-orphan;
	font-size:11.0pt;
	font-family:"Calibri","sans-serif";
	mso-ascii-font-family:Calibri;
	mso-ascii-theme-font:minor-latin;
	mso-fareast-font-family:"Times New Roman";
	mso-fareast-theme-font:minor-fareast;
	mso-hansi-font-family:Calibri;
	mso-hansi-theme-font:minor-latin;}
</style>
<p><![endif]--></p>
<div style="border: 1pt solid windowtext; padding: 1pt 4pt; background: #e5b8b7 none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial;">
<p class="MsoNormal" style="border: medium none; padding: 0cm; background: #e5b8b7 none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial;"><strong>Note:</strong> Apologies for the crap code highlighting. It isn’t working well. It is better than what it was before, which was self-hiding code&#8230;</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://distributedlife.com/blog/2008/10/cakephp-unit-testing-gotchas.html/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

