<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -16,6 +16,7 @@ requires 'Exception::Class::DBI' =&gt; '1.00';
 requires 'parent';
 requires 'Config::General'; # This should reflect the config file format you've chosen
 requires 'Test::MockObject';
+requires 'Test::XPath';
                  # See Catalyst::Plugin::ConfigLoader for supported formats
 catalyst;
 </diff>
      <filename>Makefile.PL</filename>
    </modified>
    <modified>
      <diff>@@ -28,7 +28,7 @@ ok my $output = $view-&gt;render($c, 'books/list', {
     title =&gt; 'Book List',
     books =&gt; $sth,
 }), 'Render the &quot;books/list&quot; template';
-#diag $output;
+diag $output;
 
 # Test output using Test::XPath.
 my $tx = Test::XPath-&gt;new( xml =&gt; $output, is_html =&gt; 1);
@@ -37,7 +37,7 @@ test_basics($tx, 'Book List');
 # Call this function for every request to make sure that they all
 # have the same basic structure.
 sub test_basics {
-    my ($tx, $title) = @_;
+    my ($tx, $title, $msg, $err) = @_;
 
     # Some basic sanity-checking.
     $tx-&gt;is( 'count(/html)',      1, 'Should have 1 html element' );
@@ -55,4 +55,35 @@ sub test_basics {
         '/static/css/main.css',
         'Should load the CSS',
     );
+
+    $tx-&gt;ok('/html/body/div[@id=&quot;header&quot;]', sub {
+        $_-&gt;ok('./img[@src=&quot;/static/images/btn_88x31_powered.png&quot;]');
+        $_-&gt;is('./h1', $title);
+    }, 'Should have header');
+
+    $tx-&gt;ok('/html/body/div[@id=&quot;bodyblock&quot;]', sub {
+        $_-&gt;ok('./div[@id=&quot;menu&quot;]', sub {
+            $_-&gt;is('./h3', 'Navigation', 'header should be &quot;Navigation&quot;');
+            $_-&gt;ok('./ul', =&gt; sub {
+                $_-&gt;ok('./li[1]', sub {
+                    $_-&gt;is(
+                        './a[@href=&quot;/books/list&quot;]',
+                        'Home',
+                        'Should have Home'
+                    );
+                }, 'Should have home item');
+                $_-&gt;ok('./li[2]', sub {
+                    $_-&gt;is(
+                        './a[@href=&quot;/&quot;][@title=&quot;Catalyst Welcome Page&quot;]',
+                        'Welcome',
+                        'Should have welcome page'
+                    );
+                }, 'Should have home item');
+            }, 'Should have menu list');
+        }, 'Should have menu');
+        $_-&gt;ok('./div[@id=&quot;content&quot;]', sub {
+            $_-&gt;is('./span[message]', $msg) if $msg;
+            $_-&gt;is('./span[error]',   $err) if $msg;
+        }, 'Should have content');
+    }, 'Should have bodyblock');
 }</diff>
      <filename>t/view_HTML.t</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>97415e6ef10ec6d214f100d1db5c29324a7a8a51</id>
    </parent>
  </parents>
  <author>
    <name>David E. Wheeler</name>
    <email>david@justatheory.com</email>
  </author>
  <url>http://github.com/theory/catalyst-tutorial/commit/b171bfb0cb624b3a5ef840d116e121a355f5fe7d</url>
  <id>b171bfb0cb624b3a5ef840d116e121a355f5fe7d</id>
  <committed-date>2009-11-09T12:59:30-08:00</committed-date>
  <authored-date>2009-11-09T12:59:30-08:00</authored-date>
  <message>Test all of the wrapper functionlaity.</message>
  <tree>5babc90807e35ebf14fd51bf21524d15abf0555c</tree>
  <committer>
    <name>David E. Wheeler</name>
    <email>david@justatheory.com</email>
  </committer>
</commit>
