Skip to content

Instantly share code, notes, and snippets.

@tpluscode
Last active September 11, 2019 17:35
Show Gist options
  • Save tpluscode/78b8214ab6df6bd9be5be8859a50e0e2 to your computer and use it in GitHub Desktop.
Save tpluscode/78b8214ab6df6bd9be5be8859a50e0e2 to your computer and use it in GitHub Desktop.
API Days demo
PREFIX dataCube: <https://rdf-cube-curation.described.at/>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
INSERT DATA {
GRAPH <http://localhost:5678/project/apidays> {
<http://localhost:5678/project/apidays>
a dataCube:Project ;
<http://schema.org/name> "Fact table project" .
}
}
PREFIX api: <https://rdf-cube-curation.described.at/api/>
PREFIX dataCube: <https://rdf-cube-curation.described.at/>
With Class api:ProjectPlaceholder {
Expect Property api:project {
Expect Operation <http://schema.org/CreateAction>
}
}
With Class dataCube:Project {
With Operation api:DeleteProject {
Invoke {
Expect Status 204
}
}
}
With Operation <http://schema.org/CreateAction> {
Invoke {
Content-Type "text/turtle"
```
<> <http://schema.org/name> "Fact table project" .
```
} => {
Expect Type dataCube:Project
# More tests of the project
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment