Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Added test for searching by code_name

  • Loading branch information...
commit 0f96b43e58d4dea787e330887daa4ad4ad84f2a5 1 parent 8bf3a51
@treeder treeder authored
Showing with 35 additions and 1 deletion.
  1. +6 −1 Gemfile.lock
  2. +29 −0 test/test_tasks_list.rb
View
7 Gemfile.lock
@@ -17,15 +17,19 @@ GEM
activesupport (2.3.18)
ansi (1.4.3)
builder (3.2.0)
+ concur (2.1.0)
+ concur
faraday (0.8.7)
multipart-post (~> 1.1)
+ go (1.1.0)
+ concur
hashie (2.0.3)
iron_cache (1.4.0)
iron_core (>= 0.5.1)
iron_core (0.6.0)
rest (>= 2.2.0)
mime-types (1.22)
- minitest (4.7.1)
+ minitest (4.7.2)
minitest-reporters (0.14.16)
ansi
builder
@@ -55,6 +59,7 @@ PLATFORMS
DEPENDENCIES
actionmailer
+ go
iron_cache (>= 1.4.0)
iron_worker_ng!
minitest
View
29 test/test_tasks_list.rb
@@ -0,0 +1,29 @@
+require_relative 'helpers'
+
+class TestTaskList < IWNGTest
+
+ def test_task_list
+
+ tasks = client.tasks.list()
+ code_names = {}
+ tasks.each do |t|
+ puts "#{t.code_name} - #{t.status}"
+ code_names[t.code_name] ||= 0
+ code_names[t.code_name] += 1
+ end
+ puts "num codes: #{code_names.size}"
+
+ assert code_names.size > 0
+
+ tasks = client.tasks.list(:code_name=>"hello")
+ code_names = {}
+ tasks.each do |t|
+ p t.code_name
+ code_names[t.code_name] ||= 0
+ code_names[t.code_name] += 1
+ end
+ puts "num codes: #{code_names.size}"
+
+ end
+
+end
Please sign in to comment.
Something went wrong with that request. Please try again.