[macruby-changes] [4759] DietRB/trunk/spec/source_spec.rb
source_changes at macosforge.org
source_changes at macosforge.org
Fri Oct 8 04:10:41 PDT 2010
Revision: 4759
http://trac.macosforge.org/projects/ruby/changeset/4759
Author: eloy.de.enige at gmail.com
Date: 2010-10-08 04:10:40 -0700 (Fri, 08 Oct 2010)
Log Message:
-----------
Strengthen specs a bit more
From: Eloy Duran <eloy.de.enige at gmail.com>
Modified Paths:
--------------
DietRB/trunk/spec/source_spec.rb
Modified: DietRB/trunk/spec/source_spec.rb
===================================================================
--- DietRB/trunk/spec/source_spec.rb 2010-10-08 11:10:33 UTC (rev 4758)
+++ DietRB/trunk/spec/source_spec.rb 2010-10-08 11:10:40 UTC (rev 4759)
@@ -140,11 +140,14 @@
it "returns whether or not the source contains a syntax error, except a code block not ending" do
reflect("def;").syntax_error?.should == true
reflect("def;").syntax_error?.should == true
+ reflect("{ [ } ]").syntax_error?.should == true
reflect("def foo").syntax_error?.should == false
reflect("class A; }").syntax_error?.should == true
reflect("class A; {" ).syntax_error?.should == false
+ reflect("class A; def {").syntax_error?.should == true
reflect("class A def foo").syntax_error?.should == true
reflect("class A; def foo" ).syntax_error?.should == false
+ reflect("def foo; {; end; }").syntax_error?.should == true
end
it "returns the actual syntax error message if one occurs" do
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macruby-changes/attachments/20101008/8fec1ffa/attachment.html>
More information about the macruby-changes
mailing list