Skip to content

Commit

Permalink
test(affiliations-tools/id-ror): add an example
Browse files Browse the repository at this point in the history
  • Loading branch information
revolj committed Aug 8, 2024
1 parent 29eae6f commit f2a3b3c
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 13 deletions.
5 changes: 5 additions & 0 deletions services/affiliations-tools/examples.http
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,11 @@ Content-Type: application/json
"id": 4,
"status": "non-existing",
"value": "Sphere Energy SAS, 250 Bis Boulevard Saint Germain, 75007, Paris, France"
},
{
"id": 5,
"status": "non-existing",
"value" : "Department of Computational Engineering, CSC — Scientific Computing Ltd, P.O. Box 405, 02101, Espoo, Finland"
}
]

Expand Down
30 changes: 17 additions & 13 deletions services/affiliations-tools/tests.hurl
Original file line number Diff line number Diff line change
Expand Up @@ -465,19 +465,13 @@ Année,Adresse
```

HTTP 200
[Asserts]
body contains "Année;Adresse;RNSR"
body contains "2015;CNRS UMR AMAP MONTPELLIER FRA;200317641S"
body contains "2015;IRD UMR AMAP MONTPELLIER FRA;200317641S"
body contains "2015;University of Bordeaux, IMS, CNRS UMR5218, Talence, F-33405, France;200711887V"
body contains "2015;CENBG, CNRS/IN2P3, Chemin du Solarium B. P. 120, Gradignan, F-33175, France;"
#```
#Année;Adresse;RNSR
#2015;CNRS UMR AMAP MONTPELLIER FRA;200317641S
#2015;IRD UMR AMAP MONTPELLIER FRA;200317641S
#2015;University of Bordeaux, IMS, CNRS UMR5218, Talence, F-33405, France;200711887V
#2015;CENBG, CNRS/IN2P3, Chemin du Solarium B. P. 120, Gradignan, F-33175, France;
#```
```
Année;Adresse;RNSR
2015;CNRS UMR AMAP MONTPELLIER FRA;200317641S
2015;IRD UMR AMAP MONTPELLIER FRA;200317641S
2015;University of Bordeaux, IMS, CNRS UMR5218, Talence, F-33405, France;200711887V
2015;CENBG, CNRS/IN2P3, Chemin du Solarium B. P. 120, Gradignan, F-33175, France;
```



Expand Down Expand Up @@ -576,6 +570,11 @@ content-type: application/json
"id": 4,
"status": "non-existing",
"value": "Sphere Energy SAS, 250 Bis Boulevard Saint Germain, 75007, Paris, France"
},
{
"id": 5,
"status": "non-existing",
"value" : "Department of Computational Engineering, CSC — Scientific Computing Ltd, P.O. Box 405, 02101, Espoo, Finland"
}
]

Expand Down Expand Up @@ -626,4 +625,9 @@ HTTP 200
"id": 4,
"status": "non-existing",
"value": "No match found"
},
{
"id": 5,
"status": "non-existing",
"value": "No match found"
}]
6 changes: 6 additions & 0 deletions services/affiliations-tools/v1/ror/get-id.ini
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ post.requestBody.content.application/json.example.2.value = NSF's National Optic
post.requestBody.content.application/json.example.3.id = 4
post.requestBody.content.application/json.example.3.status = non-existing
post.requestBody.content.application/json.example.3.value = Sphere Energy SAS, 250 Bis Boulevard Saint Germain, 75007, Paris, France
post.requestBody.content.application/json.example.4.id = 5
post.requestBody.content.application/json.example.4.status = non-existing
post.requestBody.content.application/json.example.4.value = Department of Computational Engineering, CSC — Scientific Computing Ltd, P.O. Box 405, 02101, Espoo, Finland
post.responses.default.content.application/json.example.0.id = 1
post.responses.default.content.application/json.example.0.status = wrong
Expand Down Expand Up @@ -59,6 +62,9 @@ post.responses.default.content.application/json.example.2.value.id_geonames = 53
post.responses.default.content.application/json.example.3.id = 4
post.responses.default.content.application/json.example.3.status = non-existing
post.responses.default.content.application/json.example.3.value = No match found
post.responses.default.content.application/json.example.4.id = 5
post.responses.default.content.application/json.example.4.status = non-existing
post.responses.default.content.application/json.example.4.value = No match found
#'

[use]
Expand Down

0 comments on commit f2a3b3c

Please sign in to comment.