dsander-reve 0.0.123 → 0.0.124

Sign up to get free protection for your applications and to get access to all the features.
data/lib/reve/classes.rb CHANGED
@@ -1244,8 +1244,8 @@ module Reve #:nodoc:
1244
1244
  attr_reader :queue_position, :end_time, :start_time, :type_id, :start_sp, :end_sp, :to_level
1245
1245
  def initialize(elem) #:nodoc:
1246
1246
  @queue_position = elem['queuePosition'].to_i
1247
- @end_time = elem['endTime'].to_time
1248
- @start_time = elem['startTime'].to_time
1247
+ @end_time = elem['endTime'] == "" ? nil : elem['endTime'].to_time
1248
+ @start_time = elem['startTime'] == "" ? nil : elem['startTime'].to_time
1249
1249
  @type_id = elem['typeID'].to_i
1250
1250
  @start_sp = elem['startSP'].to_i
1251
1251
  @end_sp = elem['endSP'].to_i
@@ -87,28 +87,6 @@ module Reve #:nodoc:
87
87
  end
88
88
  end
89
89
  end
90
- module Array
91
- def to_hash(space = 0)
92
- hash = ""
93
- each do |c|
94
- vars = []
95
- c.instance_variables.each do |m|
96
- data = c.instance_variable_get(m)
97
- if data.kind_of? Array
98
- if data.length == 0
99
- vars << "#{m} => {}"
100
- else
101
- vars << "#{m} => {\n#{data.to_hash(space + 1)}}"
102
- end
103
- else
104
- vars << " #{m} => #{data}"
105
- end
106
- end
107
- hash << "#{' ' * space}{#{vars.join(',')}}\n"
108
- end
109
- hash
110
- end
111
- end
112
90
 
113
91
  end
114
92
  end
@@ -129,10 +107,6 @@ class NilClass #:nodoc:
129
107
  include Reve::Extensions::NilClass
130
108
  end
131
109
 
132
- class Array #:nodoc:
133
- include Reve::Extensions::Array
134
- end
135
-
136
110
  class Object
137
111
  def rsend(*args, &block)
138
112
  obj = self
data/test/test_reve.rb CHANGED
@@ -935,7 +935,15 @@ class TestReve < Test::Unit::TestCase
935
935
  assert_not_nil queue.first.to_level
936
936
  assert_not_nil queue.first.start_sp
937
937
  assert_not_nil queue.first.end_sp
938
- assert_equal 9, queue.length
938
+ assert_equal 9, queue.length
939
+ Reve::API.skill_queue_url = XML_BASE + 'skill_queue-paused.xml'
940
+ queue = nil
941
+ assert_nothing_raised do
942
+ queue = @api.skill_queue(:characerid => 1)
943
+ end
944
+ assert_kind_of(Reve::Classes::QueuedSkill, queue.first)
945
+ assert_nil queue.first.start_time
946
+ assert_nil queue.first.end_time
939
947
  end
940
948
 
941
949
  def test_corporate_medals
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 0
8
- - 123
9
- version: 0.0.123
8
+ - 124
9
+ version: 0.0.124
10
10
  platform: ruby
11
11
  authors:
12
12
  - Lisa Seelye