Skip to content
Snippets Groups Projects
Verified Commit 27dc4c62 authored by Daniel Hornung's avatar Daniel Hornung
Browse files

TEST: More extensive test data.

parent 91529537
No related branches found
No related tags found
4 merge requests!100WIP: Filling XLSX: Seems to be working.,!94ENH: add framework for converting json schema into table templates,!93Filling XLSX: Everything except multiple choice.,!92ENH: xlsx template generator
Pipeline #48132 passed
No preview for this file type
......@@ -9,10 +9,10 @@ Training:
recommended_properties:
date:
datatype: DATETIME
description: 'date'
description: 'The date of the training.'
url:
datatype: TEXT
description: 'url'
description: 'The URL'
subjects:
datatype: LIST<TEXT>
coach:
......
......@@ -12,7 +12,7 @@
"description": "The name of the Record to be created"
},
"date": {
"description": "date",
"description": "The date of the training.",
"anyOf": [
{
"type": "string",
......@@ -26,7 +26,7 @@
},
"url": {
"type": "string",
"description": "url"
"description": "The URL"
},
"subjects": {
"type": "array",
......@@ -126,4 +126,4 @@
],
"additionalProperties": false,
"$schema": "https://json-schema.org/draft/2020-12/schema"
}
\ No newline at end of file
}
......@@ -116,8 +116,8 @@ def test_generate_sheets_from_schema():
foreign_keys={'Training': {"__this__": ['date', 'url']}})
assert "Training" in sdef
tdef = sdef['Training']
assert tdef['date'] == (ColumnType.SCALAR, 'date', ["Training", 'date'])
assert tdef['url'] == (ColumnType.SCALAR, 'url', ["Training", 'url'])
assert tdef['date'] == (ColumnType.SCALAR, 'The date of the training.', ["Training", 'date'])
assert tdef['url'] == (ColumnType.SCALAR, 'The URL', ["Training", 'url'])
assert tdef['supervisor.family_name'] == (ColumnType.SCALAR, None, ["Training", 'supervisor',
'family_name'])
assert tdef['supervisor.given_name'] == (ColumnType.SCALAR, None, ["Training", 'supervisor',
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment