Skip to content

Commit

Permalink
adding discogs and sharevde examples with context flag
Browse files Browse the repository at this point in the history
  • Loading branch information
hudajkhan committed Jul 31, 2019
1 parent ae3323c commit 30f7a18
Show file tree
Hide file tree
Showing 3 changed files with 83 additions and 0 deletions.
29 changes: 29 additions & 0 deletions __tests__/__fixtures__/DiscogsExample.json
@@ -0,0 +1,29 @@
{
"id": "resourceTemplate:bf2:Discogs:Example",
"resourceLabel": "Discogs Examples",
"resourceURI": "http://exampleontology.com/Discogs",
"remark": "This is altered greatly for testing purposes",
"propertyTemplates": [
{
"propertyLabel": "Related Discogs Entity",
"propertyURI": "http://exampleontology.com/relatedDiscogs",
"mandatory": "true",
"repeatable": "true",
"type": "lookup",
"subtype": "context",
"resourceTemplates": [],
"valueConstraint": {
"valueTemplateRefs": [],
"useValuesFrom": [
"urn:discogs"
],
"valueDataType": {
"dataTypeURI": "http://id.loc.gov/ontologies/bibframe/Work"
},
"defaults": []
},
"remark": "http://id.loc.gov/authorities/names.html"

}
]
}
52 changes: 52 additions & 0 deletions __tests__/__fixtures__/ShareVDEExample.json
@@ -0,0 +1,52 @@
{
"id": "resourceTemplate:bf2:ShareVDE:Example",
"resourceLabel": "ShareVDE Examples",
"resourceURI": "http://exampleontology.com/ShareVDE",
"remark": "This is altered greatly for testing purposes",
"propertyTemplates": [
{
"propertyLabel": "Related Work",
"propertyURI": "http://exampleontology.com/relatedWork",
"mandatory": "true",
"repeatable": "true",
"type": "lookup",
"subtype": "context",
"resourceTemplates": [],
"valueConstraint": {
"valueTemplateRefs": [],
"useValuesFrom": [
"urn:ld4p:qa:sharevde_cornell_work_ld4l_cache",
"urn:ld4p:qa:sharevde_stanford_work_ld4l_cache",
"urn:ld4p:qa:sharevde_ucsd_work_ld4l_cache"
],
"valueDataType": {
"dataTypeURI": "http://id.loc.gov/ontologies/bibframe/Work"
},
"defaults": []
},
"remark": "http://id.loc.gov/authorities/names.html"

},
{
"propertyLabel": "Related Instance",
"propertyURI": "http://exampleontology.com/relatedInstance",
"mandatory": "true",
"repeatable": "true",
"type": "lookup",
"resourceTemplates": [],
"valueConstraint": {
"valueTemplateRefs": [],
"useValuesFrom": [
"urn:ld4p:qa:sharevde_ucsd_instance_ld4l_cache",
"urn:ld4p:qa:sharevde_stanford_instance_ld4l_cache",
"urn:ld4p:qa:sharevde_cornell_instance_ld4l_cache"
],
"valueDataType": {
"dataTypeURI": "http://id.loc.gov/ontologies/bibframe/Instance"
},
"defaults": []
},
"remark": "http://id.loc.gov/authorities/names.html"
}
]
}
2 changes: 2 additions & 0 deletions __tests__/fixtureLoaderHelper.js
Expand Up @@ -55,6 +55,8 @@ const rtFileNames = [
'literalRepeatNoDefault.json',
'propertyURIRepeated.json',
'rdaItemMonograph.json',
'ShareVDEExample.json',
'DiscogsExample.json',
]

export const resourceTemplateId2Json = loadFixtureResourceTemplates()
Expand Down

0 comments on commit 30f7a18

Please sign in to comment.