##// END OF EJS Templates
remove trailing white-spaces from test/integration/api_test/http_basic_login_with_api_token_test.rb....
Toshi MARUYAMA -
r6554:bc15b437de89
parent child
Show More
@@ -1,27 +1,27
1 require File.expand_path('../../../test_helper', __FILE__)
1 require File.expand_path('../../../test_helper', __FILE__)
2
2
3 class ApiTest::HttpBasicLoginWithApiTokenTest < ActionController::IntegrationTest
3 class ApiTest::HttpBasicLoginWithApiTokenTest < ActionController::IntegrationTest
4 fixtures :all
4 fixtures :all
5
5
6 def setup
6 def setup
7 Setting.rest_api_enabled = '1'
7 Setting.rest_api_enabled = '1'
8 Setting.login_required = '1'
8 Setting.login_required = '1'
9 end
9 end
10
10
11 def teardown
11 def teardown
12 Setting.rest_api_enabled = '0'
12 Setting.rest_api_enabled = '0'
13 Setting.login_required = '0'
13 Setting.login_required = '0'
14 end
14 end
15
15
16 # Using the NewsController because it's a simple API.
16 # Using the NewsController because it's a simple API.
17 context "get /news" do
17 context "get /news" do
18
18
19 context "in :xml format" do
19 context "in :xml format" do
20 should_allow_http_basic_auth_with_key(:get, "/news.xml")
20 should_allow_http_basic_auth_with_key(:get, "/news.xml")
21 end
21 end
22
22
23 context "in :json format" do
23 context "in :json format" do
24 should_allow_http_basic_auth_with_key(:get, "/news.json")
24 should_allow_http_basic_auth_with_key(:get, "/news.json")
25 end
25 end
26 end
26 end
27 end
27 end
General Comments 0
You need to be logged in to leave comments. Login now