<% content_for :head, tag.meta(:name => :robots, :content => :noindex) %>
<% content_for :heading do %>
<% content_for :head, tag.meta(:name => :robots, :content => :noindex) %>
<% content_for :heading do %>
- <div <% if @user %> id="userinformation"<% end %> class="row">
<% if @user %>
<div class="col-auto">
<%= user_image @user %>
<% if @user %>
<div class="col-auto">
<%= user_image @user %>
<% content_for :heading do %>
<% content_for :heading do %>
- <div id="userinformation" class="row">
<div class="col-sm-auto">
<%= user_image @entry.user %>
</div>
<div class="col-sm-auto">
<%= user_image @entry.user %>
</div>
<% content_for :heading do %>
<% content_for :heading do %>
- <div id="userinformation" class="row">
<div class="col-sm-auto">
<%= user_image @user %>
</div>
<div class="col-sm-auto">
<%= user_image @user %>
</div>
get user_path(user)
assert_response :success
get user_path(user)
assert_response :success
- assert_select "div#userinformation" do
+ assert_select "div.content-heading" do
assert_select "a[href^='/user/#{ERB::Util.u(user.display_name)}/history']", 1
assert_select "a[href='/user/#{ERB::Util.u(user.display_name)}/traces']", 1
assert_select "a[href='/user/#{ERB::Util.u(user.display_name)}/diary']", 1
assert_select "a[href^='/user/#{ERB::Util.u(user.display_name)}/history']", 1
assert_select "a[href='/user/#{ERB::Util.u(user.display_name)}/traces']", 1
assert_select "a[href='/user/#{ERB::Util.u(user.display_name)}/diary']", 1
create(:user_block, :user => blocked_user)
get user_path(blocked_user)
assert_response :success
create(:user_block, :user => blocked_user)
get user_path(blocked_user)
assert_response :success
- assert_select "div#userinformation" do
+ assert_select "div.content-heading" do
assert_select "a[href^='/user/#{ERB::Util.u(blocked_user.display_name)}/history']", 1
assert_select "a[href='/user/#{ERB::Util.u(blocked_user.display_name)}/traces']", 1
assert_select "a[href='/user/#{ERB::Util.u(blocked_user.display_name)}/diary']", 1
assert_select "a[href^='/user/#{ERB::Util.u(blocked_user.display_name)}/history']", 1
assert_select "a[href='/user/#{ERB::Util.u(blocked_user.display_name)}/traces']", 1
assert_select "a[href='/user/#{ERB::Util.u(blocked_user.display_name)}/diary']", 1
create(:user_block, :creator => moderator_user)
get user_path(moderator_user)
assert_response :success
create(:user_block, :creator => moderator_user)
get user_path(moderator_user)
assert_response :success
- assert_select "div#userinformation" do
+ assert_select "div.content-heading" do
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)}/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
# Test the normal user
get user_path(user)
assert_response :success
# Test the normal user
get user_path(user)
assert_response :success
- assert_select "div#userinformation" do
+ assert_select "div.content-heading" do
assert_select "a[href^='/user/#{ERB::Util.u(user.display_name)}/history']", 1
assert_select "a[href='/traces/mine']", 1
assert_select "a[href='/user/#{ERB::Util.u(user.display_name)}/diary']", 1
assert_select "a[href^='/user/#{ERB::Util.u(user.display_name)}/history']", 1
assert_select "a[href='/traces/mine']", 1
assert_select "a[href='/user/#{ERB::Util.u(user.display_name)}/diary']", 1
# Test the normal user
get user_path(user)
assert_response :success
# Test the normal user
get user_path(user)
assert_response :success
- assert_select "div#userinformation" do
+ assert_select "div.content-heading" do
assert_select "a[href^='/user/#{ERB::Util.u(user.display_name)}/history']", 1
assert_select "a[href='/user/#{ERB::Util.u(user.display_name)}/traces']", 1
assert_select "a[href='/user/#{ERB::Util.u(user.display_name)}/diary']", 1
assert_select "a[href^='/user/#{ERB::Util.u(user.display_name)}/history']", 1
assert_select "a[href='/user/#{ERB::Util.u(user.display_name)}/traces']", 1
assert_select "a[href='/user/#{ERB::Util.u(user.display_name)}/diary']", 1
get user_path(agreed_user)
assert_response :success
get user_path(agreed_user)
assert_response :success
- assert_select "div#userinformation" do
+ assert_select "div.content-heading" do
assert_select "dt", :count => 0, :text => /Contributor terms/
end
get user_path(seen_user)
assert_response :success
# put @response.body
assert_select "dt", :count => 0, :text => /Contributor terms/
end
get user_path(seen_user)
assert_response :success
# put @response.body
- assert_select "div#userinformation" do
+ assert_select "div.content-heading" do
assert_select "dt", :count => 1, :text => /Contributor terms/
assert_select "dd", /Declined/
end
get user_path(not_seen_user)
assert_response :success
assert_select "dt", :count => 1, :text => /Contributor terms/
assert_select "dd", /Declined/
end
get user_path(not_seen_user)
assert_response :success
- assert_select "div#userinformation" do
+ assert_select "div.content-heading" do
assert_select "dt", :count => 1, :text => /Contributor terms/
assert_select "dd", /Undecided/
end
assert_select "dt", :count => 1, :text => /Contributor terms/
assert_select "dd", /Undecided/
end