Revision feacea35
Added by Amos Benari about 11 years ago
- ID feacea35f07f362d9e2c694a83516bbc902321a0
test/functional/api/v2/domains_controller_test.rb | ||
---|---|---|
test "should get domains for location only" do
|
||
get :index, {:location_id => taxonomies(:location1).id }
|
||
assert_response :success
|
||
assert_equal assigns(:domains).count, 2
|
||
assert_equal 2, assigns(:domains).length
|
||
assert_equal assigns(:domains), [domains(:mydomain), domains(:yourdomain)]
|
||
end
|
||
|
||
test "should get domains for organization only" do
|
||
get :index, {:organization_id => taxonomies(:organization1).id }
|
||
assert_response :success
|
||
assert_equal assigns(:domains).count, 1
|
||
assert_equal 1, assigns(:domains).length
|
||
assert_equal assigns(:domains), [domains(:mydomain)]
|
||
end
|
||
|
||
test "should get domains for both location and organization" do
|
||
get :index, {:location_id => taxonomies(:location1).id, :organization_id => taxonomies(:organization1).id }
|
||
assert_response :success
|
||
assert_equal assigns(:domains).count, 1
|
||
assert_equal 1, assigns(:domains).length
|
||
assert_equal assigns(:domains), [domains(:mydomain)]
|
||
end
|
||
|
Also available in: Unified diff
upgrade foreman to rails 3.2.13
This commit updates from rails 3.0.x to 3.2.x, main changes include:
Users who uses foreman in production, make sure that you now compile
your assets, e.g
rake assets:precompile
Paired-with: Joseph Mitchell Magen <jmagen@redhat.com>
Paired-with: Ohad Levy <ohadlevy@gmail.com>
Signed-off-by: Ohad Levy <ohadlevy@gmail.com>