cvs: presentations /slides/advanced adv_what.xml cache.php d_api.xml d_bad1.xml d_good.xml d_intro.xml d_knowledge.xml d_knowledge1.xml d_source.xml
future.php t_basic.xml t_intro.xml t_stress.xml t_stress1.xml t_stress2.xml t_unit.xml t_unit_phpunit.xml t_unit_phpunit1.xml t_unit_phpunit2.xml
t_unit_phpunit3.xml t_unit_phpunit4.xml url_parser.php url_parser1.php
| From: | Sterling Hughes | Date: | Thu, 19 Jun 2003 07:14:14 +0000 |
| Subject: | cvs: presentations /slides/advanced adv_what.xml cache.php d_api.xml d_bad1.xml d_good.xml d_intro.xml d_knowledge.xml d_knowledge1.xml d_source.xml future.php t_basic.xml t_intro.xml t_stress.xml t_stress1.xml t_stress2.xml t_unit.xml t_unit_phpunit.xml t_unit_phpunit1.xml t_unit_phpunit2.xml t_unit_phpunit3.xml t_unit_phpunit4.xml url_parser.php url_parser1.php |
||
| Groups: | php.pres | ||
| Request: | Send a blank email to pres+get-746@lists.php.net to get a copy of this message | ||
sterling Thu Jun 19 03:14:14 2003 EDT
Added files:
/presentations/slides/advanced cache.php d_api.xml d_bad1.xml
d_good.xml d_knowledge.xml
d_knowledge1.xml d_source.xml
future.php t_stress.xml
t_stress1.xml t_stress2.xml
Modified files:
/presentations/slides/advanced adv_what.xml d_intro.xml t_basic.xml
t_intro.xml t_unit.xml
t_unit_phpunit.xml
t_unit_phpunit1.xml
t_unit_phpunit2.xml
t_unit_phpunit3.xml
t_unit_phpunit4.xml url_parser.php
url_parser1.php
Log:
more slides
Index: presentations/slides/advanced/adv_what.xml diff -u presentations/slides/advanced/adv_what.xml:1.2 presentations/slides/advanced/adv_what.xml:1.3 --- presentations/slides/advanced/adv_what.xml:1.2 Tue May 13 13:15:30 2003 +++ presentations/slides/advanced/adv_what.xml Thu Jun 19 03:14:13 2003 @@ -1,8 +1,8 @@ <slide title="What is Advanced PHP?"> <break lines="3"/> -<blurb align="center" fontsize="4.0em">~Developing Large Applications.~</blurb> +<blurb align="center" fontsize="5.0em">~Developing Large Applications.~</blurb> -<list marginleft="4.0em" fontsize="3.5em"> +<list marginleft="4.0em" fontsize="4.5em"> <bullet effect="slide">Testing & Debugging</bullet> <bullet effect="slide">Documentation</bullet> <bullet effect="slide">Error Handling</bullet> Index: presentations/slides/advanced/d_intro.xml diff -u presentations/slides/advanced/d_intro.xml:1.1 presentations/slides/advanced/d_intro.xml:1.2 --- presentations/slides/advanced/d_intro.xml:1.1 Wed Jun 18 14:59:30 2003 +++ presentations/slides/advanced/d_intro.xml Thu Jun 19 03:14:13 2003 @@ -1,12 +1,10 @@ -<slide title="Documentation"> +<slide title="Faces of Documentation"> <image filename="doi.jpg" align="right" marginright="1.0em"/> - -<break lines="6"/> - -<list> -<bullet>Documentation is over proselytized</bullet> -<bullet>Documentation is very good</bullet> -<bullet marginleft="4.0em" effect="slide" type="none">... but it needs to justify its own existance</bullet> +<break lines="5"/> +<list fontsize="4.5em"> +<bullet>Source Code Documentation</bullet> +<bullet>Knowledgebase</bullet> +<bullet>Architecture Information</bullet> +<bullet>API</bullet> </list> - </slide> Index: presentations/slides/advanced/t_basic.xml diff -u presentations/slides/advanced/t_basic.xml:1.2 presentations/slides/advanced/t_basic.xml:1.3 --- presentations/slides/advanced/t_basic.xml:1.2 Tue May 13 12:50:30 2003 +++ presentations/slides/advanced/t_basic.xml Thu Jun 19 03:14:13 2003 @@ -1,15 +1,15 @@ <slide title="Basic Testing"> <image filename="testing.jpg" align="right"/> <break lines="4"/> -<list title="Methods"> +<list title="Methods" fontsize="4.5em"> <bullet>If it compiles, it works</bullet> <bullet>Click through the application</bullet> </list> -<list title="Flaws"> -<bullet fontsize="2.2em">Innumerable Race Conditions</bullet> -<bullet fontsize="1.9em" type="none" marginleft="2.0em">~... High Concurrency~</bullet> -<bullet fontsize="1.9em" type="none" marginleft="2.0em">~... Data Overflows~</bullet> -<bullet fontsize="1.9em" type="none" marginleft="2.0em">~... Request Combinations~</bullet> -<bullet fontsize="1.9em" type="none" marginleft="2.0em">~... Edge Cases~</bullet> +<list title="Flaws" fontsize="4.5em"> +<bullet>Innumerable Race Conditions</bullet> +<bullet type="none" marginleft="2.0em">~... High Concurrency~</bullet> +<bullet type="none" marginleft="2.0em">~... Data Overflows~</bullet> +<bullet type="none" marginleft="2.0em">~... Request Combinations~</bullet> +<bullet type="none" marginleft="2.0em">~... Edge Cases~</bullet> </list> </slide> Index: presentations/slides/advanced/t_intro.xml diff -u presentations/slides/advanced/t_intro.xml:1.4 presentations/slides/advanced/t_intro.xml:1.5 --- presentations/slides/advanced/t_intro.xml:1.4 Wed Jun 18 14:59:30 2003 +++ presentations/slides/advanced/t_intro.xml Thu Jun 19 03:14:13 2003 @@ -1,7 +1,7 @@ <slide title="What is testing?"> <image filename="testing.jpg" align="right"/> <break lines="6"/> -<list marginleft="3.0em" fontsize="3.5em"> +<list marginleft="3.0em" fontsize="4.5em"> <bullet effect="slide">Assuring that your application works as it should.</bullet> <bullet effect="slide">~Ensuring that your application doesn't work as it shouldn't.~</bullet> </list> Index: presentations/slides/advanced/t_unit.xml diff -u presentations/slides/advanced/t_unit.xml:1.3 presentations/slides/advanced/t_unit.xml:1.4 --- presentations/slides/advanced/t_unit.xml:1.3 Wed May 14 00:04:19 2003 +++ presentations/slides/advanced/t_unit.xml Thu Jun 19 03:14:13 2003 @@ -1,7 +1,7 @@ <slide title="Unit Testing"> <image filename="testing.jpg" align="right"/> <break lines="6"/> -<list> +<list fontsize="4.5em"> <bullet>Testing Small Portions (~Units~) of Code</bullet> <bullet>Make Sure Nothing Breaks (~Regression Tests~)</bullet> <bullet>Write Your Tests</bullet> Index: presentations/slides/advanced/t_unit_phpunit.xml diff -u presentations/slides/advanced/t_unit_phpunit.xml:1.2 presentations/slides/advanced/t_unit_phpunit.xml:1.3 --- presentations/slides/advanced/t_unit_phpunit.xml:1.2 Tue May 13 13:15:30 2003 +++ presentations/slides/advanced/t_unit_phpunit.xml Thu Jun 19 03:14:13 2003 @@ -1,7 +1,7 @@ <slide title="PHPUnit"> <image filename="testing.jpg" align="right"/> <break lines="4"/> -<blurb>PHPUnit is a Unit Testing Suite written for PHP, modeled after %JUnit%.</blurb> +<blurb fontsize="4.5em">PHPUnit is a Unit Testing Suite written for PHP, modeled after %JUnit%.</blurb> <blurb> </blurb> <example title="Installing PHPUnit" type="shell"><![CDATA[% pear install PHPUnit]]></example> Index: presentations/slides/advanced/t_unit_phpunit1.xml diff -u presentations/slides/advanced/t_unit_phpunit1.xml:1.5 presentations/slides/advanced/t_unit_phpunit1.xml:1.6 --- presentations/slides/advanced/t_unit_phpunit1.xml:1.5 Wed May 14 00:04:19 2003 +++ presentations/slides/advanced/t_unit_phpunit1.xml Thu Jun 19 03:14:13 2003 @@ -1,7 +1,7 @@ <slide title="Using PHPUnit"> <image filename="testing.jpg" align="right"/> <break/> -<blurb fontsize="3.0em">Remember, Tests First!</blurb> +<blurb fontsize="4.5em">Remember, Tests First!</blurb> <break/> <example title="url_parser.phpt" filename="url_parser.phpt" result="1" fontsize="1.5em"/> </slide> Index: presentations/slides/advanced/t_unit_phpunit2.xml diff -u presentations/slides/advanced/t_unit_phpunit2.xml:1.4 presentations/slides/advanced/t_unit_phpunit2.xml:1.5 --- presentations/slides/advanced/t_unit_phpunit2.xml:1.4 Wed May 14 00:04:19 2003 +++ presentations/slides/advanced/t_unit_phpunit2.xml Thu Jun 19 03:14:13 2003 @@ -1,7 +1,7 @@ <slide title="url_parser"> <image filename="testing.jpg" align="right"/> -<break/> -<blurb>Can you spot the error(~s~) in this code?</blurb> +<break lines="2"/> +<blurb fontsize="4.5em">Can you spot the error(~s~) in this code?</blurb> <break/> <example filename="url_parser.php" fontsize="1.7em"/> </slide> Index: presentations/slides/advanced/t_unit_phpunit3.xml diff -u presentations/slides/advanced/t_unit_phpunit3.xml:1.2 presentations/slides/advanced/t_unit_phpunit3.xml:1.3 --- presentations/slides/advanced/t_unit_phpunit3.xml:1.2 Thu May 15 16:32:44 2003 +++ presentations/slides/advanced/t_unit_phpunit3.xml Thu Jun 19 03:14:13 2003 @@ -1,7 +1,7 @@ <slide title="Offensive Regexes"> <image filename="testing.jpg" align="right"/> <break lines="5"/> -<example title="Bad"><![CDATA[@<a[^>]*href=\"([^"]+)\">[^<]*</a>@ix]]></example> +<example fontsize="3.0em" title="Bad"><![CDATA[@<a[^>]*href=\"([^"]+)\">[^<]*</a>@ix]]></example> <break/> -<example title="Good"><![CDATA[@<a.*?href=\"([^"]+)\">[^<]*</a>@ix]]></example> +<example fontsize="3.0em" title="Good"><![CDATA[@<a.*?href=\"([^"]+)\">[^<]*</a>@ix]]></example> </slide> Index: presentations/slides/advanced/t_unit_phpunit4.xml diff -u presentations/slides/advanced/t_unit_phpunit4.xml:1.1 presentations/slides/advanced/t_unit_phpunit4.xml:1.2 --- presentations/slides/advanced/t_unit_phpunit4.xml:1.1 Thu May 15 16:32:44 2003 +++ presentations/slides/advanced/t_unit_phpunit4.xml Thu Jun 19 03:14:13 2003 @@ -1,7 +1,7 @@ <slide title="Broken Tests"> <image filename="testing.jpg" align="right"/> <break/> -<blurb>Let's add our test!</blurb> +<blurb fontsize="4.5em">Let's add our test!</blurb> <break/> <example title="url_parser1.phpt" filename="url_parser1.phpt" fontsize="1.5em" result="1"/> </slide> Index: presentations/slides/advanced/url_parser.php diff -u presentations/slides/advanced/url_parser.php:1.2 presentations/slides/advanced/url_parser.php:1.3 --- presentations/slides/advanced/url_parser.php:1.2 Thu May 15 16:32:44 2003 +++ presentations/slides/advanced/url_parser.php Thu Jun 19 03:14:13 2003 @@ -3,8 +3,7 @@ public $url_list; function search_document ($document) { - preg_match_all('@<a[^>]* - href=\"([^"]+)\">[^<]*</a>@ix', + preg_match_all('@<a[^>]*href=\"([^"]+)\">[^<]*</a>@ix', $document, $matches); $this->url_list = $matches[1]; unset($matches); Index: presentations/slides/advanced/url_parser1.php diff -u presentations/slides/advanced/url_parser1.php:1.1 presentations/slides/advanced/url_parser1.php:1.2 --- presentations/slides/advanced/url_parser1.php:1.1 Thu May 15 16:32:44 2003 +++ presentations/slides/advanced/url_parser1.php Thu Jun 19 03:14:13 2003 @@ -3,8 +3,7 @@ public $url_list; function search_document ($document) { - preg_match_all('@<a.*?href=\" - ([^"]+)\">[^<]*</a>@ix', + preg_match_all('@<a.*?href=\"([^"]+)\">[^<]*</a>@ix', $document, $matches); $this->url_list = $matches[1]; unset($matches); Index: presentations/slides/advanced/cache.php +++ presentations/slides/advanced/cache.php <?php if(file_exists("/cache/first.cache")) { $stat = @stat("/cache/first.cache"); // cache for 10 seconds if ($stat[9] && (time() > $stat[9] + 10)) { unlink("/cache/first.cache"); } else { include("/cache/first.cache"); return; } } $cachefp = fopen("/cache/first.cache", "w"); ob_start(); ?> <html> <body> Today is <?= strftime("%A, %B %e %Y %H:%M:%S") ?> </body> </html> <?php if ($cachefp) { $file = ob_get_contents(); fwrite($cachefp, $file); ob_end_flush(); } ?> Index: presentations/slides/advanced/d_api.xml +++ presentations/slides/advanced/d_api.xml <slide title="API Documentation"> </slide> Index: presentations/slides/advanced/d_bad1.xml +++ presentations/slides/advanced/d_bad1.xml <slide title="Bad Documentation"> <image filename="doi.jpg" align="right" marginright="1.0em"/> <break lines="8"/> <list fontsize="4.5em"> <bullet>Code is documentation</bullet> <bullet>Document the abstract algorithms, not the programmatical constructs</bullet> <bullet>If you can't figure out what a piece of code does by looking at it, chances are the code is wrong</bullet> <bullet type="none" effect="slide" marginleft="4.0em">... Its the web stupid!</bullet> </list> </slide> Index: presentations/slides/advanced/d_good.xml +++ presentations/slides/advanced/d_good.xml <slide title="Good Documentation"> <image filename="doi.jpg" align="right" marginright="1.0em"/> <break lines="10"/> <example filename="future.php"/> </slide> Index: presentations/slides/advanced/d_knowledge.xml +++ presentations/slides/advanced/d_knowledge.xml <slide title="Knowledgebases"> <image filename="doi.jpg" align="right" marginright="1.0em"/> <break lines="13"/> <blurb fontsize="4.5em" marginleft="2.0em">~Any sufficiently advanced bug is indistinguishable from a feature.~</blurb> <blurb marginleft="4.0em" fontsize="4.5em">- Rich Kulawiec</blurb> </slide> Index: presentations/slides/advanced/d_knowledge1.xml +++ presentations/slides/advanced/d_knowledge1.xml <slide title="Knowledgebases Cont."> <image filename="doi.jpg" align="right" marginright="1.0em"/> <break lines="2"/> <list title="Types of Systems" fontsize="4.5em"> <bullet>Bug Reporting Tools (%Bugzilla%)</bullet> <bullet>Wikis (coWiki, phpWiki)</bullet> <bullet>CVS</bullet> <bullet>CVSTrac (http://www.cvstrac.org/)</bullet> </list> </slide> Index: presentations/slides/advanced/d_source.xml +++ presentations/slides/advanced/d_source.xml <slide title="Source Code Docs"> <image filename="doi.jpg" align="right" marginright="1.0em"/> <break lines="6"/> <list fontsize="4.5em"> <bullet>Documentation is over proselytized</bullet> <bullet>Documentation is very good</bullet> <bullet marginleft="4.0em" effect="slide" type="none">... but it needs to justify its own existance</bullet> </list> </slide> Index: presentations/slides/advanced/future.php +++ presentations/slides/advanced/future.php <?php function get_future_date($daycount, $t = -1) { if ($t == -1) { $t = time(); } // use strtotime() instead of just multiplying by // 86400 * $daycount, because strtotime() takes // daylight savings time into account. return strtotime("now + $daycount days"); } ?> Index: presentations/slides/advanced/t_stress.xml +++ presentations/slides/advanced/t_stress.xml <slide title="Stress Testing"> <image filename="testing.jpg" align="right"/> <break lines="8"/> <list fontsize="4.5em"> <bullet>Applications behave differently under extreme loads</bullet> <bullet>"Unforseeable" Race Conditions</bullet> <bullet>Multiple Processes and Multiple Threads</bullet> <bullet>Memory corruption</bullet> </list> </slide> Index: presentations/slides/advanced/t_stress1.xml +++ presentations/slides/advanced/t_stress1.xml <slide title="Race Condition"> <image filename="testing.jpg" align="right"/> <break/> <blurb fontsize="4.5em"> Can you spot the race condition? </blurb> <break lines="2"/> <example filename="cache.php"/> </slide> Index: presentations/slides/advanced/t_stress2.xml +++ presentations/slides/advanced/t_stress2.xml <slide title="Finding Race Conditions"> <image filename="testing.jpg" align="right"/> <break lines="2"/> <blurb fontsize="4.5em">Use %cherry%!</blurb> <break/> <example><![CDATA[% cherry -c 100 -n 10000 -v --similair http://localhost/ getting initial data from http://localhost/... done generating rabin 64 checksums... done stress testing... 100 200 300 [..] done %]]></example> </slide>
Index: presentations/slides/advanced/adv_what.xml diff -u presentations/slides/advanced/adv_what.xml:1.2 presentations/slides/advanced/adv_what.xml:1.3 --- presentations/slides/advanced/adv_what.xml:1.2 Tue May 13 13:15:30 2003 +++ presentations/slides/advanced/adv_what.xml Thu Jun 19 03:14:13 2003 @@ -1,8 +1,8 @@ <slide title="What is Advanced PHP?"> <break lines="3"/> -<blurb align="center" fontsize="4.0em">~Developing Large Applications.~</blurb> +<blurb align="center" fontsize="5.0em">~Developing Large Applications.~</blurb> -<list marginleft="4.0em" fontsize="3.5em"> +<list marginleft="4.0em" fontsize="4.5em"> <bullet effect="slide">Testing & Debugging</bullet> <bullet effect="slide">Documentation</bullet> <bullet effect="slide">Error Handling</bullet> Index: presentations/slides/advanced/d_intro.xml diff -u presentations/slides/advanced/d_intro.xml:1.1 presentations/slides/advanced/d_intro.xml:1.2 --- presentations/slides/advanced/d_intro.xml:1.1 Wed Jun 18 14:59:30 2003 +++ presentations/slides/advanced/d_intro.xml Thu Jun 19 03:14:13 2003 @@ -1,12 +1,10 @@ -<slide title="Documentation"> +<slide title="Faces of Documentation"> <image filename="doi.jpg" align="right" marginright="1.0em"/> - -<break lines="6"/> - -<list> -<bullet>Documentation is over proselytized</bullet> -<bullet>Documentation is very good</bullet> -<bullet marginleft="4.0em" effect="slide" type="none">... but it needs to justify its own existance</bullet> +<break lines="5"/> +<list fontsize="4.5em"> +<bullet>Source Code Documentation</bullet> +<bullet>Knowledgebase</bullet> +<bullet>Architecture Information</bullet> +<bullet>API</bullet> </list> - </slide> Index: presentations/slides/advanced/t_basic.xml diff -u presentations/slides/advanced/t_basic.xml:1.2 presentations/slides/advanced/t_basic.xml:1.3 --- presentations/slides/advanced/t_basic.xml:1.2 Tue May 13 12:50:30 2003 +++ presentations/slides/advanced/t_basic.xml Thu Jun 19 03:14:13 2003 @@ -1,15 +1,15 @@ <slide title="Basic Testing"> <image filename="testing.jpg" align="right"/> <break lines="4"/> -<list title="Methods"> +<list title="Methods" fontsize="4.5em"> <bullet>If it compiles, it works</bullet> <bullet>Click through the application</bullet> </list> -<list title="Flaws"> -<bullet fontsize="2.2em">Innumerable Race Conditions</bullet> -<bullet fontsize="1.9em" type="none" marginleft="2.0em">~... High Concurrency~</bullet> -<bullet fontsize="1.9em" type="none" marginleft="2.0em">~... Data Overflows~</bullet> -<bullet fontsize="1.9em" type="none" marginleft="2.0em">~... Request Combinations~</bullet> -<bullet fontsize="1.9em" type="none" marginleft="2.0em">~... Edge Cases~</bullet> +<list title="Flaws" fontsize="4.5em"> +<bullet>Innumerable Race Conditions</bullet> +<bullet type="none" marginleft="2.0em">~... High Concurrency~</bullet> +<bullet type="none" marginleft="2.0em">~... Data Overflows~</bullet> +<bullet type="none" marginleft="2.0em">~... Request Combinations~</bullet> +<bullet type="none" marginleft="2.0em">~... Edge Cases~</bullet> </list> </slide> Index: presentations/slides/advanced/t_intro.xml diff -u presentations/slides/advanced/t_intro.xml:1.4 presentations/slides/advanced/t_intro.xml:1.5 --- presentations/slides/advanced/t_intro.xml:1.4 Wed Jun 18 14:59:30 2003 +++ presentations/slides/advanced/t_intro.xml Thu Jun 19 03:14:13 2003 @@ -1,7 +1,7 @@ <slide title="What is testing?"> <image filename="testing.jpg" align="right"/> <break lines="6"/> -<list marginleft="3.0em" fontsize="3.5em"> +<list marginleft="3.0em" fontsize="4.5em"> <bullet effect="slide">Assuring that your application works as it should.</bullet> <bullet effect="slide">~Ensuring that your application doesn't work as it shouldn't.~</bullet> </list> Index: presentations/slides/advanced/t_unit.xml diff -u presentations/slides/advanced/t_unit.xml:1.3 presentations/slides/advanced/t_unit.xml:1.4 --- presentations/slides/advanced/t_unit.xml:1.3 Wed May 14 00:04:19 2003 +++ presentations/slides/advanced/t_unit.xml Thu Jun 19 03:14:13 2003 @@ -1,7 +1,7 @@ <slide title="Unit Testing"> <image filename="testing.jpg" align="right"/> <break lines="6"/> -<list> +<list fontsize="4.5em"> <bullet>Testing Small Portions (~Units~) of Code</bullet> <bullet>Make Sure Nothing Breaks (~Regression Tests~)</bullet> <bullet>Write Your Tests</bullet> Index: presentations/slides/advanced/t_unit_phpunit.xml diff -u presentations/slides/advanced/t_unit_phpunit.xml:1.2 presentations/slides/advanced/t_unit_phpunit.xml:1.3 --- presentations/slides/advanced/t_unit_phpunit.xml:1.2 Tue May 13 13:15:30 2003 +++ presentations/slides/advanced/t_unit_phpunit.xml Thu Jun 19 03:14:13 2003 @@ -1,7 +1,7 @@ <slide title="PHPUnit"> <image filename="testing.jpg" align="right"/> <break lines="4"/> -<blurb>PHPUnit is a Unit Testing Suite written for PHP, modeled after %JUnit%.</blurb> +<blurb fontsize="4.5em">PHPUnit is a Unit Testing Suite written for PHP, modeled after %JUnit%.</blurb> <blurb> </blurb> <example title="Installing PHPUnit" type="shell"><![CDATA[% pear install PHPUnit]]></example> Index: presentations/slides/advanced/t_unit_phpunit1.xml diff -u presentations/slides/advanced/t_unit_phpunit1.xml:1.5 presentations/slides/advanced/t_unit_phpunit1.xml:1.6 --- presentations/slides/advanced/t_unit_phpunit1.xml:1.5 Wed May 14 00:04:19 2003 +++ presentations/slides/advanced/t_unit_phpunit1.xml Thu Jun 19 03:14:13 2003 @@ -1,7 +1,7 @@ <slide title="Using PHPUnit"> <image filename="testing.jpg" align="right"/> <break/> -<blurb fontsize="3.0em">Remember, Tests First!</blurb> +<blurb fontsize="4.5em">Remember, Tests First!</blurb> <break/> <example title="url_parser.phpt" filename="url_parser.phpt" result="1" fontsize="1.5em"/> </slide> Index: presentations/slides/advanced/t_unit_phpunit2.xml diff -u presentations/slides/advanced/t_unit_phpunit2.xml:1.4 presentations/slides/advanced/t_unit_phpunit2.xml:1.5 --- presentations/slides/advanced/t_unit_phpunit2.xml:1.4 Wed May 14 00:04:19 2003 +++ presentations/slides/advanced/t_unit_phpunit2.xml Thu Jun 19 03:14:13 2003 @@ -1,7 +1,7 @@ <slide title="url_parser"> <image filename="testing.jpg" align="right"/> -<break/> -<blurb>Can you spot the error(~s~) in this code?</blurb> +<break lines="2"/> +<blurb fontsize="4.5em">Can you spot the error(~s~) in this code?</blurb> <break/> <example filename="url_parser.php" fontsize="1.7em"/> </slide> Index: presentations/slides/advanced/t_unit_phpunit3.xml diff -u presentations/slides/advanced/t_unit_phpunit3.xml:1.2 presentations/slides/advanced/t_unit_phpunit3.xml:1.3 --- presentations/slides/advanced/t_unit_phpunit3.xml:1.2 Thu May 15 16:32:44 2003 +++ presentations/slides/advanced/t_unit_phpunit3.xml Thu Jun 19 03:14:13 2003 @@ -1,7 +1,7 @@ <slide title="Offensive Regexes"> <image filename="testing.jpg" align="right"/> <break lines="5"/> -<example title="Bad"><![CDATA[@<a[^>]*href=\"([^"]+)\">[^<]*</a>@ix]]></example> +<example fontsize="3.0em" title="Bad"><![CDATA[@<a[^>]*href=\"([^"]+)\">[^<]*</a>@ix]]></example> <break/> -<example title="Good"><![CDATA[@<a.*?href=\"([^"]+)\">[^<]*</a>@ix]]></example> +<example fontsize="3.0em" title="Good"><![CDATA[@<a.*?href=\"([^"]+)\">[^<]*</a>@ix]]></example> </slide> Index: presentations/slides/advanced/t_unit_phpunit4.xml diff -u presentations/slides/advanced/t_unit_phpunit4.xml:1.1 presentations/slides/advanced/t_unit_phpunit4.xml:1.2 --- presentations/slides/advanced/t_unit_phpunit4.xml:1.1 Thu May 15 16:32:44 2003 +++ presentations/slides/advanced/t_unit_phpunit4.xml Thu Jun 19 03:14:13 2003 @@ -1,7 +1,7 @@ <slide title="Broken Tests"> <image filename="testing.jpg" align="right"/> <break/> -<blurb>Let's add our test!</blurb> +<blurb fontsize="4.5em">Let's add our test!</blurb> <break/> <example title="url_parser1.phpt" filename="url_parser1.phpt" fontsize="1.5em" result="1"/> </slide> Index: presentations/slides/advanced/url_parser.php diff -u presentations/slides/advanced/url_parser.php:1.2 presentations/slides/advanced/url_parser.php:1.3 --- presentations/slides/advanced/url_parser.php:1.2 Thu May 15 16:32:44 2003 +++ presentations/slides/advanced/url_parser.php Thu Jun 19 03:14:13 2003 @@ -3,8 +3,7 @@ public $url_list; function search_document ($document) { - preg_match_all('@<a[^>]* - href=\"([^"]+)\">[^<]*</a>@ix', + preg_match_all('@<a[^>]*href=\"([^"]+)\">[^<]*</a>@ix', $document, $matches); $this->url_list = $matches[1]; unset($matches); Index: presentations/slides/advanced/url_parser1.php diff -u presentations/slides/advanced/url_parser1.php:1.1 presentations/slides/advanced/url_parser1.php:1.2 --- presentations/slides/advanced/url_parser1.php:1.1 Thu May 15 16:32:44 2003 +++ presentations/slides/advanced/url_parser1.php Thu Jun 19 03:14:13 2003 @@ -3,8 +3,7 @@ public $url_list; function search_document ($document) { - preg_match_all('@<a.*?href=\" - ([^"]+)\">[^<]*</a>@ix', + preg_match_all('@<a.*?href=\"([^"]+)\">[^<]*</a>@ix', $document, $matches); $this->url_list = $matches[1]; unset($matches); Index: presentations/slides/advanced/cache.php +++ presentations/slides/advanced/cache.php <?php if(file_exists("/cache/first.cache")) { $stat = @stat("/cache/first.cache"); // cache for 10 seconds if ($stat[9] && (time() > $stat[9] + 10)) { unlink("/cache/first.cache"); } else { include("/cache/first.cache"); return; } } $cachefp = fopen("/cache/first.cache", "w"); ob_start(); ?> <html> <body> Today is <?= strftime("%A, %B %e %Y %H:%M:%S") ?> </body> </html> <?php if ($cachefp) { $file = ob_get_contents(); fwrite($cachefp, $file); ob_end_flush(); } ?> Index: presentations/slides/advanced/d_api.xml +++ presentations/slides/advanced/d_api.xml <slide title="API Documentation"> </slide> Index: presentations/slides/advanced/d_bad1.xml +++ presentations/slides/advanced/d_bad1.xml <slide title="Bad Documentation"> <image filename="doi.jpg" align="right" marginright="1.0em"/> <break lines="8"/> <list fontsize="4.5em"> <bullet>Code is documentation</bullet> <bullet>Document the abstract algorithms, not the programmatical constructs</bullet> <bullet>If you can't figure out what a piece of code does by looking at it, chances are the code is wrong</bullet> <bullet type="none" effect="slide" marginleft="4.0em">... Its the web stupid!</bullet> </list> </slide> Index: presentations/slides/advanced/d_good.xml +++ presentations/slides/advanced/d_good.xml <slide title="Good Documentation"> <image filename="doi.jpg" align="right" marginright="1.0em"/> <break lines="10"/> <example filename="future.php"/> </slide> Index: presentations/slides/advanced/d_knowledge.xml +++ presentations/slides/advanced/d_knowledge.xml <slide title="Knowledgebases"> <image filename="doi.jpg" align="right" marginright="1.0em"/> <break lines="13"/> <blurb fontsize="4.5em" marginleft="2.0em">~Any sufficiently advanced bug is indistinguishable from a feature.~</blurb> <blurb marginleft="4.0em" fontsize="4.5em">- Rich Kulawiec</blurb> </slide> Index: presentations/slides/advanced/d_knowledge1.xml +++ presentations/slides/advanced/d_knowledge1.xml <slide title="Knowledgebases Cont."> <image filename="doi.jpg" align="right" marginright="1.0em"/> <break lines="2"/> <list title="Types of Systems" fontsize="4.5em"> <bullet>Bug Reporting Tools (%Bugzilla%)</bullet> <bullet>Wikis (coWiki, phpWiki)</bullet> <bullet>CVS</bullet> <bullet>CVSTrac (http://www.cvstrac.org/)</bullet> </list> </slide> Index: presentations/slides/advanced/d_source.xml +++ presentations/slides/advanced/d_source.xml <slide title="Source Code Docs"> <image filename="doi.jpg" align="right" marginright="1.0em"/> <break lines="6"/> <list fontsize="4.5em"> <bullet>Documentation is over proselytized</bullet> <bullet>Documentation is very good</bullet> <bullet marginleft="4.0em" effect="slide" type="none">... but it needs to justify its own existance</bullet> </list> </slide> Index: presentations/slides/advanced/future.php +++ presentations/slides/advanced/future.php <?php function get_future_date($daycount, $t = -1) { if ($t == -1) { $t = time(); } // use strtotime() instead of just multiplying by // 86400 * $daycount, because strtotime() takes // daylight savings time into account. return strtotime("now + $daycount days"); } ?> Index: presentations/slides/advanced/t_stress.xml +++ presentations/slides/advanced/t_stress.xml <slide title="Stress Testing"> <image filename="testing.jpg" align="right"/> <break lines="8"/> <list fontsize="4.5em"> <bullet>Applications behave differently under extreme loads</bullet> <bullet>"Unforseeable" Race Conditions</bullet> <bullet>Multiple Processes and Multiple Threads</bullet> <bullet>Memory corruption</bullet> </list> </slide> Index: presentations/slides/advanced/t_stress1.xml +++ presentations/slides/advanced/t_stress1.xml <slide title="Race Condition"> <image filename="testing.jpg" align="right"/> <break/> <blurb fontsize="4.5em"> Can you spot the race condition? </blurb> <break lines="2"/> <example filename="cache.php"/> </slide> Index: presentations/slides/advanced/t_stress2.xml +++ presentations/slides/advanced/t_stress2.xml <slide title="Finding Race Conditions"> <image filename="testing.jpg" align="right"/> <break lines="2"/> <blurb fontsize="4.5em">Use %cherry%!</blurb> <break/> <example><![CDATA[% cherry -c 100 -n 10000 -v --similair http://localhost/ getting initial data from http://localhost/... done generating rabin 64 checksums... done stress testing... 100 200 300 [..] done %]]></example> </slide>