Skip to content

Commit

Permalink
Merge pull request #36 from RockefellerArchiveCenter/issue-26
Browse files Browse the repository at this point in the history
Improves note validation
  • Loading branch information
helrond authored Oct 1, 2020
2 parents 2e1f5ad + 6fccd35 commit 3387152
Show file tree
Hide file tree
Showing 29 changed files with 222 additions and 94 deletions.
4 changes: 2 additions & 2 deletions fixtures/invalid/collection/invalid-format.json
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@
}
],
"title": "Arrangement:",
"type": "multipart"
"type": "arrangement"
},
{
"source": "archivesspace",
Expand All @@ -218,7 +218,7 @@
}
],
"title": "Summary:",
"type": "multipart"
"type": "abstract"
}
],
"online": false,
Expand Down
4 changes: 2 additions & 2 deletions fixtures/invalid/collection/invalid-type.json
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@
}
],
"title": "Arrangement:",
"type": "multipart"
"type": "arrangement"
},
{
"source": "archivesspace",
Expand All @@ -218,7 +218,7 @@
}
],
"title": "Summary:",
"type": "multipart"
"type": "abstract"
}
],
"online": false,
Expand Down
4 changes: 2 additions & 2 deletions fixtures/invalid/collection/no-category.json
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@
}
],
"title": "Arrangement:",
"type": "multipart"
"type": "arrangement"
},
{
"source": "archivesspace",
Expand All @@ -217,7 +217,7 @@
}
],
"title": "Summary:",
"type": "multipart"
"type": "abstract"
}
],
"online": false,
Expand Down
4 changes: 2 additions & 2 deletions fixtures/invalid/collection/no-creators.json
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@
}
],
"title": "Arrangement:",
"type": "multipart"
"type": "arrangement"
},
{
"source": "archivesspace",
Expand All @@ -191,7 +191,7 @@
}
],
"title": "Summary:",
"type": "multipart"
"type": "abstract"
}
],
"online": false,
Expand Down
4 changes: 2 additions & 2 deletions fixtures/invalid/collection/no-dates.json
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@
}
],
"title": "Arrangement:",
"type": "multipart"
"type": "arrangement"
},
{
"source": "archivesspace",
Expand All @@ -209,7 +209,7 @@
}
],
"title": "Summary:",
"type": "multipart"
"type": "abstract"
}
],
"online": false,
Expand Down
4 changes: 2 additions & 2 deletions fixtures/invalid/collection/no-extents.json
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@
}
],
"title": "Arrangement:",
"type": "multipart"
"type": "arrangement"
},
{
"source": "archivesspace",
Expand All @@ -209,7 +209,7 @@
}
],
"title": "Summary:",
"type": "multipart"
"type": "abstract"
}
],
"online": false,
Expand Down
4 changes: 2 additions & 2 deletions fixtures/invalid/collection/no-external-identifiers.json
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@
}
],
"title": "Arrangement:",
"type": "multipart"
"type": "arrangement"
},
{
"source": "archivesspace",
Expand All @@ -213,7 +213,7 @@
}
],
"title": "Summary:",
"type": "multipart"
"type": "abstract"
}
],
"online": false,
Expand Down
4 changes: 2 additions & 2 deletions fixtures/invalid/collection/no-formats.json
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@
}
],
"title": "Arrangement:",
"type": "multipart"
"type": "arrangement"
},
{
"source": "archivesspace",
Expand All @@ -216,7 +216,7 @@
}
],
"title": "Summary:",
"type": "multipart"
"type": "abstract"
}
],
"online": false,
Expand Down
4 changes: 2 additions & 2 deletions fixtures/invalid/collection/no-group.json
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@
}
],
"title": "Arrangement:",
"type": "multipart"
"type": "arrangement"
},
{
"source": "archivesspace",
Expand All @@ -213,7 +213,7 @@
}
],
"title": "Summary:",
"type": "multipart"
"type": "abstract"
}
],
"online": false,
Expand Down
4 changes: 2 additions & 2 deletions fixtures/invalid/collection/no-languages.json
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@
}
],
"title": "Arrangement:",
"type": "multipart"
"type": "arrangement"
},
{
"source": "archivesspace",
Expand All @@ -213,7 +213,7 @@
}
],
"title": "Summary:",
"type": "multipart"
"type": "abstract"
}
],
"online": false,
Expand Down
4 changes: 2 additions & 2 deletions fixtures/invalid/collection/no-online.json
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@
}
],
"title": "Arrangement:",
"type": "multipart"
"type": "arrangement"
},
{
"source": "archivesspace",
Expand All @@ -218,7 +218,7 @@
}
],
"title": "Summary:",
"type": "multipart"
"type": "abstract"
}
],
"organizations": [
Expand Down
4 changes: 2 additions & 2 deletions fixtures/invalid/collection/no-title.json
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@
}
],
"title": "Arrangement:",
"type": "multipart"
"type": "arrangement"
},
{
"source": "archivesspace",
Expand All @@ -218,7 +218,7 @@
}
],
"title": "Summary:",
"type": "multipart"
"type": "abstract"
}
],
"online": false,
Expand Down
4 changes: 2 additions & 2 deletions fixtures/invalid/collection/no-type.json
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@
}
],
"title": "Arrangement:",
"type": "multipart"
"type": "arrangement"
},
{
"source": "archivesspace",
Expand All @@ -218,7 +218,7 @@
}
],
"title": "Summary:",
"type": "multipart"
"type": "abstract"
}
],
"online": false,
Expand Down
14 changes: 14 additions & 0 deletions fixtures/invalid/note/invalid-subnote-content.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"source": "archivesspace",
"subnotes": [
{
"content": [
{"key": "value"}
],
"items": [],
"type": "text"
}
],
"title": "Conditions Governing Access",
"type": "accessrestrict"
}
12 changes: 12 additions & 0 deletions fixtures/invalid/note/invalid-subnote-items.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"source": "archivesspace",
"subnotes": [
{
"content": [],
"items": ["Open for research with select materials restricted as noted. Brittle or damaged items are available at the discretion of RAC.\n\nResearchers interested in accessing digital media (floppy disks, CDs, DVDs, etc.) or audiovisual material (audio cassettes, VHS, etc.) in this collection must use an access surrogate. The original items may not be accessed because of preservation concerns. To request an access surrogate be made, or if you are unsure if there is an access surrogate, please contact an archivist."],
"type": "text"
}
],
"title": "Conditions Governing Access",
"type": "accessrestrict"
}
14 changes: 14 additions & 0 deletions fixtures/invalid/note/invalid-subnote-type.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"source": "archivesspace",
"subnotes": [
{
"content": [
"Open for research with select materials restricted as noted. Brittle or damaged items are available at the discretion of RAC.\n\nResearchers interested in accessing digital media (floppy disks, CDs, DVDs, etc.) or audiovisual material (audio cassettes, VHS, etc.) in this collection must use an access surrogate. The original items may not be accessed because of preservation concerns. To request an access surrogate be made, or if you are unsure if there is an access surrogate, please contact an archivist."
],
"items": [],
"type": "accessrestrict"
}
],
"title": "Conditions Governing Access",
"type": "accessrestrict"
}
14 changes: 14 additions & 0 deletions fixtures/invalid/note/invalid-type.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"source": "archivesspace",
"subnotes": [
{
"content": [
"Open for research with select materials restricted as noted. Brittle or damaged items are available at the discretion of RAC.\n\nResearchers interested in accessing digital media (floppy disks, CDs, DVDs, etc.) or audiovisual material (audio cassettes, VHS, etc.) in this collection must use an access surrogate. The original items may not be accessed because of preservation concerns. To request an access surrogate be made, or if you are unsure if there is an access surrogate, please contact an archivist."
],
"items": [],
"type": "text"
}
],
"title": "Conditions Governing Access",
"type": "multipart"
}
13 changes: 13 additions & 0 deletions fixtures/invalid/note/missing-source.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"subnotes": [
{
"content": [
"Open for research with select materials restricted as noted. Brittle or damaged items are available at the discretion of RAC.\n\nResearchers interested in accessing digital media (floppy disks, CDs, DVDs, etc.) or audiovisual material (audio cassettes, VHS, etc.) in this collection must use an access surrogate. The original items may not be accessed because of preservation concerns. To request an access surrogate be made, or if you are unsure if there is an access surrogate, please contact an archivist."
],
"items": [],
"type": "text"
}
],
"title": "Conditions Governing Access",
"type": "accessrestrict"
}
13 changes: 13 additions & 0 deletions fixtures/invalid/note/missing-subnote-type.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"source": "archivesspace",
"subnotes": [
{
"content": [
"Open for research with select materials restricted as noted. Brittle or damaged items are available at the discretion of RAC.\n\nResearchers interested in accessing digital media (floppy disks, CDs, DVDs, etc.) or audiovisual material (audio cassettes, VHS, etc.) in this collection must use an access surrogate. The original items may not be accessed because of preservation concerns. To request an access surrogate be made, or if you are unsure if there is an access surrogate, please contact an archivist."
],
"items": []
}
],
"title": "Conditions Governing Access",
"type": "accessrestrict"
}
6 changes: 6 additions & 0 deletions fixtures/invalid/note/missing-subnotes.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"source": "archivesspace",
"subnotes": [],
"title": "Conditions Governing Access",
"type": "accessrestrict"
}
14 changes: 14 additions & 0 deletions fixtures/invalid/note/missing-title.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"source": "archivesspace",
"subnotes": [
{
"content": [
"Open for research with select materials restricted as noted. Brittle or damaged items are available at the discretion of RAC.\n\nResearchers interested in accessing digital media (floppy disks, CDs, DVDs, etc.) or audiovisual material (audio cassettes, VHS, etc.) in this collection must use an access surrogate. The original items may not be accessed because of preservation concerns. To request an access surrogate be made, or if you are unsure if there is an access surrogate, please contact an archivist."
],
"items": [],
"type": "text"
}
],
"type": "accessrestrict",
"title": ""
}
13 changes: 13 additions & 0 deletions fixtures/invalid/note/missing-type.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"source": "archivesspace",
"subnotes": [
{
"content": [
"Open for research with select materials restricted as noted. Brittle or damaged items are available at the discretion of RAC.\n\nResearchers interested in accessing digital media (floppy disks, CDs, DVDs, etc.) or audiovisual material (audio cassettes, VHS, etc.) in this collection must use an access surrogate. The original items may not be accessed because of preservation concerns. To request an access surrogate be made, or if you are unsure if there is an access surrogate, please contact an archivist."
],
"items": [],
"type": "text"
}
],
"title": "Conditions Governing Access"
}
4 changes: 2 additions & 2 deletions fixtures/valid/collection/3pnr9kariwnqpin5fohkv2hzs2.json
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@
}
],
"title": "Arrangement:",
"type": "multipart"
"type": "arrangement"
},
{
"source": "archivesspace",
Expand All @@ -218,7 +218,7 @@
}
],
"title": "Summary:",
"type": "multipart"
"type": "scopecontent"
}
],
"online": false,
Expand Down
2 changes: 1 addition & 1 deletion fixtures/valid/collection/3y5m8r7tfh7sffmctu3j3sf7i2.json
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@
}
],
"title": "Other Finding Aids",
"type": "multipart"
"type": "otherfindaid"
}
],
"online": false,
Expand Down
Loading

0 comments on commit 3387152

Please sign in to comment.