diff options
Diffstat (limited to 'test')
| -rw-r--r-- | test/examples/x.pl | 5 | ||||
| -rw-r--r-- | test/examples/x.pl.styled | 5 | ||||
| -rw-r--r-- | test/examples/x.rb | 6 | ||||
| -rw-r--r-- | test/examples/x.rb.styled | 6 | ||||
| -rw-r--r-- | test/lexTests.py | 6 | 
5 files changed, 28 insertions, 0 deletions
| diff --git a/test/examples/x.pl b/test/examples/x.pl new file mode 100644 index 000000000..ba89f62a7 --- /dev/null +++ b/test/examples/x.pl @@ -0,0 +1,5 @@ +use strict;
 +while ( $r ) {
 +  printf ( "Example text \n" );
 +  sleep 1;
 +}
\ No newline at end of file diff --git a/test/examples/x.pl.styled b/test/examples/x.pl.styled new file mode 100644 index 000000000..74da4e911 --- /dev/null +++ b/test/examples/x.pl.styled @@ -0,0 +1,5 @@ +{5}use{0} {11}strict{10};{0} +{5}while{0} {10}({0} {12}$r{0} {10}){0} {10}{{0} +  {5}printf{0} {10}({0} {6}"Example text \n"{0} {10});{0} +  {5}sleep{0} {4}1{10};{0} +{10}}
\ No newline at end of file diff --git a/test/examples/x.rb b/test/examples/x.rb new file mode 100644 index 000000000..234a6406b --- /dev/null +++ b/test/examples/x.rb @@ -0,0 +1,6 @@ +class Demo
 +	def test # A test
 +		i = 1
 +		puts "Example"
 +	end
 +end
\ No newline at end of file diff --git a/test/examples/x.rb.styled b/test/examples/x.rb.styled new file mode 100644 index 000000000..904d07dd3 --- /dev/null +++ b/test/examples/x.rb.styled @@ -0,0 +1,6 @@ +{5}class{0} {8}Demo{0} +	{5}def{0} {9}test{0} {2}# A test{0} +		{11}i{0} {10}={0} {4}1{0} +		{11}puts{0} {6}"Example"{0} +	{5}end{0} +{5}end
\ No newline at end of file diff --git a/test/lexTests.py b/test/lexTests.py index 2a245649c..3c5ccc147 100644 --- a/test/lexTests.py +++ b/test/lexTests.py @@ -110,6 +110,12 @@ class TestLexers(unittest.TestCase):  	def testLua(self):  		self.LexExample("x.lua", b"lua", [b"function end"]) +	def testRuby(self): +		self.LexExample("x.rb", b"ruby", [b"class def end"]) + +	def testPerl(self): +		self.LexExample("x.pl", b"perl", [b"printf sleep use while"]) +  	def testD(self):  		self.LexExample("x.d", b"d",  			[b"keyword1", b"keyword2", b"", b"keyword4", b"keyword5", | 
