forked from ruboto/ruboto
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Removed use of the --with-psych switch since we now include the complete Ruby 1.9 stdlib by default * Changed how we omit psych tests on jruby-jars 1.5.6 to avoid stack overflow.
- Loading branch information
Showing
9 changed files
with
48 additions
and
68 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
module Ruboto | ||
VERSION = '0.5.3.rc.1' | ||
VERSION = '0.5.3.rc.2' | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,25 @@ | ||
# TODO(uwe): Remove check when we stop supporting jruby-jars 1.5.6 | ||
if JRUBY_VERSION != '1.5.6' | ||
require 'jruby' | ||
require 'rbconfig' | ||
org.jruby.ext.psych.PsychLibrary.new.load(JRuby.runtime, false) | ||
$LOADED_FEATURES << 'psych.so' | ||
$LOAD_PATH << File.join(Config::CONFIG['libdir'], 'ruby/1.9') | ||
require 'psych.rb' | ||
require 'jruby' | ||
require 'rbconfig' | ||
org.jruby.ext.psych.PsychLibrary.new.load(JRuby.runtime, false) | ||
$LOADED_FEATURES << 'psych.so' | ||
$LOAD_PATH << File.join(Config::CONFIG['libdir'], 'ruby/1.9') | ||
require 'psych.rb' | ||
|
||
Psych::Parser | ||
Psych::Handler | ||
Psych::Parser | ||
Psych::Handler | ||
|
||
require 'ruboto' | ||
require 'ruboto' | ||
|
||
ruboto_import_widgets :Button, :LinearLayout, :TextView | ||
ruboto_import_widgets :Button, :LinearLayout, :TextView | ||
|
||
$activity.handle_create do |bundle| | ||
setTitle File.basename(__FILE__).chomp('_activity.rb').split('_').map { |s| "#{s[0..0].upcase}#{s[1..-1]}" }.join(' ') | ||
$activity.handle_create do |bundle| | ||
setTitle File.basename(__FILE__).chomp('_activity.rb').split('_').map { |s| "#{s[0..0].upcase}#{s[1..-1]}" }.join(' ') | ||
|
||
setup_content do | ||
linear_layout :orientation => LinearLayout::VERTICAL do | ||
@decoded_view = text_view :id => 42, :text => Psych.load('--- foo') | ||
# @encoded_view = text_view :id => 43, :text => Psych.dump("foo") | ||
end | ||
setup_content do | ||
linear_layout :orientation => LinearLayout::VERTICAL do | ||
@decoded_view = text_view :id => 42, :text => Psych.load('--- foo') | ||
# @encoded_view = text_view :id => 43, :text => Psych.dump("foo") | ||
end | ||
|
||
end | ||
|
||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,16 @@ | ||
# TODO(uwe): Remove check when we stop supporting jruby-jars 1.5.6 | ||
if JRUBY_VERSION != '1.5.6' | ||
activity org.ruboto.test_app.PsychActivity | ||
activity org.ruboto.test_app.PsychActivity | ||
|
||
setup do |activity| | ||
start = Time.now | ||
loop do | ||
@text_view = activity.findViewById(42) | ||
break if @text_view || (Time.now - start > 60) | ||
sleep 1 | ||
end | ||
assert @text_view | ||
setup do |activity| | ||
start = Time.now | ||
loop do | ||
@text_view = activity.findViewById(42) | ||
break if @text_view || (Time.now - start > 60) | ||
sleep 1 | ||
end | ||
assert @text_view | ||
end | ||
|
||
test('psych_encode_decode') do |activity| | ||
assert_equal 'foo', activity.find_view_by_id(42).text.to_s | ||
#assert_equal "--- foo\n...\n", activity.find_view_by_id(43).text.to_s | ||
end | ||
test('psych_encode_decode') do |activity| | ||
assert_equal 'foo', activity.find_view_by_id(42).text.to_s | ||
#assert_equal "--- foo\n...\n", activity.find_view_by_id(43).text.to_s | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters