From 3a3b711e1c777cd02b2a969ce0496714dcc713b3 Mon Sep 17 00:00:00 2001 From: Emmanuel Garette Date: Thu, 11 Jun 2026 08:34:32 +0200 Subject: [PATCH] feat: leadership => sequence --- src/rougail/output_json/__init__.py | 4 ++-- tests/results/test_namespace/00_0no_variable.json | 4 +--- .../test_namespace/00_0no_variable_default_version.json | 4 +--- .../test_namespace/00_0no_variable_remove_version.json | 4 +--- tests/results/test_namespace/16_6exists_family.json | 4 +--- tests/results/test_namespace/20_0empty_family.json | 4 +--- tests/results/test_namespace/20_1empty_subfamily.json | 4 +--- tests/results/test_namespace/40_0leadership_empty.json | 4 +--- tests/results/test_namespace/60_0family_empty.json | 4 +--- tests/results/test_namespace_read_write/00_0no_variable.json | 4 +--- .../00_0no_variable_default_version.json | 4 +--- .../00_0no_variable_remove_version.json | 4 +--- .../test_namespace_read_write/00_9default_calculation.json | 2 +- .../results/test_namespace_read_write/16_6exists_family.json | 4 +--- tests/results/test_namespace_read_write/20_0empty_family.json | 4 +--- .../test_namespace_read_write/20_1empty_subfamily.json | 4 +--- .../test_namespace_read_write/40_0leadership_empty.json | 4 +--- tests/results/test_namespace_read_write/60_0family_empty.json | 4 +--- tests/results/test_read_write/00_9default_calculation.json | 2 +- 19 files changed, 20 insertions(+), 52 deletions(-) diff --git a/src/rougail/output_json/__init__.py b/src/rougail/output_json/__init__.py index 1c24bcc..ed8b41f 100644 --- a/src/rougail/output_json/__init__.py +++ b/src/rougail/output_json/__init__.py @@ -134,7 +134,7 @@ class RougailOutputJson: if option.isoptiondescription(): if option.isleadership(): parent = [] - self.parse_leadership( + self.parse_sequence( option, parent, ) @@ -149,7 +149,7 @@ class RougailOutputJson: else: child[option.name()] = option.value.get() - def parse_leadership( + def parse_sequence( self, conf, parent, diff --git a/tests/results/test_namespace/00_0no_variable.json b/tests/results/test_namespace/00_0no_variable.json index 91936ef..9e26dfe 100644 --- a/tests/results/test_namespace/00_0no_variable.json +++ b/tests/results/test_namespace/00_0no_variable.json @@ -1,3 +1 @@ -{ - "rougail": {} -} \ No newline at end of file +{} \ No newline at end of file diff --git a/tests/results/test_namespace/00_0no_variable_default_version.json b/tests/results/test_namespace/00_0no_variable_default_version.json index 91936ef..9e26dfe 100644 --- a/tests/results/test_namespace/00_0no_variable_default_version.json +++ b/tests/results/test_namespace/00_0no_variable_default_version.json @@ -1,3 +1 @@ -{ - "rougail": {} -} \ No newline at end of file +{} \ No newline at end of file diff --git a/tests/results/test_namespace/00_0no_variable_remove_version.json b/tests/results/test_namespace/00_0no_variable_remove_version.json index 91936ef..9e26dfe 100644 --- a/tests/results/test_namespace/00_0no_variable_remove_version.json +++ b/tests/results/test_namespace/00_0no_variable_remove_version.json @@ -1,3 +1 @@ -{ - "rougail": {} -} \ No newline at end of file +{} \ No newline at end of file diff --git a/tests/results/test_namespace/16_6exists_family.json b/tests/results/test_namespace/16_6exists_family.json index 91936ef..9e26dfe 100644 --- a/tests/results/test_namespace/16_6exists_family.json +++ b/tests/results/test_namespace/16_6exists_family.json @@ -1,3 +1 @@ -{ - "rougail": {} -} \ No newline at end of file +{} \ No newline at end of file diff --git a/tests/results/test_namespace/20_0empty_family.json b/tests/results/test_namespace/20_0empty_family.json index 91936ef..9e26dfe 100644 --- a/tests/results/test_namespace/20_0empty_family.json +++ b/tests/results/test_namespace/20_0empty_family.json @@ -1,3 +1 @@ -{ - "rougail": {} -} \ No newline at end of file +{} \ No newline at end of file diff --git a/tests/results/test_namespace/20_1empty_subfamily.json b/tests/results/test_namespace/20_1empty_subfamily.json index 91936ef..9e26dfe 100644 --- a/tests/results/test_namespace/20_1empty_subfamily.json +++ b/tests/results/test_namespace/20_1empty_subfamily.json @@ -1,3 +1 @@ -{ - "rougail": {} -} \ No newline at end of file +{} \ No newline at end of file diff --git a/tests/results/test_namespace/40_0leadership_empty.json b/tests/results/test_namespace/40_0leadership_empty.json index 91936ef..9e26dfe 100644 --- a/tests/results/test_namespace/40_0leadership_empty.json +++ b/tests/results/test_namespace/40_0leadership_empty.json @@ -1,3 +1 @@ -{ - "rougail": {} -} \ No newline at end of file +{} \ No newline at end of file diff --git a/tests/results/test_namespace/60_0family_empty.json b/tests/results/test_namespace/60_0family_empty.json index 91936ef..9e26dfe 100644 --- a/tests/results/test_namespace/60_0family_empty.json +++ b/tests/results/test_namespace/60_0family_empty.json @@ -1,3 +1 @@ -{ - "rougail": {} -} \ No newline at end of file +{} \ No newline at end of file diff --git a/tests/results/test_namespace_read_write/00_0no_variable.json b/tests/results/test_namespace_read_write/00_0no_variable.json index 91936ef..9e26dfe 100644 --- a/tests/results/test_namespace_read_write/00_0no_variable.json +++ b/tests/results/test_namespace_read_write/00_0no_variable.json @@ -1,3 +1 @@ -{ - "rougail": {} -} \ No newline at end of file +{} \ No newline at end of file diff --git a/tests/results/test_namespace_read_write/00_0no_variable_default_version.json b/tests/results/test_namespace_read_write/00_0no_variable_default_version.json index 91936ef..9e26dfe 100644 --- a/tests/results/test_namespace_read_write/00_0no_variable_default_version.json +++ b/tests/results/test_namespace_read_write/00_0no_variable_default_version.json @@ -1,3 +1 @@ -{ - "rougail": {} -} \ No newline at end of file +{} \ No newline at end of file diff --git a/tests/results/test_namespace_read_write/00_0no_variable_remove_version.json b/tests/results/test_namespace_read_write/00_0no_variable_remove_version.json index 91936ef..9e26dfe 100644 --- a/tests/results/test_namespace_read_write/00_0no_variable_remove_version.json +++ b/tests/results/test_namespace_read_write/00_0no_variable_remove_version.json @@ -1,3 +1 @@ -{ - "rougail": {} -} \ No newline at end of file +{} \ No newline at end of file diff --git a/tests/results/test_namespace_read_write/00_9default_calculation.json b/tests/results/test_namespace_read_write/00_9default_calculation.json index 91922ed..8ff7427 100644 --- a/tests/results/test_namespace_read_write/00_9default_calculation.json +++ b/tests/results/test_namespace_read_write/00_9default_calculation.json @@ -1,5 +1,5 @@ { "rougail": { - "variable": "string_1_True_" + "variable": "string_1_True_None" } } \ No newline at end of file diff --git a/tests/results/test_namespace_read_write/16_6exists_family.json b/tests/results/test_namespace_read_write/16_6exists_family.json index 91936ef..9e26dfe 100644 --- a/tests/results/test_namespace_read_write/16_6exists_family.json +++ b/tests/results/test_namespace_read_write/16_6exists_family.json @@ -1,3 +1 @@ -{ - "rougail": {} -} \ No newline at end of file +{} \ No newline at end of file diff --git a/tests/results/test_namespace_read_write/20_0empty_family.json b/tests/results/test_namespace_read_write/20_0empty_family.json index 91936ef..9e26dfe 100644 --- a/tests/results/test_namespace_read_write/20_0empty_family.json +++ b/tests/results/test_namespace_read_write/20_0empty_family.json @@ -1,3 +1 @@ -{ - "rougail": {} -} \ No newline at end of file +{} \ No newline at end of file diff --git a/tests/results/test_namespace_read_write/20_1empty_subfamily.json b/tests/results/test_namespace_read_write/20_1empty_subfamily.json index 91936ef..9e26dfe 100644 --- a/tests/results/test_namespace_read_write/20_1empty_subfamily.json +++ b/tests/results/test_namespace_read_write/20_1empty_subfamily.json @@ -1,3 +1 @@ -{ - "rougail": {} -} \ No newline at end of file +{} \ No newline at end of file diff --git a/tests/results/test_namespace_read_write/40_0leadership_empty.json b/tests/results/test_namespace_read_write/40_0leadership_empty.json index 91936ef..9e26dfe 100644 --- a/tests/results/test_namespace_read_write/40_0leadership_empty.json +++ b/tests/results/test_namespace_read_write/40_0leadership_empty.json @@ -1,3 +1 @@ -{ - "rougail": {} -} \ No newline at end of file +{} \ No newline at end of file diff --git a/tests/results/test_namespace_read_write/60_0family_empty.json b/tests/results/test_namespace_read_write/60_0family_empty.json index 91936ef..9e26dfe 100644 --- a/tests/results/test_namespace_read_write/60_0family_empty.json +++ b/tests/results/test_namespace_read_write/60_0family_empty.json @@ -1,3 +1 @@ -{ - "rougail": {} -} \ No newline at end of file +{} \ No newline at end of file diff --git a/tests/results/test_read_write/00_9default_calculation.json b/tests/results/test_read_write/00_9default_calculation.json index 728f089..0d290a8 100644 --- a/tests/results/test_read_write/00_9default_calculation.json +++ b/tests/results/test_read_write/00_9default_calculation.json @@ -1,3 +1,3 @@ { - "variable": "string_1_True_" + "variable": "string_1_True_None" } \ No newline at end of file