- assert_select "a[href^='/user/#{URI.encode(moderator_user.display_name)}/history']", 1
- assert_select "a[href='/user/#{URI.encode(moderator_user.display_name)}/traces']", 1
- assert_select "a[href='/user/#{URI.encode(moderator_user.display_name)}/diary']", 1
- assert_select "a[href='/user/#{URI.encode(moderator_user.display_name)}/diary/comments']", 1
- assert_select "a[href='/user/#{URI.encode(moderator_user.display_name)}/account']", 0
- assert_select "a[href='/user/#{URI.encode(moderator_user.display_name)}/blocks']", 0
- assert_select "a[href='/user/#{URI.encode(moderator_user.display_name)}/blocks_by']", 1
- assert_select "a[href='/blocks/new/#{URI.encode(moderator_user.display_name)}']", 0
+ assert_select "a[href^='/user/#{ERB::Util.u(moderator_user.display_name)}/history']", 1
+ assert_select "a[href='/user/#{ERB::Util.u(moderator_user.display_name)}/traces']", 1
+ assert_select "a[href='/user/#{ERB::Util.u(moderator_user.display_name)}/diary']", 1
+ assert_select "a[href='/user/#{ERB::Util.u(moderator_user.display_name)}/diary/comments']", 1
+ assert_select "a[href='/user/#{ERB::Util.u(moderator_user.display_name)}/account']", 0
+ assert_select "a[href='/user/#{ERB::Util.u(moderator_user.display_name)}/blocks']", 0
+ assert_select "a[href='/user/#{ERB::Util.u(moderator_user.display_name)}/blocks_by']", 1
+ assert_select "a[href='/blocks/new/#{ERB::Util.u(moderator_user.display_name)}']", 0