summaryrefslogtreecommitdiffstats
path: root/test/integration/api_test
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2016-05-16 06:25:11 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2016-05-16 06:25:11 +0000
commit0e59482e90a788f2da7775a3fb5c51dbea7b135f (patch)
tree08b2741b4a1bab46629e4e37eccfeaddee3c13b0 /test/integration/api_test
parent1acb0c9f69b3dbe4a2bca98fc154197490c952c0 (diff)
downloadredmine-0e59482e90a788f2da7775a3fb5c51dbea7b135f.tar.gz
redmine-0e59482e90a788f2da7775a3fb5c51dbea7b135f.zip
Include private_notes property in xml/json Journals output (#20985).
Patch by Takenori TAKAKI. git-svn-id: http://svn.redmine.org/redmine/trunk@15414 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/integration/api_test')
-rw-r--r--test/integration/api_test/issues_test.rb9
1 files changed, 8 insertions, 1 deletions
diff --git a/test/integration/api_test/issues_test.rb b/test/integration/api_test/issues_test.rb
index 8b23dccc8..b1e189181 100644
--- a/test/integration/api_test/issues_test.rb
+++ b/test/integration/api_test/issues_test.rb
@@ -169,10 +169,13 @@ class Redmine::ApiTest::IssuesTest < Redmine::ApiTest::Base
end
test "GET /issues/:id.xml with journals" do
- get '/issues/1.xml?include=journals'
+ Journal.find(2).update_attribute(:private_notes, true)
+
+ get '/issues/1.xml?include=journals', {}, credentials('jsmith')
assert_select 'issue journals[type=array]' do
assert_select 'journal[id="1"]' do
+ assert_select 'private_notes', :text => 'false'
assert_select 'details[type=array]' do
assert_select 'detail[name=status_id]' do
assert_select 'old_value', :text => '1'
@@ -180,6 +183,10 @@ class Redmine::ApiTest::IssuesTest < Redmine::ApiTest::Base
end
end
end
+ assert_select 'journal[id="2"]' do
+ assert_select 'private_notes', :text => 'true'
+ assert_select 'details[type=array]'
+ end
end
end