fix: dependency
This commit is contained in:
parent
dd5e725fde
commit
2f37aeac5b
22 changed files with 232 additions and 27 deletions
|
|
@ -8,13 +8,10 @@ version = "0.2.0a8"
|
||||||
authors = [{name = "Emmanuel Garette", email = "gnunux@gnunux.info"}]
|
authors = [{name = "Emmanuel Garette", email = "gnunux@gnunux.info"}]
|
||||||
readme = "README.md"
|
readme = "README.md"
|
||||||
description = "Rougail output json"
|
description = "Rougail output json"
|
||||||
requires-python = ">=3.8"
|
requires-python = ">=3.10"
|
||||||
license = {file = "LICENSE"}
|
license = {file = "LICENSE"}
|
||||||
classifiers = [
|
classifiers = [
|
||||||
"License :: OSI Approved :: GNU Library or Lesser General Public License (LGPL)",
|
"License :: OSI Approved :: GNU Library or Lesser General Public License (LGPL)",
|
||||||
"Programming Language :: Python",
|
|
||||||
"Programming Language :: Python :: 3.8",
|
|
||||||
"Programming Language :: Python :: 3.9",
|
|
||||||
"Programming Language :: Python :: 3.10",
|
"Programming Language :: Python :: 3.10",
|
||||||
"Programming Language :: Python :: 3.11",
|
"Programming Language :: Python :: 3.11",
|
||||||
"Programming Language :: Python :: 3.12",
|
"Programming Language :: Python :: 3.12",
|
||||||
|
|
@ -24,10 +21,10 @@ classifiers = [
|
||||||
"Operating System :: OS Independent",
|
"Operating System :: OS Independent",
|
||||||
"Natural Language :: English",
|
"Natural Language :: English",
|
||||||
"Natural Language :: French",
|
"Natural Language :: French",
|
||||||
|
|
||||||
]
|
]
|
||||||
|
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"rougail >= 1.1,<2",
|
"rougail-base >= 1.1,<2",
|
||||||
]
|
]
|
||||||
|
|
||||||
[project.urls]
|
[project.urls]
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,5 @@
|
||||||
|
{
|
||||||
|
"var1": "string1",
|
||||||
|
"var2": "string1",
|
||||||
|
"var3": "string1"
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,15 @@
|
||||||
|
{
|
||||||
|
"leadership": [
|
||||||
|
{
|
||||||
|
"leader": "string1"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"leader": "string2",
|
||||||
|
"follower": "string2"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"leader": "string3",
|
||||||
|
"follower": "string3"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,5 @@
|
||||||
|
{
|
||||||
|
"var1": "string1",
|
||||||
|
"var2": "string1",
|
||||||
|
"var3": "string1"
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,15 @@
|
||||||
|
{
|
||||||
|
"leadership": [
|
||||||
|
{
|
||||||
|
"leader": "string1"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"leader": "string2",
|
||||||
|
"follower": "string2"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"leader": "string3",
|
||||||
|
"follower": "string3"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,7 @@
|
||||||
|
{
|
||||||
|
"rougail": {
|
||||||
|
"var1": "string1",
|
||||||
|
"var2": "string1",
|
||||||
|
"var3": "string1"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,17 @@
|
||||||
|
{
|
||||||
|
"rougail": {
|
||||||
|
"leadership": [
|
||||||
|
{
|
||||||
|
"leader": "string1"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"leader": "string2",
|
||||||
|
"follower": "string2"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"leader": "string3",
|
||||||
|
"follower": "string3"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,7 @@
|
||||||
|
{
|
||||||
|
"rougail": {
|
||||||
|
"var1": "string1",
|
||||||
|
"var2": "string1",
|
||||||
|
"var3": "string1"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,17 @@
|
||||||
|
{
|
||||||
|
"rougail": {
|
||||||
|
"leadership": [
|
||||||
|
{
|
||||||
|
"leader": "string1"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"leader": "string2",
|
||||||
|
"follower": "string2"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"leader": "string3",
|
||||||
|
"follower": "string3"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,7 @@
|
||||||
|
{
|
||||||
|
"rougail": {
|
||||||
|
"var1": null,
|
||||||
|
"var2": null,
|
||||||
|
"var3": null
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,13 @@
|
||||||
|
{
|
||||||
|
"rougail": {
|
||||||
|
"leadership": [
|
||||||
|
{
|
||||||
|
"leader": "a"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"leader": "b",
|
||||||
|
"follower": "value"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,7 @@
|
||||||
|
{
|
||||||
|
"rougail": {
|
||||||
|
"var1": "string1",
|
||||||
|
"var2": "string1",
|
||||||
|
"var3": "string1"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,17 @@
|
||||||
|
{
|
||||||
|
"rougail": {
|
||||||
|
"leadership": [
|
||||||
|
{
|
||||||
|
"leader": "string1"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"leader": "string2",
|
||||||
|
"follower": "string2"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"leader": "string3",
|
||||||
|
"follower": "string3"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,8 @@
|
||||||
|
{
|
||||||
|
"_errors": [
|
||||||
|
"The following variables are mandatory but have no value:",
|
||||||
|
" - rougail.var1 (a first variable)",
|
||||||
|
" - rougail.var2 (a second variable)",
|
||||||
|
" - rougail.var3 (a new variable)"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,13 @@
|
||||||
|
{
|
||||||
|
"rougail": {
|
||||||
|
"leadership": [
|
||||||
|
{
|
||||||
|
"leader": "a"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"leader": "b",
|
||||||
|
"follower": "value"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,5 @@
|
||||||
|
{
|
||||||
|
"var1": null,
|
||||||
|
"var2": null,
|
||||||
|
"var3": null
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,11 @@
|
||||||
|
{
|
||||||
|
"leadership": [
|
||||||
|
{
|
||||||
|
"leader": "a"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"leader": "b",
|
||||||
|
"follower": "value"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,5 @@
|
||||||
|
{
|
||||||
|
"var1": "string1",
|
||||||
|
"var2": "string1",
|
||||||
|
"var3": "string1"
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,15 @@
|
||||||
|
{
|
||||||
|
"leadership": [
|
||||||
|
{
|
||||||
|
"leader": "string1"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"leader": "string2",
|
||||||
|
"follower": "string2"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"leader": "string3",
|
||||||
|
"follower": "string3"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,8 @@
|
||||||
|
{
|
||||||
|
"_errors": [
|
||||||
|
"The following variables are mandatory but have no value:",
|
||||||
|
" - var1 (a first variable)",
|
||||||
|
" - var2 (a second variable)",
|
||||||
|
" - var3 (a new variable)"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,11 @@
|
||||||
|
{
|
||||||
|
"leadership": [
|
||||||
|
{
|
||||||
|
"leader": "a"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"leader": "b",
|
||||||
|
"follower": "value"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
@ -28,7 +28,7 @@ def test_dir(request):
|
||||||
return request.param
|
return request.param
|
||||||
|
|
||||||
|
|
||||||
def _test_dictionaries(test_dir, namespace, ext, *, read_write=True, mandatory=False, do_calc=True):
|
def _test_structural_files(test_dir, namespace, ext, *, read_write=True, mandatory=False, do_calc=True):
|
||||||
rougailconfig = get_rougail_config(test_dir, namespace)
|
rougailconfig = get_rougail_config(test_dir, namespace)
|
||||||
if not rougailconfig:
|
if not rougailconfig:
|
||||||
return
|
return
|
||||||
|
|
@ -68,42 +68,42 @@ def _test_dictionaries(test_dir, namespace, ext, *, read_write=True, mandatory=F
|
||||||
assert generated_output == attented_output, f'filename {output_file}'
|
assert generated_output == attented_output, f'filename {output_file}'
|
||||||
|
|
||||||
|
|
||||||
def test_dictionaries_json(test_dir):
|
def test_structural_files_json(test_dir):
|
||||||
_test_dictionaries(test_dir, True, EXT)
|
_test_structural_files(test_dir, True, EXT)
|
||||||
|
|
||||||
|
|
||||||
def test_dictionaries_json_errors(test_dir):
|
def test_structural_files_json_errors(test_dir):
|
||||||
_test_dictionaries(test_dir, True, EXT, do_calc=False, mandatory=True)
|
_test_structural_files(test_dir, True, EXT, do_calc=False, mandatory=True)
|
||||||
|
|
||||||
|
|
||||||
def test_dictionaries_json_read_only(test_dir):
|
def test_structural_files_json_read_only(test_dir):
|
||||||
_test_dictionaries(test_dir, True, EXT, read_write=False)
|
_test_structural_files(test_dir, True, EXT, read_write=False)
|
||||||
|
|
||||||
|
|
||||||
def test_dictionaries_json_mandatory(test_dir):
|
def test_structural_files_json_mandatory(test_dir):
|
||||||
_test_dictionaries(test_dir, True, EXT, mandatory=True)
|
_test_structural_files(test_dir, True, EXT, mandatory=True)
|
||||||
|
|
||||||
|
|
||||||
def test_dictionaries_json_mandatory_read_only(test_dir):
|
def test_structural_files_json_mandatory_read_only(test_dir):
|
||||||
_test_dictionaries(test_dir, True, EXT, read_write=False, mandatory=True)
|
_test_structural_files(test_dir, True, EXT, read_write=False, mandatory=True)
|
||||||
|
|
||||||
|
|
||||||
#################
|
#################
|
||||||
def test_dictionaries_json_namespace(test_dir):
|
def test_structural_files_json_namespace(test_dir):
|
||||||
_test_dictionaries(test_dir, False, EXT)
|
_test_structural_files(test_dir, False, EXT)
|
||||||
|
|
||||||
|
|
||||||
def test_dictionaries_json_namespace_errors(test_dir):
|
def test_structural_files_json_namespace_errors(test_dir):
|
||||||
_test_dictionaries(test_dir, False, EXT, do_calc=False, mandatory=True)
|
_test_structural_files(test_dir, False, EXT, do_calc=False, mandatory=True)
|
||||||
|
|
||||||
|
|
||||||
def test_dictionaries_json_namespace_read_only(test_dir):
|
def test_structural_files_json_namespace_read_only(test_dir):
|
||||||
_test_dictionaries(test_dir, False, EXT, read_write=False)
|
_test_structural_files(test_dir, False, EXT, read_write=False)
|
||||||
|
|
||||||
|
|
||||||
def test_dictionaries_json_namespace_mandatory(test_dir):
|
def test_structural_files_json_namespace_mandatory(test_dir):
|
||||||
_test_dictionaries(test_dir, False, EXT, mandatory=True)
|
_test_structural_files(test_dir, False, EXT, mandatory=True)
|
||||||
|
|
||||||
|
|
||||||
def test_dictionaries_json_namespace_mandatory_read_only(test_dir):
|
def test_structural_files_json_namespace_mandatory_read_only(test_dir):
|
||||||
_test_dictionaries(test_dir, False, EXT, read_write=False, mandatory=True)
|
_test_structural_files(test_dir, False, EXT, read_write=False, mandatory=True)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue