Skip to content

Instantly share code, notes, and snippets.

View jarib's full-sized avatar

Jari Bakken jarib

View GitHub Profile
@jarib
jarib / gist:70128
Created February 25, 2009 10:57
parser bug
diff --git a/spec/cucumber/parser/feature_parser_spec.rb b/spec/cucumber/parser/feature_parser_spec.rb
index 7147308..a48516b 100644
--- a/spec/cucumber/parser/feature_parser_spec.rb
+++ b/spec/cucumber/parser/feature_parser_spec.rb
@@ -94,7 +94,7 @@ Feature: hi
Given Pepper
@st3
- @st4
+ @st4 @ST5
diff --git a/plugins/feed.rb b/plugins/feed.rb
index da99d9a..bca3d3d 100755
--- a/plugins/feed.rb
+++ b/plugins/feed.rb
@@ -203,6 +203,7 @@ module FeedStuff
def run(out = STDOUT, filename = '/tmp/feeds.yaml', period = 30*60)
tr = Thread.new do
+ sleep(120)
begin
{:version=>"0.0.5.9"}
Mar 8, 2009 6:37:30 PM com.gargoylesoftware.htmlunit.IncorrectnessListenerImpl notify
WARNING: Obsolete content type encountered: 'text/javascript'.
Mar 8, 2009 6:37:31 PM com.gargoylesoftware.htmlunit.IncorrectnessListenerImpl notify
WARNING: Obsolete content type encountered: 'text/javascript'.
.Mar 8, 2009 6:37:35 PM com.gargoylesoftware.htmlunit.IncorrectnessListenerImpl notify
WARNING: Obsolete content type encountered: 'text/javascript'.
Mar 8, 2009 6:37:37 PM com.gargoylesoftware.htmlunit.IncorrectnessListenerImpl notify
WARNING: Obsolete content type encountered: 'text/javascript'.
Mar 8, 2009 6:37:37 PM com.gargoylesoftware.htmlunit.IncorrectnessListenerImpl notify
vm/test/runner
Running 686 testsWatching for 0
.Watching for 0
.Watching for 0
.Watching for 0
....Watching for 0
.Watching for 0
.Watching for 0
.Watching for 0
.Watching for 0
qjava.lang.NoSuchMethodError: org.jruby.runtime.builtin.IRubyObject.getInstanceVariable(Ljava/lang/String;)Lorg/jruby/runtime/builtin/IRubyObject;
at HpricotScanService.hpricot_scan(HpricotScanService.java:931)
at HpricotScanService.__hpricot_scan(HpricotScanService.java:1324)
at HpricotScanServiceCallback$__hpricot_scan_S1.call(Unknown Source)
at org.jruby.runtime.callback.InvocationCallback.execute(InvocationCallback.java:67)
at org.jruby.internal.runtime.methods.FullFunctionCallbackMethod.call(FullFunctionCallbackMethod.java:69)
at org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:243)
at org.jruby.runtime.callsite.CachingCallSite.callBlock(CachingCallSite.java:119)
at org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:126)
at org.jruby.ast.CallOneArgBlockNode.interpret(CallOneArgBlockNode.java:60)
java.lang.NoSuchMethodError: org.jruby.runtime.builtin.IRubyObject.getInstanceVariable(Ljava/lang/String;)Lorg/jruby/runtime/builtin/IRubyObject;
at HpricotScanService.hpricot_scan(HpricotScanService.java:931)
at HpricotScanService.__hpricot_scan(HpricotScanService.java:1324)
at HpricotScanServiceCallback$__hpricot_scan_S1.call(Unknown Source)
at org.jruby.runtime.callback.InvocationCallback.execute(InvocationCallback.java:67)
at org.jruby.internal.runtime.methods.FullFunctionCallbackMethod.call(FullFunctionCallbackMethod.java:69)
at org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:243)
at org.jruby.runtime.callsite.CachingCallSite.callBlock(CachingCallSite.java:119)
at org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:126)
at org.jruby.ast.CallOneArgBlockNode.interpret(CallOneArgBlockNode.java:60)
## ex. 1 - expose remove_listener
blk = lamda { true }
browser.add_listener(:confirm, &blk)
browser.button(...).click # to trigger confirm
browser.remove_listener(blk)
## ex. 2 - new API
browser.confirm(true/false) do
$ ruby socket_stuff.rb
tcp6 0 0 localhost.6000 *.* LISTEN
:mri
{:read=>"foo"}
tcp6 0 0 localhost.6000 *.* LISTEN
tcp6 0 0 localhost.49830 localhost.6000 TIME_WAIT
:jruby
-e:1:in `new': Connection refused - Connection refused (Errno::ECONNREFUSED)
from -e:1
$ jruby socket_stuff.rb
total 6712
-rw-r--r-- 1 root wheel 667B Aug 25 2008 README
-rw-r--r-- 1 root wheel 9.5K Aug 25 2008 ant-1.7.0.pom
-rw-r--r-- 1 root wheel 3.1K Aug 25 2008 ant-antlr-1.7.0.pom
-rw-r--r-- 1 root wheel 2.8K Aug 25 2008 ant-apache-bcel-1.7.0.pom
-rw-r--r-- 1 root wheel 3.0K Aug 25 2008 ant-apache-bsf-1.7.0.pom
-rw-r--r-- 1 root wheel 2.7K Aug 25 2008 ant-apache-log4j-1.7.0.pom
-rw-r--r-- 1 root wheel 2.8K Aug 25 2008 ant-apache-oro-1.7.0.pom
-rw-r--r-- 1 root wheel 2.7K Aug 25 2008 ant-apache-regexp-1.7.0.pom
-rw-r--r-- 1 root wheel 2.7K Aug 25 2008 ant-apache-resolver-1.7.0.pom
$ pwd
/tmp/demo
$ sqlite3 db/development.sqlite3 "select * from foos;"
1|New name|2009-04-02 14:29:15|2009-04-02 14:46:47
$ cd script
$ cp celerity_demo.rb celerity_demo2.rb
$ diff -u celerity_demo.rb celerity_demo2.rb
--- celerity_demo.rb 2009-04-02 23:15:54.000000000 +0200
+++ celerity_demo2.rb 2009-04-02 23:16:12.000000000 +0200
@@ -1,10 +1,10 @@