From: Uri Guttman <uri@quad.(none)>
Date: Wed, 9 May 2012 07:15:26 +0000 (-0400)
Subject: added test for token_re option
X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=c1b17cb50b09c3d949a37dec5aae862bd9b258bb;p=urisagit%2FTemplate-Simple.git

added test for token_re option
---

diff --git a/t/options.t b/t/options.t
index 320fe15..9500206 100644
--- a/t/options.t
+++ b/t/options.t
@@ -175,6 +175,24 @@ foo
 [%END FOO%]
 EXPECTED
 	},
+	{
+		name	=> 'token_id',
+		opts	=> {
+			token_id => qw/[-\w]+?/,
+		},
+		data	=> {
+			'foo-bar'	=> 'FOO is 3',
+			'BAR-BAZ'	=> 'bar is baz',
+		},
+		template => <<TEMPLATE,
+[%foo-bar%]
+[%BAR-BAZ%]
+TEMPLATE
+		expected => <<EXPECTED,
+FOO is 3
+bar is baz
+EXPECTED
+	},
 ] ;
 
 template_tester( $tests ) ;