Refactor versions_controller_test
This commit is contained in:
parent
93f1489048
commit
c576edecd4
1 changed files with 3 additions and 3 deletions
|
@ -1,7 +1,7 @@
|
||||||
require "test_helper"
|
require "test_helper"
|
||||||
|
|
||||||
module Api
|
module Api
|
||||||
class VersionsControllerTest < ActionController::TestCase
|
class VersionsControllerTest < ActionDispatch::IntegrationTest
|
||||||
##
|
##
|
||||||
# test all routes which lead to this controller
|
# test all routes which lead to this controller
|
||||||
def test_routes
|
def test_routes
|
||||||
|
@ -16,7 +16,7 @@ module Api
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_versions
|
def test_versions
|
||||||
get :show
|
get api_versions_path
|
||||||
assert_response :success
|
assert_response :success
|
||||||
assert_select "osm[generator='#{Settings.generator}']", :count => 1 do
|
assert_select "osm[generator='#{Settings.generator}']", :count => 1 do
|
||||||
assert_select "api", :count => 1 do
|
assert_select "api", :count => 1 do
|
||||||
|
@ -26,7 +26,7 @@ module Api
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_no_version_in_root_element
|
def test_no_version_in_root_element
|
||||||
get :show
|
get api_versions_path
|
||||||
assert_response :success
|
assert_response :success
|
||||||
assert_select "osm[version]", :count => 0
|
assert_select "osm[version]", :count => 0
|
||||||
end
|
end
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue