Friday, August 29. 2008Zend Framework testing: emulating HTTP calls
Following last month's article by Ian, here's some thoughts on how to test a Zend Framework application.
One of the unit testing best practices suggests to break dependencies, so you can test each component separately. The first problem that arises when you want to test controllers might be having a tighter control over the HTTP Request and Response objects. Fortunately, ZF already has something that really makes your life easier, i.e. the Zend_Test_PHPUnit_ControllerTestCase class, which has stubs for the Request and Response objects, and you can easily check headers, return codes, routes, redirects, and even the view itself. Continue reading "Zend Framework testing: emulating HTTP calls" Monday, August 11. 2008Dutch PHP TestFest - A Big Success
In May, I helped organize the Dutch PHP TestFest in my position as board member of the Dutch PHP User Group. This dutch event, which was sponsored by Ibuildings, was part of the global PHP TestFest initiative, which aims to get a higher test coverage for the PHP language and with that stabilize the language even more - something that will benefit all users of PHP. Back in May, we already deemed our event a big success with 10 attendees, a great presentation by Sebastian Bergmann and a huge number of tests written. But it turns out to be an even bigger success...
Continue reading "Dutch PHP TestFest - A Big Success" Monday, February 11. 2008Using the atkMockDb
If you develop an ATK application but do not have the luxury of a separate test-database, and can only test against actual databases, it is not safe to run testcases that actually add records to the database. Even though testcases can be built to clean-up testdata afterwards, this is not without risk. For instance, when a testcase breaks halfway through the code with a PHP parse error, any testdata that was already added will stay there. Besides the fact that this can break any future executions of your testcase, the testrecord stays in the live database and possibly break the live site.
This is where the atkMockDb kicks in Continue reading "Using the atkMockDb" Thursday, February 7. 2008Backward compatibility, bane of the developer
Recently 'A List Apart' posted an article about the new X-UA-Compatible switch that Microsoft will be implementing in Internet Explorer 8.
In short, you can target versions of the IE renderer with the switch; you can say: I want this page to be rendered like IE7 would render it and then IE8 (and IE9 and IE10 presumably) would render it similarly to IE7. Now this provoked a lot of reactions, and it got me thinking about one of the most painful subjects among developers (PHP and in general): backward compatibility. Continue reading "Backward compatibility, bane of the developer"
Posted by Boy Baukema
at
12:41
| Comment (1)
| Trackback (1)
Defined tags for this entry: api, architecture, compatibility, development, php, release management, unittest
Thursday, June 14. 2007ATK6 gereleased!![]() Sinds 1 juni ben ik bij Ibuildings aan de slag gegaan als Product Manager. Als afstudeerder heb ik kennis mogen maken met de wereld van PHP, Zend, Content Management Systemen, internationale samenwerking etc. Het was een leuke tijd en met de overgang naar "echte medewerker" kan ik nu datgene in de praktijk brengen wat ik tijdens mijn afstuderen geadviseerd heb! Ik ga me voornamelijk bezighouden met de producten van Ibuildings: applicatieframework ATK, cms WDE, projectmanagementsysteem Achievo en webapplicatie Mockatoo. In mijn tweede week werd er een nieuwe versie van ATK gereleased. Continue reading "ATK6 gereleased!" Tuesday, October 31. 2006De voordelen van automatische tests
Testen is een van de belangrijkste onderdelen in het proces van software ontwikkeling, maar is tevens hetgene dat het vaakst wordt vergeten of wordt overgeslagen vanwege tijdgebrek. Dit komt voornamelijk omdat het testen van software vaak wordt gezien als een handmatig klusje dat pas wordt uitgevoerd aan het einde van het proces, als het product volledig ontwikkeld is. Vaak is het dan zo dat er vanwege tijdgebrek geen tijd meer over is om alles goed te testen of het testen wordt maar half uitgevoerd.
Een oplossing voor dit probleem wordt beschreven in de XP (Extreme Programming) methode, namelijk het 'Test First' principe. Dit houdt in dat je alvorens te beginnen met programmeren nadenkt over hoe de software moet werken en hoe je dit kan testen. Vervolgens schrijf je dan eerst een zogenaamde unittest om een functie te testen (automatisch) en vervolgens ga je de functie implementeren. De theorie klinkt allemaal leuk en aardig, maar werkt dit in de praktijk ook zo goed? Continue reading "De voordelen van automatische tests"
(Page 1 of 1, totaling 6 entries)
|
Blog

