From 31d2c4c68876cb37936b13a6e65257cd7d61bda8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Esm=C3=A9=20Cowles?= Date: Wed, 4 Jan 2017 09:41:49 -0500 Subject: [PATCH] Removing link to copyright website, making more statements notable (#928) --- config/authorities/licenses.yml | 4 ++-- config/locales/en.yml | 2 -- spec/features/scanned_resource_spec.rb | 11 +++++++++++ spec/services/rights_statement_service_spec.rb | 6 ++++++ 4 files changed, 19 insertions(+), 4 deletions(-) diff --git a/config/authorities/licenses.yml b/config/authorities/licenses.yml index 9b61596fc..6dd67ed21 100644 --- a/config/authorities/licenses.yml +++ b/config/authorities/licenses.yml @@ -76,7 +76,7 @@ terms:
For other uses you need to obtain permission from the rightsholder(s). - id: http://rightsstatements.org/vocab/NoC-CR/1.0/ term: No Copyright - Contractual Restrictions - notable: false + notable: true active: true scopeNote: | This Rights Statement can only be used for Items that are in the Public @@ -94,7 +94,7 @@ terms: cultural protections, digitization agreements or donor agreements. - id: http://rightsstatements.org/vocab/NoC-OKLR/1.0/ term: No Copyright - Other Known Legal Restrictions - notable: false + notable: true active: true scopeNote: | This Rights Statement should be used for Items that are in the public diff --git a/config/locales/en.yml b/config/locales/en.yml index 4734a16fe..8749b86d4 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -29,8 +29,6 @@ en: Princeton University Library claims no copyright governing this digital resource. It is provided for free, on a non-commercial, open-access basis, for fair-use academic and research purposes only. Anyone who claims copyright over any part of these resources and feels that they should not be presented in this manner is invited to contact Princeton University Library, who will in turn consider such concerns and make every effort to respond appropriately. boilerplate: | Princeton University Library claims no copyright governing this digital resource. It is provided for free, on a non-commercial, open-access basis, for fair-use academic and research purposes only. Anyone who claims copyright over any part of these resources and feels that they should not be presented in this manner is invited to contact Princeton University Library, who will in turn consider such concerns and make every effort to respond appropriately. We request that users reproducing this resource cite it according the guidelines described at http://rbsc.princeton.edu/policies/forms-citation. - - Princeton users with copyright questions or concerns should refer to http://www.princeton.edu/copyright/. simple_form: labels: defaults: diff --git a/spec/features/scanned_resource_spec.rb b/spec/features/scanned_resource_spec.rb index 802fca6ab..7d7c985ff 100644 --- a/spec/features/scanned_resource_spec.rb +++ b/spec/features/scanned_resource_spec.rb @@ -24,4 +24,15 @@ expect(page).to have_selector "a", text: I18n.t('blacklight.back_to_search') end end + + context "an anonymous user" do + let(:scanned_resource) { FactoryGirl.create(:scanned_resource, title: ["first title", "second title"], user: user) } + + scenario "viewing a scanned resource it should display rights boilerplate" do + visit polymorphic_path [scanned_resource] + expect(page).to have_selector "h1", text: "first title" + expect(page).to have_text "Princeton University Library claims no copyright governing" + expect(page).not_to have_text "Princeton users with copyright questions or concerns" + end + end end diff --git a/spec/services/rights_statement_service_spec.rb b/spec/services/rights_statement_service_spec.rb index 02fa51aeb..9398551c0 100644 --- a/spec/services/rights_statement_service_spec.rb +++ b/spec/services/rights_statement_service_spec.rb @@ -2,6 +2,7 @@ RSpec.describe RightsStatementService do let(:uri) { 'http://rightsstatements.org/vocab/InC/1.0/' } + let(:noc_cr_uri) { 'http://rightsstatements.org/vocab/NoC-CR/1.0/' } let(:desc) { 'This Item is protected by copyright and/or related rights.' } let(:valid_statements) { [ @@ -21,6 +22,11 @@ expect(described_class.new.definition(uri)).to include('
') end + it "indicates which statements should have notes enabled" do + expect(described_class.new.notable?(uri)).to be false + expect(described_class.new.notable?(noc_cr_uri)).to be true + end + it "lists all valid rights statements" do expect(described_class.new.valid_statements).to eq(valid_statements) end