diff --git a/pyproject.toml b/pyproject.toml index a31430cbf..3557fb064 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -13,9 +13,6 @@ license = {file = "LICENSE"} classifiers = [ "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.11", "Programming Language :: Python :: 3.12", "Programming Language :: Python :: 3.13", diff --git a/tests/results/test/04_5disabled_calculation_boolean.adoc b/tests/results/test/04_5disabled_calculation_boolean.adoc new file mode 100644 index 000000000..5d017f01e --- /dev/null +++ b/tests/results/test/04_5disabled_calculation_boolean.adoc @@ -0,0 +1,23 @@ +[cols="1a,1a"] +|==== +| Variable | Description +| + +**condition** + +`https://rougail.readthedocs.io/en/latest/variable.html#variables-types[string]` `standard` `mandatory` | +A conditional variable. + +**Default**: no +| + +**variable1** + +`https://rougail.readthedocs.io/en/latest/variable.html#variables-types[string]` `basic` `mandatory` `__disabled__` | +A first variable. + +**Disabled**: if condition is egal to "yes". +| + +**variable2** + +`https://rougail.readthedocs.io/en/latest/variable.html#variables-types[string]` `basic` `mandatory` `__disabled__` | +A seconde variable. + +**Disabled**: if condition is not egal to "yes". +|==== + diff --git a/tests/results/test/04_5disabled_calculation_boolean.gitlab.md b/tests/results/test/04_5disabled_calculation_boolean.gitlab.md new file mode 100644 index 000000000..baf8dc0c6 --- /dev/null +++ b/tests/results/test/04_5disabled_calculation_boolean.gitlab.md @@ -0,0 +1,6 @@ +| Variable | Description | +|---------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------| +| **condition**
[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` `mandatory` | A conditional variable.
**Default**: no | +| **variable1**
[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `basic` `mandatory` *`disabled`* | A first variable.
**Disabled**: if condition is egal to "yes". | +| **variable2**
[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `basic` `mandatory` *`disabled`* | A seconde variable.
**Disabled**: if condition is not egal to "yes". | + diff --git a/tests/results/test/04_5disabled_calculation_boolean.json b/tests/results/test/04_5disabled_calculation_boolean.json new file mode 100644 index 000000000..3e7434764 --- /dev/null +++ b/tests/results/test/04_5disabled_calculation_boolean.json @@ -0,0 +1,94 @@ +{ + "condition": { + "type": "variable", + "default": { + "name": "Default", + "values": "no" + }, + "properties": [ + { + "type": "type", + "name": "string" + }, + { + "type": "mode", + "name": "standard" + }, + { + "type": "property", + "name": "mandatory" + } + ], + "paths": [ + "condition" + ], + "names": [ + "condition" + ], + "descriptions": [ + "A conditional variable." + ] + }, + "variable1": { + "type": "variable", + "properties": [ + { + "type": "type", + "name": "string" + }, + { + "type": "mode", + "name": "basic" + }, + { + "type": "property", + "name": "mandatory" + }, + { + "type": "property", + "name": "disabled", + "annotation": "if condition is egal to \"yes\"." + } + ], + "paths": [ + "variable1" + ], + "names": [ + "variable1" + ], + "descriptions": [ + "A first variable." + ] + }, + "variable2": { + "type": "variable", + "properties": [ + { + "type": "type", + "name": "string" + }, + { + "type": "mode", + "name": "basic" + }, + { + "type": "property", + "name": "mandatory" + }, + { + "type": "property", + "name": "disabled", + "annotation": "if condition is not egal to \"yes\"." + } + ], + "paths": [ + "variable2" + ], + "names": [ + "variable2" + ], + "descriptions": [ + "A seconde variable." + ] + } +} \ No newline at end of file diff --git a/tests/results/test/04_5disabled_calculation_boolean.md b/tests/results/test/04_5disabled_calculation_boolean.md new file mode 100644 index 000000000..a8e5dd393 --- /dev/null +++ b/tests/results/test/04_5disabled_calculation_boolean.md @@ -0,0 +1,6 @@ +| Variable                                                                                                             | Description                                                                                                          | +|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| **condition**
[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` `mandatory` | A conditional variable.
**Default**: no | +| **variable1**
[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `basic` `mandatory` *`disabled`* | A first variable.
**Disabled**: if condition is egal to "yes". | +| **variable2**
[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `basic` `mandatory` *`disabled`* | A seconde variable.
**Disabled**: if condition is not egal to "yes". | + diff --git a/tests/results/test/04_5disabled_calculation_boolean.sh b/tests/results/test/04_5disabled_calculation_boolean.sh new file mode 100644 index 000000000..14976882a --- /dev/null +++ b/tests/results/test/04_5disabled_calculation_boolean.sh @@ -0,0 +1,14 @@ +┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓ +┃ Variable  ┃ Description  ┃ +┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩ +│ condition │ A conditional variable. │ +│  string   standard   mandatory  │ Default: no │ +├───────────────────────────────────────┼──────────────────────────────────────┤ +│ variable1 │ A first variable. │ +│  string   basic   mandatory    │ Disabled: if condition is egal to │ +│ disabled  │ "yes". │ +├───────────────────────────────────────┼──────────────────────────────────────┤ +│ variable2 │ A seconde variable. │ +│  string   basic   mandatory    │ Disabled: if condition is not egal │ +│ disabled  │ to "yes". │ +└───────────────────────────────────────┴──────────────────────────────────────┘ diff --git a/tests/results/test/warnings_04_5disabled_calculation_boolean b/tests/results/test/warnings_04_5disabled_calculation_boolean new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/tests/results/test/warnings_04_5disabled_calculation_boolean @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/tests/results/test_examples/04_5disabled_calculation_boolean.md b/tests/results/test_examples/04_5disabled_calculation_boolean.md new file mode 100644 index 000000000..1bc6b79e2 --- /dev/null +++ b/tests/results/test_examples/04_5disabled_calculation_boolean.md @@ -0,0 +1,15 @@ +# Example with mandatory variables not filled in + +```yaml +--- +variable1: example +variable2: example +``` +# Example with all variables modifiable + +```yaml +--- +condition: no +variable1: example +variable2: example +``` diff --git a/tests/results/test_examples/warnings_04_5disabled_calculation_boolean b/tests/results/test_examples/warnings_04_5disabled_calculation_boolean new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/tests/results/test_examples/warnings_04_5disabled_calculation_boolean @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/tests/results/test_namespace/04_5disabled_calculation_boolean.adoc b/tests/results/test_namespace/04_5disabled_calculation_boolean.adoc new file mode 100644 index 000000000..5bc80a1e8 --- /dev/null +++ b/tests/results/test_namespace/04_5disabled_calculation_boolean.adoc @@ -0,0 +1,29 @@ +== Variables for "Rougail" + +**rougail** + +`basic` + +[cols="1a,1a"] +|==== +| Variable | Description +| + +**rougail.condition** + +`https://rougail.readthedocs.io/en/latest/variable.html#variables-types[string]` `standard` `mandatory` | +A conditional variable. + +**Default**: no +| + +**rougail.variable1** + +`https://rougail.readthedocs.io/en/latest/variable.html#variables-types[string]` `basic` `mandatory` `__disabled__` | +A first variable. + +**Disabled**: if condition is egal to "yes". +| + +**rougail.variable2** + +`https://rougail.readthedocs.io/en/latest/variable.html#variables-types[string]` `basic` `mandatory` `__disabled__` | +A seconde variable. + +**Disabled**: if condition is not egal to "yes". +|==== + diff --git a/tests/results/test_namespace/04_5disabled_calculation_boolean.gitlab.md b/tests/results/test_namespace/04_5disabled_calculation_boolean.gitlab.md new file mode 100644 index 000000000..d1c15a521 --- /dev/null +++ b/tests/results/test_namespace/04_5disabled_calculation_boolean.gitlab.md @@ -0,0 +1,15 @@ +
Rougail + +>>> [!note] Informations +**rougail**
`basic` + + +>>> +| Variable | Description | +|-----------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------| +| **rougail.condition**
[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` `mandatory` | A conditional variable.
**Default**: no | +| **rougail.variable1**
[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `basic` `mandatory` *`disabled`* | A first variable.
**Disabled**: if condition is egal to "yes". | +| **rougail.variable2**
[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `basic` `mandatory` *`disabled`* | A seconde variable.
**Disabled**: if condition is not egal to "yes". | + +
+ diff --git a/tests/results/test_namespace/04_5disabled_calculation_boolean.json b/tests/results/test_namespace/04_5disabled_calculation_boolean.json new file mode 100644 index 000000000..eadfdf1fc --- /dev/null +++ b/tests/results/test_namespace/04_5disabled_calculation_boolean.json @@ -0,0 +1,114 @@ +{ + "rougail": { + "type": "namespace", + "informations": { + "paths": [ + "rougail" + ], + "names": [ + "rougail" + ], + "description": "Rougail", + "properties": [ + { + "type": "mode", + "name": "basic" + } + ] + }, + "children": { + "rougail.condition": { + "type": "variable", + "default": { + "name": "Default", + "values": "no" + }, + "properties": [ + { + "type": "type", + "name": "string" + }, + { + "type": "mode", + "name": "standard" + }, + { + "type": "property", + "name": "mandatory" + } + ], + "paths": [ + "rougail.condition" + ], + "names": [ + "condition" + ], + "descriptions": [ + "A conditional variable." + ] + }, + "rougail.variable1": { + "type": "variable", + "properties": [ + { + "type": "type", + "name": "string" + }, + { + "type": "mode", + "name": "basic" + }, + { + "type": "property", + "name": "mandatory" + }, + { + "type": "property", + "name": "disabled", + "annotation": "if condition is egal to \"yes\"." + } + ], + "paths": [ + "rougail.variable1" + ], + "names": [ + "variable1" + ], + "descriptions": [ + "A first variable." + ] + }, + "rougail.variable2": { + "type": "variable", + "properties": [ + { + "type": "type", + "name": "string" + }, + { + "type": "mode", + "name": "basic" + }, + { + "type": "property", + "name": "mandatory" + }, + { + "type": "property", + "name": "disabled", + "annotation": "if condition is not egal to \"yes\"." + } + ], + "paths": [ + "rougail.variable2" + ], + "names": [ + "variable2" + ], + "descriptions": [ + "A seconde variable." + ] + } + } + } +} \ No newline at end of file diff --git a/tests/results/test_namespace/04_5disabled_calculation_boolean.md b/tests/results/test_namespace/04_5disabled_calculation_boolean.md new file mode 100644 index 000000000..b9609a85b --- /dev/null +++ b/tests/results/test_namespace/04_5disabled_calculation_boolean.md @@ -0,0 +1,12 @@ +# Variables for "Rougail" + +**rougail** + +`basic` + +| Variable                                                                                                             | Description                                                                                                          | +|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| **rougail.condition**
[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `standard` `mandatory` | A conditional variable.
**Default**: no | +| **rougail.variable1**
[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `basic` `mandatory` *`disabled`* | A first variable.
**Disabled**: if condition is egal to "yes". | +| **rougail.variable2**
[`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `basic` `mandatory` *`disabled`* | A seconde variable.
**Disabled**: if condition is not egal to "yes". | + diff --git a/tests/results/test_namespace/04_5disabled_calculation_boolean.sh b/tests/results/test_namespace/04_5disabled_calculation_boolean.sh new file mode 100644 index 000000000..388a742ce --- /dev/null +++ b/tests/results/test_namespace/04_5disabled_calculation_boolean.sh @@ -0,0 +1,29 @@ + + +Variables for "Rougail" + + + +rougail + + + + basic  + + + +┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓ +┃ Variable  ┃ Description  ┃ +┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩ +│ rougail.condition │ A conditional variable. │ +│  string   standard   mandatory  │ Default: no │ +├───────────────────────────────────────┼──────────────────────────────────────┤ +│ rougail.variable1 │ A first variable. │ +│  string   basic   mandatory    │ Disabled: if condition is egal to │ +│ disabled  │ "yes". │ +├───────────────────────────────────────┼──────────────────────────────────────┤ +│ rougail.variable2 │ A seconde variable. │ +│  string   basic   mandatory    │ Disabled: if condition is not egal │ +│ disabled  │ to "yes". │ +└───────────────────────────────────────┴──────────────────────────────────────┘ + diff --git a/tests/results/test_namespace/warnings_04_5disabled_calculation_boolean b/tests/results/test_namespace/warnings_04_5disabled_calculation_boolean new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/tests/results/test_namespace/warnings_04_5disabled_calculation_boolean @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/tests/results/test_namespace_examples/04_5disabled_calculation_boolean.md b/tests/results/test_namespace_examples/04_5disabled_calculation_boolean.md new file mode 100644 index 000000000..bda98aca6 --- /dev/null +++ b/tests/results/test_namespace_examples/04_5disabled_calculation_boolean.md @@ -0,0 +1,17 @@ +# Example with mandatory variables not filled in + +```yaml +--- +rougail: + variable1: example + variable2: example +``` +# Example with all variables modifiable + +```yaml +--- +rougail: + condition: no + variable1: example + variable2: example +``` diff --git a/tests/results/test_namespace_examples/warnings_04_5disabled_calculation_boolean b/tests/results/test_namespace_examples/warnings_04_5disabled_calculation_boolean new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/tests/results/test_namespace_examples/warnings_04_5disabled_calculation_boolean @@ -0,0 +1 @@ +[] \ No newline at end of file