Permalink
Browse files

Add basic Ratel test.

  • Loading branch information...
1 parent 3b07397 commit bd62b68d27001d957e7db8f07d096ff207642349 @tene tene committed Jun 11, 2010
Showing with 20 additions and 0 deletions.
  1. +20 −0 t/ratel/01-basics.t
View
@@ -0,0 +1,20 @@
+use v6;
+use Test;
+
+use Ratel;
+plan 2;
+
+my $template = q|<html>
+<title>[%! title %]</title>
+<ul>
+[% for 1..10 { %]
+<li>item [%= $_ %]</li>
+[% } %]
+</ul>
+</html>|;
+
+my Ratel $r .= new(:source($template));
+my $text = $r.render(:title('OMG HAI GUYS!!'));
+
+ok( $text ~~ /'item 2'/, 'Basic rendering' );
+ok( $text ~~ /'OMG HAI'/, 'Attribute interpolation' );

0 comments on commit bd62b68

Please sign in to comment.