Project

General

Profile

Patch #25775 » 25775-test.patch

Patch for test (issue controller and UI) - Akiko Takano, 2017-05-08 01:17

View differences:

test/functional/issues_controller_test.rb Tue Apr 25 17:44:08 2017 +0000 → test/functional/issues_controller_test.rb Mon May 08 08:13:17 2017 +0900
assert_response :success
assert_select 'a[href=?][onclick=?]', "/issues/1", "", :text => 'Cancel'
end
def test_show_should_display_with_assignees_gravatars
@request.session[:user_id] = 1
issue = Issue.find(1)
with_settings :gravatar_enabled => '1' do
get :show, :id => issue.id
assert_equal issue.assigned_to_id, nil
assert_select 'div.gravatar-with-child' do
assert_select 'img', 1
end
issue.update :assigned_to_id => User.find(2).id
get :show, :id => issue.id
assert_equal issue.assigned_to_id, 2
end
assert_select 'div.gravatar-with-child' do
assert_select 'img', 2
assert_select 'img.gravatar', 1
assert_select 'img.gravatar-child', 1
end
end
end
(3-3/5)