Skip to content
This repository has been archived by the owner on Mar 24, 2020. It is now read-only.

Commit

Permalink
Add edit button to Collection Level Record
Browse files Browse the repository at this point in the history
Add test for CLR edit button

Update test
  • Loading branch information
VivianChu committed Jan 30, 2020
1 parent e3fb09d commit e18f35e
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 0 deletions.
1 change: 1 addition & 0 deletions app/views/dams_collections/_show_editor_tools.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -18,5 +18,6 @@
</li>
<% end %>
<% } %>
<%= render :partial => 'shared/fields/edit_button' %>
<% end %>
</ul>
4 changes: 4 additions & 0 deletions app/views/shared/fields/_edit_button.html.erb
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<a class="btn btn-small btn-primary" target="edit-form" href="<%= rdf_edit_url (@document['id'])%>">
<i class="icon-edit icon-white"></i>Edit
</a>

5 changes: 5 additions & 0 deletions spec/features/dams_collections_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,11 @@
expect(page).to have_content("Push to OSF");
expect(page).to have_content("Delete from OSF");
end
scenario "should contain damsmanger url for RDF Edit" do
sign_in_developer
visit dams_collection_path @provCollection
expect(page).to have_xpath "//a[contains(@href,'/damsmanager/rdfImport.do?ark=#{@provCollection.pid}')]"
end
end

feature 'Collection that has DOI identifier' do
Expand Down

0 comments on commit e18f35e

Please sign in to comment.