Mercurial > hg > soundsoftware-site
comparison .svn/pristine/97/97ae92d3d67c300e3e33399e47b9856864d7483b.svn-base @ 1296:038ba2d95de8 redmine-2.2
Fix redmine-2.2 branch update (add missing svn files)
author | Chris Cannam |
---|---|
date | Fri, 14 Jun 2013 09:05:06 +0100 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
1294:3e4c3460b6ca | 1296:038ba2d95de8 |
---|---|
1 # Redmine - project management software | |
2 # Copyright (C) 2006-2012 Jean-Philippe Lang | |
3 # | |
4 # This program is free software; you can redistribute it and/or | |
5 # modify it under the terms of the GNU General Public License | |
6 # as published by the Free Software Foundation; either version 2 | |
7 # of the License, or (at your option) any later version. | |
8 # | |
9 # This program is distributed in the hope that it will be useful, | |
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
12 # GNU General Public License for more details. | |
13 # | |
14 # You should have received a copy of the GNU General Public License | |
15 # along with this program; if not, write to the Free Software | |
16 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | |
17 | |
18 require File.expand_path('../../../test_helper', __FILE__) | |
19 | |
20 class ApiTest::QueriesTest < ActionController::IntegrationTest | |
21 fixtures :projects, :trackers, :issue_statuses, :issues, | |
22 :enumerations, :users, :issue_categories, | |
23 :projects_trackers, | |
24 :roles, | |
25 :member_roles, | |
26 :members, | |
27 :enabled_modules, | |
28 :workflows, | |
29 :queries | |
30 | |
31 def setup | |
32 Setting.rest_api_enabled = '1' | |
33 end | |
34 | |
35 context "/queries" do | |
36 context "GET" do | |
37 | |
38 should "return queries" do | |
39 get '/queries.xml' | |
40 | |
41 assert_response :success | |
42 assert_equal 'application/xml', @response.content_type | |
43 assert_tag :tag => 'queries', | |
44 :attributes => {:type => 'array'}, | |
45 :child => { | |
46 :tag => 'query', | |
47 :child => { | |
48 :tag => 'id', | |
49 :content => '4', | |
50 :sibling => { | |
51 :tag => 'name', | |
52 :content => 'Public query for all projects' | |
53 } | |
54 } | |
55 } | |
56 end | |
57 end | |
58 end | |
59 end |