projects
/
arvados.git
/ blobdiff
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch '8567-moar-docker' refs #8567
[arvados.git]
/
services
/
api
/
test
/
functional
/
arvados
/
v1
/
nodes_controller_test.rb
diff --git
a/services/api/test/functional/arvados/v1/nodes_controller_test.rb
b/services/api/test/functional/arvados/v1/nodes_controller_test.rb
index 428c663a77b92ab2fc679ef20bbcf6b8fcc0fd69..b4ddd78554c8e7c85f4ad6ee0a3514de048f074d 100644
(file)
--- a/
services/api/test/functional/arvados/v1/nodes_controller_test.rb
+++ b/
services/api/test/functional/arvados/v1/nodes_controller_test.rb
@@
-17,8
+17,8
@@
class Arvados::V1::NodesControllerTest < ActionController::TestCase
authorize_with :inactive
get :index
assert_response :success
authorize_with :inactive
get :index
assert_response :success
- node_items = JSON.parse(@response.body)['items']
- assert_equal 0,
node_items.size
+ assert_equal 0, json_response['items'].size
+ assert_equal 0,
json_response['items_available']
end
# active user sees non-secret attributes of up and recently-up nodes
end
# active user sees non-secret attributes of up and recently-up nodes
@@
-26,8
+26,9
@@
class Arvados::V1::NodesControllerTest < ActionController::TestCase
authorize_with :active
get :index
assert_response :success
authorize_with :active
get :index
assert_response :success
- node_items = JSON.parse(@response.body)['items']
- assert_not_equal 0, node_items.size
+ assert_operator 0, :<, json_response['items_available']
+ node_items = json_response['items']
+ assert_operator 0, :<, node_items.size
found_busy_node = false
node_items.each do |node|
assert_nil node['info'].andand['ping_secret']
found_busy_node = false
node_items.each do |node|
assert_nil node['info'].andand['ping_secret']
@@
-113,6
+114,7
@@
class Arvados::V1::NodesControllerTest < ActionController::TestCase
authorize_with user
get :index, {select: ['domain']}
assert_response :success
authorize_with user
get :index, {select: ['domain']}
assert_response :success
+ assert_operator 0, :<, json_response['items_available']
end
end
end
end