From 96e38edde79735b4080ec08d57e9f54759e97b61 Mon Sep 17 00:00:00 2001 From: Martin Czygan Date: Thu, 2 Jan 2020 17:35:54 +0100 Subject: datacite: add conversion fixtures The `test_datacite_conversions` function will compare an input (datacite) document to an expected output (release entity as JSON). This way, it should not be too hard to add more cases by adding: input, output - and by increasing the counter in the range loop within the test. To view input and result side by side with vim, change into the test directory and run: tests/files/datacite $ ./caseview.sh 18 --- .../tests/files/datacite/datacite_result_09.json | 35 ++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 python/tests/files/datacite/datacite_result_09.json (limited to 'python/tests/files/datacite/datacite_result_09.json') diff --git a/python/tests/files/datacite/datacite_result_09.json b/python/tests/files/datacite/datacite_result_09.json new file mode 100644 index 00000000..01f92f85 --- /dev/null +++ b/python/tests/files/datacite/datacite_result_09.json @@ -0,0 +1,35 @@ +{ + "extra": { + "datacite": { + "subjects": [ + { + "subject": "Direktdiodenlasersysteme" + }, + { + "subject": "Physics", + "subjectScheme": "linsearch" + } + ] + } + }, + "title": "BrightLas : TP3.3. Module f\u00fcr Direktdiodenstrahlquellen bis 4kW und Untersuchungen zur Leistungsskalierung (Diodemodul) : zum Verbundvorhaben Direktdiodenlaseranlagen und -systeme (VP3) im F\u00f6rderschwerpunkt innovative regionale Wachstumskerne, BMBF : Abschlussbericht", + "release_type": "report", + "release_stage": "published", + "release_year": 2016, + "ext_ids": { + "doi": "10.2314/gbv:880813733" + }, + "publisher": "[Lumics GmbH]", + "language": "de", + "contribs": [ + { + "index": 0, + "raw_name": "Kirstaedter, Nils", + "given_name": "Nils", + "surname": "Kirstaedter", + "role": "author" + } + ], + "refs": [], + "abstracts": [] +} \ No newline at end of file -- cgit v1.2.3