diff --git a/README.fr.md b/README.fr.md index 4b0b038b4..590f68ef0 100644 --- a/README.fr.md +++ b/README.fr.md @@ -4,22 +4,22 @@ include_toc: true --- [🇬🇧 (EN)](README.md) - [🇫🇷 (FR)](README.fr.md) -| Variable | Description | Valeur par défaut | Type | Contrôle des accès | Validateur | -|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------|----------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| **default_structural_format_version**
**Ligne de commande** :
-v, --default_structural_format_version
**Variable d'environnement** : DEFAULT_STRUCTURAL_FORMAT_VERSION | Version par défaut du format des fichiers de structure.
Cette valeur n'est utilisée que si la version n'est pas définie dans le fichier de structure. | | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | **Choix** :
• 1.0
• 1.1
• null | -| **types**
**Ligne de commande** :
--types
**Variable d'environnement** : TYPES | Fichier avec types personnalisés.
Ce fichier contient des types personnalisés au format Rougail pour les fichiers de structure. | | [`UNIX filename`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique`
• le nom de fichier peut ĂŞtre une chemin relatif
• le fichier doit exister
• type de fichier autorisĂ©: "fichier" et "rĂ©pertoire". | -| **functions_files**
**Ligne de commande** :
--functions_files
**Variable d'environnement** : FUNCTIONS_FILES | Fichier avec les fonctions.
Ce fichier contient des filtres et des fonctions Jinja2 supplémentaires utilisables dans les fichiers de structure. | | [`UNIX filename`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique`
• le nom de fichier peut ĂŞtre une chemin relatif
• le fichier doit exister
• type de fichier autorisĂ©: "file". | -| **modes_level**
**Ligne de commande** :
--modes_level
**Variable d'environnement** : MODES_LEVEL | Tous les niveaux de modes valides. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique` | -| **default_family_mode**
**Variable d'environnement** : DEFAULT_FAMILY_MODE | Mode par défaut pour une famille. | le premier défini dans "[Tous les niveaux de modes valides](#modes_level)" | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | Ce mode doit être disponible dans "[Tous les niveaux de modes valides](#modes_level)". | -| **default_variable_mode**
**Variable d'environnement** : DEFAULT_VARIABLE_MODE | Mode par défaut pour une variable. | si la variable "[Tous les niveaux de modes valides](#modes_level)" est définit, la valeur par défaut est le second élément disponible, sinon, le premier | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | Ce mode doit être disponible dans "[Tous les niveaux de modes valides](#modes_level)". | -| **base_option_name**
**Variable d'environnement** : BASE_OPTION_NAME | Nom de l'option pour l'option de base. | baseoption | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | | -| **export_with_import**
**Variable d'environnement** : EXPORT_WITH_IMPORT | Dans le fichier de cache, ne pas importer Tiramisu et autres dépendances. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | | -| **tiramisu_cache**
**Ligne de commande** :
-t, --tiramisu_cache
**Variable d'environnement** : TIRAMISU_CACHE | Enregistrer le cache Tiramisu dans le fichier.
Ce fichier contient les instructions Tiramisu utilisé en interne pour charger les variables.
Ce fichier peut ĂŞtre utilisĂ© pour le dĂ©bogage. | | [`UNIX filename`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | • le nom de fichier peut ĂŞtre une chemin relatif
• type de fichier autorisĂ©: "file". | -| **internal_functions**
**Variable d'environnement** : INTERNAL_FUNCTIONS | Nom des fonctions internes qu'il est possible d'utiliser comme fonction. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | | -| **extra_annotators**
**Variable d'environnement** : EXTRA_ANNOTATORS | Nom des annotators supplémentaires. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | | -| **suffix**
**Variable d'environnement** : SUFFIX | Suffix ajouté pour généré le nom des options. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | | -| **force_optional**
**Ligne de commande** :
• --force_optional
• --no-force_optional
**Variable d'environnement** : FORCE_OPTIONAL | Toutes les variables dans un calcul sont optionnelles. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | `standard` | | -| **load_unexist_redefine**
**Variable d'environnement** : LOAD_UNEXIST_REDEFINE | Charger les variables redéfinis même si elles n'existe pas. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | | +| Variable | Description | Valeur par défaut | Type | Contrôle des accès | Validateur | +|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| **default_structural_format_version**
**Ligne de commande** :
-v, --default_structural_format_version
**Variable d'environnement** : DEFAULT_STRUCTURAL_FORMAT_VERSION | Version par défaut du format des fichiers de structure.
Cette valeur n'est utilisée que si la version n'est pas définie dans le fichier de structure. | | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | **Choix** :
• 1.0
• 1.1
• null | +| **types**
**Ligne de commande** :
--types
**Variable d'environnement** : TYPES | Fichier avec types personnalisés.
Ce fichier contient des types personnalisés au format Rougail pour les fichiers de structure. | | [`UNIX filename`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique`
• le nom de fichier peut ĂŞtre une chemin relatif
• le fichier doit exister
• type de fichier autorisĂ©: "directory" et "file". | +| **functions_files**
**Ligne de commande** :
--functions_files
**Variable d'environnement** : FUNCTIONS_FILES | Fichier avec les fonctions.
Ce fichier contient des filtres et des fonctions Jinja2 supplémentaires utilisables dans les fichiers de structure. | | [`UNIX filename`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique`
• le nom de fichier peut ĂŞtre une chemin relatif
• le fichier doit exister
• type de fichier autorisĂ©: "file". | +| **modes_level**
**Ligne de commande** :
--modes_level
**Variable d'environnement** : MODES_LEVEL | Tous les niveaux de modes valides. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique` | +| **default_family_mode**
**Variable d'environnement** : DEFAULT_FAMILY_MODE | Mode par défaut pour une famille. | le premier défini dans "[Tous les niveaux de modes valides](#modes_level)". | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | `standard` *`désactivé`*
**Désactivé** : si aucun mode n'est défini dans "[Tous les niveaux de modes valides](#modes_level)". | Ce mode doit être disponible dans "[Tous les niveaux de modes valides](#modes_level)". | +| **default_variable_mode**
**Variable d'environnement** : DEFAULT_VARIABLE_MODE | Mode par défaut pour une variable. | si la variable "[Tous les niveaux de modes valides](#modes_level)" est définit, la valeur par défaut est le second élément disponible, sinon, le premier. | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | `standard` *`désactivé`*
**Désactivé** : si aucun mode n'est défini dans "[Tous les niveaux de modes valides](#modes_level)". | Ce mode doit être disponible dans "[Tous les niveaux de modes valides](#modes_level)". | +| **base_option_name**
**Variable d'environnement** : BASE_OPTION_NAME | Nom de l'option pour l'option de base. | baseoption | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | `standard` | | +| **export_with_import**
**Variable d'environnement** : EXPORT_WITH_IMPORT | Dans le fichier de cache, ne pas importer Tiramisu et autres dépendances. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | `standard` | | +| **tiramisu_cache**
**Variable d'environnement** : TIRAMISU_CACHE | Enregistrer le cache Tiramisu dans le fichier.
Ce fichier contient les instructions Tiramisu utilisé en interne pour charger les variables.
Ce fichier peut ĂŞtre utilisĂ© pour le dĂ©bogage. | | [`UNIX filename`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | • le nom de fichier peut ĂŞtre une chemin relatif
• type de fichier autorisĂ©: "file". | +| **internal_functions**
**Variable d'environnement** : INTERNAL_FUNCTIONS | Nom des fonctions internes qu'il est possible d'utiliser comme fonction. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique` | +| **extra_annotators**
**Variable d'environnement** : EXTRA_ANNOTATORS | Nom des annotators supplémentaires. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique` | +| **suffix**
**Variable d'environnement** : SUFFIX | Suffix ajouté pour généré le nom des options. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | | +| **force_optional**
**Ligne de commande** :
• --force_optional
• --no-force_optional
**Variable d'environnement** : FORCE_OPTIONAL | Toutes les variables dans un calcul sont optionnelles. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | `standard` | | +| **load_unexist_redefine**
**Variable d'environnement** : LOAD_UNEXIST_REDEFINE | Charger les variables redéfinis même si elles n'existe pas. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | `standard` | | ## Le gestionnaire de secret @@ -39,11 +39,11 @@ include_toc: true > **Chemin** : step\ > `standard` -| Variable | Description | Valeur par défaut | Type | Contrôle des accès | Validateur | -|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------|---------------------|--------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| **step.structural**
**Variable d'environnement** : STEP.STRUCTURAL | SĂ©lection pour structure. | • directory | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | **Choix** :
• directory
• string
• commandline
• risotto | -| **step.user_data**
**Ligne de commande** :
-u, --step.user_data
**Variable d'environnement** : STEP.USER_DATA | Sélection pour données utilisateur. | | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` *`désactivé`*
**Désactivé** : les sorties "doc" n'autorisent pas des données utilisateur | `unique`
**Choix** :
• yaml
• environment
• commandline
• ansible
• questionary
• risotto
• bitwarden | -| **step.output**
**Ligne de commande** :
-o, --step.output
**Variable d'environnement** : STEP.OUTPUT | Sélection pour sortie. | display | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | `standard` | **Choix** :
• display
• json
• doc
• table
• ansible | +| Variable | Description | Valeur par dĂ©faut | Type | ContrĂ´le des accès | Validateur | +|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------|---------------------|-------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| **step.structural**
**Variable d'environnement** : STEP.STRUCTURAL | SĂ©lection pour structure. | • directory | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` `obligatoire` | `standard` | `unique`
**Choix** :
• directory
• string
• commandline
• risotto | +| **step.user_data**
**Ligne de commande** :
-u, --step.user_data
**Variable d'environnement** : STEP.USER_DATA | Sélection pour données utilisateur. | | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` *`désactivé`*
**Désactivé** : les sorties "doc" n'autorisent pas des données utilisateur. | `unique`
**Choix** :
• yaml
• environment
• commandline
• ansible
• questionary
• risotto
• bitwarden | +| **step.output**
**Ligne de commande** :
-o, --step.output
**Variable d'environnement** : STEP.OUTPUT | Sélection pour sortie. | display | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `obligatoire` | `standard` | **Choix** :
• display
• json
• doc
• table
• ansible | | Variable | Description | Valeur par dĂ©faut | Type | ContrĂ´le des accès | |---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------|---------------------|---------------------------------------------------------------------------------------------------|----------------------| @@ -55,7 +55,7 @@ include_toc: true > > **Chemin** : default_params\ > `standard` *`dĂ©sactivĂ©`*\ -> **DĂ©sactivĂ©** : lorsque la variable "[Sur charger les paramètre par dĂ©faut pour le type d'option](#define_default_params)" a la valeur "false" +> **DĂ©sactivĂ©** : when the variable "[Sur charger les paramètre par dĂ©faut pour le type d'option](#define_default_params)" a la valeur "false". ### UNIX filename @@ -207,5 +207,3 @@ include_toc: true | **default_params.port.allow_wellknown**
**Ligne de commande** :
• --default_params.port.allow_wellknown
• --default_params.port.no-allow_wellknown
**Variable d'environnement** : DEFAULT_PARAMS.PORT.ALLOW_WELLKNOWN | Les ports connus (1 à 1023) sont autorisés. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | | **default_params.port.allow_registred**
**Ligne de commande** :
• --default_params.port.allow_registred
• --default_params.port.no-allow_registred
**Variable d'environnement** : DEFAULT_PARAMS.PORT.ALLOW_REGISTRED | Les ports enregistrés (1024 à 49151) sont autorisés. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | | **default_params.port.allow_private**
**Ligne de commande** :
• --default_params.port.allow_private
• --default_params.port.no-allow_private
**Variable d'environnement** : DEFAULT_PARAMS.PORT.ALLOW_PRIVATE | Les ports privés (supérieur à 49152) sont autorisés. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | - - diff --git a/README.md b/README.md index a301012ec..c1f2b1511 100644 --- a/README.md +++ b/README.md @@ -4,22 +4,22 @@ include_toc: true --- [🇬🇧 (EN)](README.md) - [🇫🇷 (FR)](README.fr.md) -| Variable | Description | Default value | Type | Access control | Validator | -|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------|------------------|--------------------------------------------------------------------------------------------------------------------------------------------------| -| **default_structural_format_version**
**Command line**:
-v, --default_structural_format_version
**Environment variable**: DEFAULT_STRUCTURAL_FORMAT_VERSION | Default version of the structural file format.
This value is only used if the version is not set in the structural file. | | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | **Choices**:
• 1.0
• 1.1
• null | -| **types**
**Command line**:
--types
**Environment variable**: TYPES | File with personalize types.
This file contains personalize types in Rougail format for structure files. | | [`UNIX filename`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique`
• this filename could be a relative path
• this file must exist
• file type allowed: "directory" and "file". | -| **functions_files**
**Command line**:
--functions_files
**Environment variable**: FUNCTIONS_FILES | File with functions.
This file contains filters and additional Jinja2 functions usable in structure files. | | [`UNIX filename`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique`
• this filename could be a relative path
• this file must exist
• file type allowed: "file". | -| **modes_level**
**Command line**:
--modes_level
**Environment variable**: MODES_LEVEL | All modes level available. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique` | -| **default_family_mode**
**Environment variable**: DEFAULT_FAMILY_MODE | Default mode for a family. | the first one defined in "[All modes level available](#modes_level)" | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | This mode must be available in "[All modes level available](#modes_level)". | -| **default_variable_mode**
**Environment variable**: DEFAULT_VARIABLE_MODE | Default mode for a variable. | if the variable "[All modes level available](#modes_level)" is defined, the default value is the second available element, otherwise, the first | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | This mode must be available in "[All modes level available](#modes_level)". | -| **base_option_name**
**Environment variable**: BASE_OPTION_NAME | Option name for the base option. | baseoption | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | | -| **export_with_import**
**Environment variable**: EXPORT_WITH_IMPORT | In cache file, do not importation of Tiramisu and other dependencies. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | | -| **tiramisu_cache**
**Command line**:
-t, --tiramisu_cache
**Environment variable**: TIRAMISU_CACHE | Store Tiramisu cache filename.
This file contains the Tiramisu instructions used internally to load the variables.
This file can be used for debugging. | | [`UNIX filename`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | • this filename could be a relative path
• file type allowed: "file". | -| **internal_functions**
**Environment variable**: INTERNAL_FUNCTIONS | Name of internal functions that we can use as a function. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | | -| **extra_annotators**
**Environment variable**: EXTRA_ANNOTATORS | Name of extra annotators. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | | -| **suffix**
**Environment variable**: SUFFIX | Suffix add to generated options name. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | | -| **force_optional**
**Command line**:
• --force_optional
• --no-force_optional
**Environment variable**: FORCE_OPTIONAL | Every variables in calculation are optionals. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | `standard` | | -| **load_unexist_redefine**
**Environment variable**: LOAD_UNEXIST_REDEFINE | Loads redefine variables even if there don't already exists. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | | +| Variable | Description | Default value | Type | Access control | Validator | +|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------| +| **default_structural_format_version**
**Command line**:
-v, --default_structural_format_version
**Environment variable**: DEFAULT_STRUCTURAL_FORMAT_VERSION | Default version of the structural file format.
This value is only used if the version is not set in the structural file. | | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | **Choices**:
• 1.0
• 1.1
• null | +| **types**
**Command line**:
--types
**Environment variable**: TYPES | File with personalize types.
This file contains personalize types in Rougail format for structure files. | | [`UNIX filename`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique`
• this filename could be a relative path
• this file must exist
• file type allowed: "directory" and "file". | +| **functions_files**
**Command line**:
--functions_files
**Environment variable**: FUNCTIONS_FILES | File with functions.
This file contains filters and additional Jinja2 functions usable in structure files. | | [`UNIX filename`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique`
• this filename could be a relative path
• this file must exist
• file type allowed: "file". | +| **modes_level**
**Command line**:
--modes_level
**Environment variable**: MODES_LEVEL | All modes level available. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique` | +| **default_family_mode**
**Environment variable**: DEFAULT_FAMILY_MODE | Default mode for a family. | the first one defined in "[All modes level available](#modes_level)". | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | `standard` *`disabled`*
**Disabled**: when no mode is defined in "[All modes level available](#modes_level)". | This mode must be available in "[All modes level available](#modes_level)". | +| **default_variable_mode**
**Environment variable**: DEFAULT_VARIABLE_MODE | Default mode for a variable. | if the variable "[All modes level available](#modes_level)" is defined, the default value is the second available element, otherwise, the first. | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | `standard` *`disabled`*
**Disabled**: when no mode is defined in "[All modes level available](#modes_level)". | This mode must be available in "[All modes level available](#modes_level)". | +| **base_option_name**
**Environment variable**: BASE_OPTION_NAME | Option name for the base option. | baseoption | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | `standard` | | +| **export_with_import**
**Environment variable**: EXPORT_WITH_IMPORT | In cache file, do not importation of Tiramisu and other dependencies. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | `standard` | | +| **tiramisu_cache**
**Environment variable**: TIRAMISU_CACHE | Store Tiramisu cache filename.
This file contains the Tiramisu instructions used internally to load the variables.
This file can be used for debugging. | | [`UNIX filename`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | • this filename could be a relative path
• file type allowed: "file". | +| **internal_functions**
**Environment variable**: INTERNAL_FUNCTIONS | Name of internal functions that we can use as a function. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique` | +| **extra_annotators**
**Environment variable**: EXTRA_ANNOTATORS | Name of extra annotators. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | `unique` | +| **suffix**
**Environment variable**: SUFFIX | Suffix add to generated options name. | | [`string`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | | +| **force_optional**
**Command line**:
• --force_optional
• --no-force_optional
**Environment variable**: FORCE_OPTIONAL | Every variables in calculation are optionals. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | `standard` | | +| **load_unexist_redefine**
**Environment variable**: LOAD_UNEXIST_REDEFINE | Loads redefine variables even if there don't already exists. | false | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | `standard` | | ## The secret manager @@ -39,11 +39,11 @@ include_toc: true > **Path**: step\ > `standard` -| Variable | Description | Default value | Type | Access control | Validator | -|------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------|------------------|------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| **step.structural**
**Environment variable**: STEP.STRUCTURAL | Select for structural. | • directory | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` | **Choices**:
• directory
• string
• commandline
• risotto | -| **step.user_data**
**Command line**:
-u, --step.user_data
**Environment variable**: STEP.USER_DATA | Select for user datas. | | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` *`disabled`*
**Disabled**: outputs "doc" did not allow user data | `unique`
**Choices**:
• yaml
• environment
• commandline
• ansible
• questionary
• risotto
• bitwarden | -| **step.output**
**Command line**:
-o, --step.output
**Environment variable**: STEP.OUTPUT | Select for output. | display | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | `standard` | **Choices**:
• display
• json
• doc
• table
• ansible | +| Variable | Description | Default value | Type | Access control | Validator | +|------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------|------------------|-----------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| **step.structural**
**Environment variable**: STEP.STRUCTURAL | Select for structural. | • directory | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` `mandatory` | `standard` | `unique`
**Choices**:
• directory
• string
• commandline
• risotto | +| **step.user_data**
**Command line**:
-u, --step.user_data
**Environment variable**: STEP.USER_DATA | Select for user datas. | | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `multiple` | `standard` *`disabled`*
**Disabled**: outputs "doc" did not allow user data. | `unique`
**Choices**:
• yaml
• environment
• commandline
• ansible
• questionary
• risotto
• bitwarden | +| **step.output**
**Command line**:
-o, --step.output
**Environment variable**: STEP.OUTPUT | Select for output. | display | [`choice`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) `mandatory` | `standard` | **Choices**:
• display
• json
• doc
• table
• ansible | | Variable | Description | Default value | Type | Access control | |----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------|-----------------|-------------------------------------------------------------------------------------------------|------------------| @@ -55,7 +55,7 @@ include_toc: true > > **Path**: default_params\ > `standard` *`disabled`*\ -> **Disabled**: when the variable "[Override default parameters for option type](#define_default_params)" has the value "false" +> **Disabled**: when the variable "[Override default parameters for option type](#define_default_params)" has the value "false". ### UNIX filename @@ -207,5 +207,3 @@ include_toc: true | **default_params.port.allow_wellknown**
**Command line**:
• --default_params.port.allow_wellknown
• --default_params.port.no-allow_wellknown
**Environment variable**: DEFAULT_PARAMS.PORT.ALLOW_WELLKNOWN | Well-known ports (1 to 1023) are allowed. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | | **default_params.port.allow_registred**
**Command line**:
• --default_params.port.allow_registred
• --default_params.port.no-allow_registred
**Environment variable**: DEFAULT_PARAMS.PORT.ALLOW_REGISTRED | Registred ports (1024 to 49151) are allowed. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | | **default_params.port.allow_private**
**Command line**:
• --default_params.port.allow_private
• --default_params.port.no-allow_private
**Environment variable**: DEFAULT_PARAMS.PORT.ALLOW_PRIVATE | Private ports (greater than 49152) are allowed. | true | [`boolean`](https://rougail.readthedocs.io/en/latest/variable.html#variables-types) | `standard` | - - diff --git a/locale/fr/LC_MESSAGES/rougail.po b/locale/fr/LC_MESSAGES/rougail.po index 8f5887f3d..ce9b84c0a 100644 --- a/locale/fr/LC_MESSAGES/rougail.po +++ b/locale/fr/LC_MESSAGES/rougail.po @@ -5,8 +5,8 @@ msgid "" msgstr "" "Project-Id-Version: \n" -"POT-Creation-Date: 2026-01-21 08:37+0100\n" -"PO-Revision-Date: 2026-01-21 08:42+0100\n" +"POT-Creation-Date: 2026-04-29 21:06+0200\n" +"PO-Revision-Date: 2026-04-29 21:11+0200\n" "Last-Translator: \n" "Language-Team: \n" "Language: fr\n" @@ -14,7 +14,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Generated-By: pygettext.py 1.5\n" -"X-Generator: Poedit 3.8\n" +"X-Generator: Poedit 3.9\n" #: src/rougail/annotator/family.py:152 msgid "default variable mode \"{0}\" is not a valid mode, valid modes are {1}" @@ -72,7 +72,7 @@ msgstr "" "la variable \"{0}\" est dans le mode \"{1}\" mais la famille a le mode " "supérieur \"{2}\"" -#: src/rougail/annotator/property.py:181 +#: src/rougail/annotator/property.py:182 msgid "" "invalid tag name \"{0}\" should only contains lowercase ascii character, " "number or _" @@ -80,12 +80,12 @@ msgstr "" "nom de l'étiquette invalide \"{0}\" doit seulement contenir des caractères " "ascii minuscule, nombre or _" -#: src/rougail/annotator/property.py:186 +#: src/rougail/annotator/property.py:187 msgid "invalid tag name \"{0}\" should not be a name of an existing mode" msgstr "" "nom de l'étiquette invalide \"{0}\" ne doit pas être un nom de mode existant" -#: src/rougail/annotator/property.py:191 +#: src/rougail/annotator/property.py:192 msgid "" "invalid tag name \"{0}\" should not be the name of an available properties" msgstr "" @@ -167,51 +167,51 @@ msgstr "nécessite au minimum {0} valeurs" msgid "the \"{0}\" default value is a calculation with itself" msgstr "la valeur par défaut \"{0}\" est un calcul avec elle-même" -#: src/rougail/annotator/variable.py:306 +#: src/rougail/annotator/variable.py:310 msgid "" "the variable \"{0}\" has regexp attribut but has not the \"regexp\" type" msgstr "" "la variable \"{0}\" a un attribut regexp mais n'a pas le type \"regexp\"" -#: src/rougail/annotator/variable.py:349 +#: src/rougail/annotator/variable.py:353 msgid "" "the variable \"{0}\" has choices attribut but has not the \"choice\" type" msgstr "" "la variable \"{0}\" a un attribut choices mais n'a pas le type \"choice\"" -#: src/rougail/annotator/variable.py:377 +#: src/rougail/annotator/variable.py:381 msgid "" "the variable \"{0}\" has an unvalid default value \"{1}\" should be in {2}" msgstr "" "la variable \"{0}\" a la valeur par défaut invalide \"{1}\" devrait être {2}" -#: src/rougail/config/__init__.py:272 +#: src/rougail/config/__init__.py:283 msgid "Default version of the structural file format" msgstr "Version par défaut du format des fichiers de structure" -#: src/rougail/config/__init__.py:273 +#: src/rougail/config/__init__.py:284 msgid "" "This value is only used if the version is not set in the structural file" msgstr "" "Cette valeur n'est utilisée que si la version n'est pas définie dans le " "fichier de structure" -#: src/rougail/config/__init__.py:281 +#: src/rougail/config/__init__.py:292 msgid "File with personalize types" msgstr "Fichier avec types personnalisés" -#: src/rougail/config/__init__.py:282 +#: src/rougail/config/__init__.py:293 msgid "" "This file contains personalize types in Rougail format for structure files" msgstr "" "Ce fichier contient des types personnalisés au format Rougail pour les " "fichiers de structure" -#: src/rougail/config/__init__.py:291 +#: src/rougail/config/__init__.py:302 msgid "File with functions" msgstr "Fichier avec les fonctions" -#: src/rougail/config/__init__.py:292 +#: src/rougail/config/__init__.py:303 msgid "" "This file contains filters and additional Jinja2 functions usable in " "structure files" @@ -219,31 +219,31 @@ msgstr "" "Ce fichier contient des filtres et des fonctions Jinja2 supplémentaires " "utilisables dans les fichiers de structure" -#: src/rougail/config/__init__.py:303 +#: src/rougail/config/__init__.py:314 msgid "All modes level available" msgstr "Tous les niveaux de modes valides" -#: src/rougail/config/__init__.py:315 +#: src/rougail/config/__init__.py:326 msgid "Default mode for a family" msgstr "Mode par défaut pour une famille" -#: src/rougail/config/__init__.py:321 +#: src/rougail/config/__init__.py:332 msgid "the first one defined in \"modes_level\"" msgstr "le premier défini dans \"modes_level\"" -#: src/rougail/config/__init__.py:327 src/rougail/config/__init__.py:354 +#: src/rougail/config/__init__.py:338 src/rougail/config/__init__.py:365 msgid "when no mode is defined in \"modes_level\"" msgstr "si aucun mode n'est défini dans \"modes_level\"" -#: src/rougail/config/__init__.py:334 src/rougail/config/__init__.py:361 +#: src/rougail/config/__init__.py:345 src/rougail/config/__init__.py:372 msgid "this mode must be available in \"modes_level\"" msgstr "ce mode doit être disponible dans \"modes_level\"" -#: src/rougail/config/__init__.py:338 +#: src/rougail/config/__init__.py:349 msgid "Default mode for a variable" msgstr "Mode par défaut pour une variable" -#: src/rougail/config/__init__.py:348 +#: src/rougail/config/__init__.py:359 msgid "" "if the variable \"modes_level\" is defined, the default value is the second " "available element, otherwise, the first" @@ -251,20 +251,20 @@ msgstr "" "si la variable \"modes_level\" est définit, la valeur par défaut est le " "second élément disponible, sinon, le premier" -#: src/rougail/config/__init__.py:365 +#: src/rougail/config/__init__.py:376 msgid "Option name for the base option" msgstr "Nom de l'option pour l'option de base" -#: src/rougail/config/__init__.py:370 +#: src/rougail/config/__init__.py:381 msgid "In cache file, do not importation of Tiramisu and other dependencies" msgstr "" "Dans le fichier de cache, ne pas importer Tiramisu et autres dépendances" -#: src/rougail/config/__init__.py:375 +#: src/rougail/config/__init__.py:386 msgid "Store Tiramisu cache filename" msgstr "Enregistrer le cache Tiramisu dans le fichier" -#: src/rougail/config/__init__.py:376 +#: src/rougail/config/__init__.py:387 msgid "" "This file contains the Tiramisu instructions used internally to load the " "variables.\n" @@ -276,32 +276,32 @@ msgstr "" "\n" "Ce fichier peut être utilisé pour le débogage" -#: src/rougail/config/__init__.py:386 +#: src/rougail/config/__init__.py:398 msgid "Name of internal functions that we can use as a function" msgstr "" "Nom des fonctions internes qu'il est possible d'utiliser comme fonction" -#: src/rougail/config/__init__.py:392 +#: src/rougail/config/__init__.py:404 msgid "Name of extra annotators" msgstr "Nom des annotators supplémentaires" -#: src/rougail/config/__init__.py:398 +#: src/rougail/config/__init__.py:410 msgid "Suffix add to generated options name" msgstr "Suffix ajouté pour généré le nom des options" -#: src/rougail/config/__init__.py:404 +#: src/rougail/config/__init__.py:416 msgid "Every variables in calculation are optionals" msgstr "Toutes les variables dans un calcul sont optionnelles" -#: src/rougail/config/__init__.py:408 +#: src/rougail/config/__init__.py:420 msgid "Loads redefine variables even if there don't already exists" msgstr "Charger les variables redéfinis même si elles n'existe pas" -#: src/rougail/config/__init__.py:412 +#: src/rougail/config/__init__.py:424 msgid "The secret manager" msgstr "Le gestionnaire de secret" -#: src/rougail/config/__init__.py:415 +#: src/rougail/config/__init__.py:427 msgid "" "The secret pattern to constructing the name of the item searched for in the " "secret manager" @@ -309,67 +309,71 @@ msgstr "" "Le modèle de secret permettant de construire le nom de l'élément recherché " "dans le gestionnaire de secrets" -#: src/rougail/config/__init__.py:416 +#: src/rougail/config/__init__.py:428 msgid "The pattern is in Jinja2 format" msgstr "Le modèle est au format Jinja2" -#: src/rougail/config/__init__.py:425 +#: src/rougail/config/__init__.py:437 msgid "structural" msgstr "structure" -#: src/rougail/config/__init__.py:426 +#: src/rougail/config/__init__.py:438 msgid "user datas" msgstr "données utilisateur" -#: src/rougail/config/__init__.py:427 +#: src/rougail/config/__init__.py:439 msgid "output" msgstr "sortie" -#: src/rougail/config/__init__.py:448 -msgid "Select for {0}" -msgstr "Sélection pour {0}" +#: src/rougail/config/__init__.py:460 +msgid "select for {0}" +msgstr "sélection pour {0}" -#: src/rougail/config/__init__.py:486 +#: src/rougail/config/__init__.py:498 msgid "outputs {0} did not allow user data" msgstr "les sorties {0} n'autorisent pas des données utilisateur" -#: src/rougail/config/__init__.py:512 +#: src/rougail/config/__init__.py:524 msgid "Override default parameters for option type" msgstr "Sur charger les paramètre par défaut pour le type d'option" -#: src/rougail/config/__init__.py:515 +#: src/rougail/config/__init__.py:527 msgid "Default parameters for option type" msgstr "Paramètre par défaut pour le type d'option" -#: src/rougail/convert/convert.py:281 -msgid "unknown type {0} for {1}" -msgstr "type {0} inconnu pour {1}" +#: src/rougail/convert/convert.py:282 +msgid "unknown type \"{0}\" for \"{1}\"" +msgstr "type \"{0}\" inconnu pour \"{1}\"" -#: src/rougail/convert/convert.py:444 +#: src/rougail/convert/convert.py:441 msgid "family \"{0}\" define multiple time" msgstr "la famille \"{0}\" est définit plusieurs fois" -#: src/rougail/convert/convert.py:715 +#: src/rougail/convert/convert.py:739 msgid "variable \"{0}\" define multiple time" msgstr "la variable \"{0}\" est définit plusieurs fois" -#: src/rougail/convert/convert.py:808 src/rougail/convert/convert.py:815 +#: src/rougail/convert/convert.py:796 +msgid "the {0} \"{1}\" has an invalid \"{2}\": {3}" +msgstr "l\" {0} \"{1}\" a un invalide \"{2}\" : {3}" + +#: src/rougail/convert/convert.py:836 src/rougail/convert/convert.py:843 msgid "params must be a dict for {0}" msgstr "params doit être une dict pour {0}" -#: src/rougail/convert/convert.py:836 +#: src/rougail/convert/convert.py:864 msgid "\"{0}\" has an invalid \"params\" for {1}: {2}" msgstr "\"{0}\" a un attribut \"params\" invalide pour {1}: {2}" -#: src/rougail/convert/convert.py:850 +#: src/rougail/convert/convert.py:881 msgid "secret_manager must be a dict for {0}" msgstr "secret_manager doit être une dict pour {0}" -#: src/rougail/convert/convert.py:1190 +#: src/rougail/convert/convert.py:1257 msgid "Cannot execute annotate multiple time" msgstr "Ne peut exécuter l'annotation plusieurs fois" -#: src/rougail/convert/convert.py:1197 +#: src/rougail/convert/convert.py:1264 msgid "" "invalid \"structural\" definition ({0}), we cannot load any structural file!" msgstr "" @@ -390,7 +394,7 @@ msgstr "" "\"{2}\"" #: src/rougail/convert/object_model.py:143 -#: src/rougail/convert/object_model.py:528 +#: src/rougail/convert/object_model.py:530 msgid "unknown object \"{0}\" in attribute \"{1}\" for \"{2}\"" msgstr "objet inconnu \"{0}\" dans l'attribut \"{1}\" pour \"{2}\"" @@ -419,7 +423,7 @@ msgstr "" "la variable \"{0}\" n'est pas suiveuse, donc ne peut avoir de type index " "comme paramètre dans \"{1}\"" -#: src/rougail/convert/object_model.py:263 +#: src/rougail/convert/object_model.py:264 msgid "" "\"warnings\" are only available with attribute \"{self.attribute_name}\" for " "variable \"{self.path}\"" @@ -427,7 +431,7 @@ msgstr "" "\"warnings\" est seulement utilisable avec l'attribut \"{self.attribute_name}" "\" pour la variable \"{self.path}\"" -#: src/rougail/convert/object_model.py:325 +#: src/rougail/convert/object_model.py:326 msgid "" "the variable \"{0}\" has a depreciated return_type \"{1}\", please use " "\"{2}\" instead in {3}" @@ -435,8 +439,8 @@ msgstr "" "la variable \"{0}\" a un attribut return_type déprécié \"{1}\", veuillez " "utiliser \"{2}\" au lieu de \"{3}\"" -#: src/rougail/convert/object_model.py:413 -#: src/rougail/convert/object_model.py:447 +#: src/rougail/convert/object_model.py:414 +#: src/rougail/convert/object_model.py:448 msgid "" "variable \"{0}\" has a calculating \"{1}\" with an invalid return_type, " "should be boolean or string, not \"{2}\"" @@ -444,7 +448,7 @@ msgstr "" "la variable \"{0}\" a un calcul \"{1}\" avec un return_type invalide, " "devrait être un booléen ou une chaîne de caractère, et pas \"{2}\"" -#: src/rougail/convert/object_model.py:424 +#: src/rougail/convert/object_model.py:425 msgid "" "the variable \"{0}\" has a return_type \"{1}\", for attribute \"{2}\" but " "has not description in {3}" @@ -452,11 +456,11 @@ msgstr "" "la variable \"{0}\" a un return_type \"{1}\", pour l'attribut \"{2}\" mais " "n'a pas de description dans {3}" -#: src/rougail/convert/object_model.py:429 +#: src/rougail/convert/object_model.py:430 msgid "value is invalid" msgstr "la valeur est invalide" -#: src/rougail/convert/object_model.py:523 +#: src/rougail/convert/object_model.py:525 msgid "" "a variable \"{0}\" is needs in attribute \"{1}\" for \"{2}\" but it's a " "family" @@ -464,7 +468,15 @@ msgstr "" "une variable \"{0}\" est nécessaire pour l'attribut \"{1}\" pour \"{2}\" " "mais c'est une famille" -#: src/rougail/convert/object_model.py:545 +#: src/rougail/convert/object_model.py:548 +msgid "" +"variable \"{0}\" has an attribute \"{1}\" with an identifier \"{2}\" but the " +"path has also the identifier \"{3}\"" +msgstr "" +"la variable \"{0}\" a un attribut \"{1}\" avec un identifiant \"{2}\" mais " +"le chemin a aussi l'identifiant \"{3}\"" + +#: src/rougail/convert/object_model.py:556 msgid "" "variable \"{0}\" has an attribute \"{1}\" calculated with the unknown " "variable \"{2}\"" @@ -472,7 +484,7 @@ msgstr "" "la variable \"{0}\" a un attribut invalide \"{1}\" calculé avec la variable " "inconnue \"{2}\"" -#: src/rougail/convert/object_model.py:593 +#: src/rougail/convert/object_model.py:605 msgid "" "the variable \"{0}\" has an invalid \"{1}\" the variable \"{2}\" is in a sub " "dynamic option" @@ -480,14 +492,14 @@ msgstr "" "la variable \"{0}\" a un attribut invalide \"{1}\", la variable \"{2}\" est " "dans une sous option dynamique" -#: src/rougail/convert/object_model.py:602 +#: src/rougail/convert/object_model.py:614 msgid "" "the leader \"{0}\" has an invalid \"{1}\" the follower \"{2}\" is a multi" msgstr "" "la variable meneuse \"{0}\" a un attribut invalide \"{1}\", la variable " "suiveuse \"{2}\" est multiple" -#: src/rougail/convert/object_model.py:644 +#: src/rougail/convert/object_model.py:656 msgid "" "the variable \"{0}\" has an invalid attribute \"{1}\", the variable \"{2}\" " "must not be multi" @@ -495,7 +507,7 @@ msgstr "" "la variable \"{0}\" a un attribut invalide \"{1}\", la variable \"{2}\" ne " "doit pas être multiple" -#: src/rougail/convert/object_model.py:658 +#: src/rougail/convert/object_model.py:670 msgid "" "the variable \"{0}\" has an invalid attribute \"{1}\", the variable must not " "be a multi or the variable \"{2}\" must be multi" @@ -503,7 +515,7 @@ msgstr "" "la variable \"{0}\" a un attribut invalide \"{1}\", la variable ne doit pas " "être multiple ou la variable \"{2}\" doit être multiple" -#: src/rougail/convert/object_model.py:672 +#: src/rougail/convert/object_model.py:684 msgid "" "the variable \"{0}\" has an invalid attribute \"{1}\", the variable must be " "a multi or the variable \"{2}\" must not be multi" @@ -511,7 +523,7 @@ msgstr "" "la variable \"{0}\" a un attribut invalide \"{1}\", la variable doit être " "multiple ou la variable \"{2}\" ne doit pas être multiple" -#: src/rougail/convert/object_model.py:686 +#: src/rougail/convert/object_model.py:698 msgid "" "the variable \"{0}\" has an invalid attribute \"{1}\", the variable \"{2}\" " "is multi but is inside a list" @@ -519,7 +531,7 @@ msgstr "" "la variable \"{0}\" a un attribut invalide \"{1}\", la variable \"{2}\" est " "multiple mais est dans une liste" -#: src/rougail/convert/object_model.py:708 +#: src/rougail/convert/object_model.py:720 msgid "" "the variable \"{0}\" is waiting for a list as \"{1}\" but the attribute " "\"default\" is not a list (\"{2}\")" @@ -527,7 +539,7 @@ msgstr "" "la variable \"{0}\" attend une liste comme \"{1}\" mais l'attribut " "\"default\" n'est pas une liste \"{2}\"" -#: src/rougail/convert/object_model.py:712 +#: src/rougail/convert/object_model.py:724 msgid "" "the variable \"{0}\" is not waiting for a list as \"{1}\" but the attribute " "\"default\" is a list (\"{2}\")" @@ -535,7 +547,7 @@ msgstr "" "la variable \"{0}\" n'attend pas une liste comme \"{1}\" mais l'attribut " "\"default\" est une liste \"{2}\"" -#: src/rougail/convert/object_model.py:737 +#: src/rougail/convert/object_model.py:748 msgid "" "\"{0}\" attribut shall not have an \"optional\" attribute without the " "\"default\" attribute for variable \"{1}\"" @@ -543,7 +555,7 @@ msgstr "" "l'attribut \"{0}\" ne devrait pas avoir d'attribut \"optional\" sans " "l'attribut \"default\" pour la variable \"{1}\"" -#: src/rougail/convert/object_model.py:759 +#: src/rougail/convert/object_model.py:770 msgid "" "variable \"{0}\" has a default value calculated with \"{1}\" which has " "incompatible type" @@ -551,7 +563,7 @@ msgstr "" "la variable \"{0}\" a une valeur par défaut calculé a partir de \"{1}\" " "laquelle a un type incompatible" -#: src/rougail/convert/object_model.py:805 +#: src/rougail/convert/object_model.py:816 msgid "" "the variable \"{0}\" is waiting for a boolean as \"{1}\" but the attribute " "\"default\" is not a boolean (\"{2}\")" @@ -559,7 +571,7 @@ msgstr "" "la variable \"{0}\" attend un booléan comme \"{1}\" mais l'attribut " "\"default\" n'est pas une booléan (\"{2}\")" -#: src/rougail/convert/object_model.py:828 +#: src/rougail/convert/object_model.py:840 msgid "" "\"when\" is not allowed in format version 1.0 for attribute \"{0}\" for " "variable \"{1}\"" @@ -567,7 +579,7 @@ msgstr "" "\"when\" n'est pas autorisé avec le format en version 1.0 pour l'attribut " "\"{0}\" pour la variable \"{1}\"" -#: src/rougail/convert/object_model.py:833 +#: src/rougail/convert/object_model.py:845 msgid "" "the variable \"{0}\" has an invalid attribute \"{1}\", \"when\" and " "\"when_not\" cannot set together" @@ -575,7 +587,7 @@ msgstr "" "la variable \"{0}\" a un attribut invalide \"{1}\", \"when\" et \"when_not\" " "ne peuvent pas être défini ensemble" -#: src/rougail/convert/object_model.py:841 +#: src/rougail/convert/object_model.py:853 msgid "" "\"when_not\" is not allowed in format version 1.0 for attribute \"{0}\" for " "variable \"{1}\"" @@ -583,7 +595,7 @@ msgstr "" "\"when_not\" n'est pas autorisé au format 1.0 pour l'attribut \"{0}\" pour " "la variable variable \"{1}\"" -#: src/rougail/convert/object_model.py:852 +#: src/rougail/convert/object_model.py:864 msgid "" "\"when\" or \"when_not\" is mandatory for the not boolean variable \"{0}\" " "in attribute \"{1}\"" @@ -591,7 +603,7 @@ msgstr "" "\"when\" ou \"when_not\" est obligatoire pour la variable non booléenne " "\"{0}\" dans l'attribut \"{1}\"" -#: src/rougail/convert/object_model.py:899 +#: src/rougail/convert/object_model.py:909 msgid "" "cannot find variable \"{0}\" for the information \"{1}\" when calculating " "\"{2}\"" @@ -599,19 +611,19 @@ msgstr "" "ne peut trouver la variable \"{0}\" pour l'information \"{1}\" lors du " "calcul de \"{2}\"" -#: src/rougail/convert/object_model.py:904 +#: src/rougail/convert/object_model.py:914 msgid "" "identifier not allowed for the information \"{0}\" when calculating \"{1}\"" msgstr "" "identifier n'est pas autorisé pour l'information \"{0}\" lors du calcul de " "\"{1}\"" -#: src/rougail/convert/object_model.py:958 +#: src/rougail/convert/object_model.py:966 msgid "\"when\" is not allowed in format version 1.0 for attribute \"{0}\"" msgstr "\"when\" n'est pas autorisé au format 1.0 pour l'attribut \"{0}\"" -#: src/rougail/convert/object_model.py:964 -#: src/rougail/convert/object_model.py:974 +#: src/rougail/convert/object_model.py:972 +#: src/rougail/convert/object_model.py:982 msgid "" "the identifier has an invalid attribute \"{0}\", \"when\" and \"when_not\" " "cannot set together" @@ -619,20 +631,20 @@ msgstr "" "l'identifiant a un attribut invalide \"{0}\", \"when\" et \"when_not\" ne " "peuvent pas être défini ensemble" -#: src/rougail/convert/object_model.py:1001 +#: src/rougail/convert/object_model.py:1008 msgid "" "the variable \"{0}\" is not a follower, so cannot have index type for \"{1}\"" msgstr "" "la variable \"{0}\" n'est pas suiveuse, donc ne peut avoir de type index " "pour \"{1}\"" -#: src/rougail/convert/path.py:211 +#: src/rougail/convert/path.py:213 msgid "" -"A variable or a family located in the \"{0}\" namespace shall not be used in " -"the \"{1}\" namespace" +"The variable or the family \"{0}\" located in the \"{1}\" namespace shall " +"not be used in the \"{2}\" namespace" msgstr "" -"Une variable ou une famille localisé dans l'espace de nom \"{0}\" ne devrait " -"pas être utilisé dans l'espace de nom \"{1}\"" +"La variable ou la famille \"{0}\" placée dans l'espace de nom \"{1}\" ne " +"devrait pas être utilisé dans l'espace de nom \"{2}\"" #: src/rougail/convert/tiramisureflector.py:348 msgid "" @@ -712,7 +724,7 @@ msgstr "" "Répertoires où sont placés les fichiers de structure de l'espace de nom " "supplémentaire" -#: src/rougail/structural_directory/config.py:106 +#: src/rougail/structural_directory/config.py:104 msgid "directory is not in \"__.step.structural\"" msgstr "directory n'est pas dans \"__.step.structural\"" @@ -899,38 +911,30 @@ msgstr "\"{0}\" est un {1} invalide" msgid "the attribute \"{0}\" in {1} causes the error: {2}" msgstr "l'attribut \"{0}\" dans {1} provoque l'erreur : {2}" -#: src/rougail/types.py:66 -msgid "type is not compatible with leadership family" -msgstr "type n'est pas compatible avec une famille leadership" - -#: src/rougail/types.py:68 -msgid "type is not compatible with dynamic family" -msgstr "type n'est pas compatible avec une famille dynamique" - -#: src/rougail/user_data.py:104 +#: src/rougail/user_data.py:105 msgid "{0}, it will be ignored" msgstr "{0}, elle sera ignorée" -#: src/rougail/user_data.py:155 +#: src/rougail/user_data.py:156 msgid "" "cannot load variable path \"{0}\", the identifier \"{1}\" is not valid in {2}" msgstr "" "ne peut charger la variable \"{0}\", l'identifiant \"{1}\" n'est pas valide " "dans {2}" -#: src/rougail/user_data.py:239 +#: src/rougail/user_data.py:240 msgid "the variable contains secrets and should not be defined in {0}" msgstr "" "la variable contient des secrets et ne devrait pas être défini dans {0}" -#: src/rougail/user_data.py:318 +#: src/rougail/user_data.py:326 msgid "" "it's a family so we cannot set the value {0}, it has been loading from {1}" msgstr "" "c'est une famille donc il n'est pas possible de définir la valeur {0}, elle " "a été chargée depuis {1}" -#: src/rougail/user_data.py:322 +#: src/rougail/user_data.py:330 msgid "" "it's a family so we cannot set the value {0}, it will be ignored when " "loading from {1}" @@ -938,38 +942,38 @@ msgstr "" "c'est une famille donc il n'est pas possible de définir la valeur {0}, elle " "sera ignorée lors du chargement depuis {1}" -#: src/rougail/user_data.py:332 +#: src/rougail/user_data.py:340 msgid "it's a symlink option so we cannot set the value {0}" msgstr "" "c'est un option symlink donc il n'est pas possible de définir la valeur {0}" -#: src/rougail/user_data.py:334 src/rougail/user_data.py:364 -#: src/rougail/user_data.py:493 src/rougail/user_data.py:505 -#: src/rougail/user_data.py:518 +#: src/rougail/user_data.py:342 src/rougail/user_data.py:372 +#: src/rougail/user_data.py:504 src/rougail/user_data.py:516 +#: src/rougail/user_data.py:529 msgid "{0}, it has been loading from {1}" msgstr "{0}, elle a été chargée depuis {1}" -#: src/rougail/user_data.py:336 src/rougail/user_data.py:368 -#: src/rougail/user_data.py:497 src/rougail/user_data.py:509 -#: src/rougail/user_data.py:520 +#: src/rougail/user_data.py:344 src/rougail/user_data.py:376 +#: src/rougail/user_data.py:508 src/rougail/user_data.py:520 +#: src/rougail/user_data.py:531 msgid "{0}, it will be ignored when loading from {1}" msgstr "{0}, elle sera ignorée lors du chargement depuis {1}" -#: src/rougail/user_data.py:341 src/rougail/user_data.py:346 +#: src/rougail/user_data.py:349 src/rougail/user_data.py:354 msgid "{0}, it has been loaded from {1}" msgstr "{0}, elle a été chargée depuis {1}" -#: src/rougail/user_data.py:360 +#: src/rougail/user_data.py:368 msgid "variable or family \"{0}\" does not exist so cannot load \"{1}\"" msgstr "" "la variable ou la famille \"{0}\" n'existe pas donc ne peut charger \"{1}\"" -#: src/rougail/user_data.py:377 +#: src/rougail/user_data.py:385 msgid "\"{0}\" is the name of a dynamic family, it has been loading from {1}" msgstr "" "\"{0}\" est le nom d'une famille dynamique, elle a été chargée depuis {1}" -#: src/rougail/user_data.py:381 +#: src/rougail/user_data.py:389 msgid "" "\"{0}\" is the name of a dynamic family, it will be ignored when loading " "from {1}" @@ -977,16 +981,16 @@ msgstr "" "\"{0}\" est le nom d'une famille dynamique, il sera ignoré lors du " "chargement depuis {1}" -#: src/rougail/user_data.py:387 +#: src/rougail/user_data.py:395 msgid "{0} loaded from {1}" msgstr "{0} chargée depuis {1}" -#: src/rougail/user_data.py:426 +#: src/rougail/user_data.py:436 msgid "variable {0} at index \"{1}\" is {2}, it has been loading from {3}" msgstr "" "la variable {0} à l'index \"{1}\" est {2}, elle a été chargée depuis {3}" -#: src/rougail/user_data.py:430 +#: src/rougail/user_data.py:440 msgid "" "variable {0} at index \"{1}\" is {2}, it will be ignored when loading from " "{3}" @@ -994,29 +998,29 @@ msgstr "" "la variable {0} à l'index \"{1}\" est {2}, elle sera ignorée lors du " "chargement depuis {3}" -#: src/rougail/user_data.py:443 +#: src/rougail/user_data.py:453 msgid "family {0} is {1}, {2} at index \"{3}\", it has been loading from {4}" msgstr "" "la famille {0} est {1}, {2} à l'index \"{3}\", elle a été chargée depuis {4}" -#: src/rougail/user_data.py:447 +#: src/rougail/user_data.py:457 msgid "" "family {0} is {1}, {2} at index \"{3}\", it will be ignored when loading " "from {4}" msgstr "" "la famille {0} est {1}, {2} à l'index \"{3}\", elle a été chargée depuis {4}" -#: src/rougail/user_data.py:462 +#: src/rougail/user_data.py:472 msgid "variable has propery {0}, it has been loading from {1}" msgstr "la variable a la propriété {0}, elle a été chargée depuis {1}" -#: src/rougail/user_data.py:466 +#: src/rougail/user_data.py:476 msgid "variable has property {0}, it will be ignored when loading from {1}" msgstr "" "la variable a la propriété {0}, elle sera ignorée lors du chargement depuis " "{1}" -#: src/rougail/user_data.py:476 +#: src/rougail/user_data.py:487 msgid "" "family {0} has property {1}, so cannot access to {2}, it has been loading " "from {3}" @@ -1024,7 +1028,7 @@ msgstr "" "la famille {0} a la propriété {1}, donc ne peut accéder à {2}, elle a été " "chargée depuis {3}" -#: src/rougail/user_data.py:480 +#: src/rougail/user_data.py:491 msgid "" "family {0} has property {1}, so cannot access to {2}, it will be ignored " "when loading from {3}" @@ -1032,26 +1036,53 @@ msgstr "" "la famille {0} a la propriété {1}, donc ne peut accéder à {2}, sera ignorée " "lors du chargement depuis {3}" -#: src/rougail/user_data.py:525 +#: src/rougail/user_data.py:536 msgid "the value {0} is an invalid {1}, {2}" msgstr "la valeur {0} est un {1} invalide, {2}" -#: src/rougail/user_data.py:531 +#: src/rougail/user_data.py:542 msgid ", it has been loading from {0}" msgstr ", elle a été chargée depuis {0}" -#: src/rougail/user_data.py:533 +#: src/rougail/user_data.py:544 msgid ", it will be ignored when loading from {0}" msgstr ", elle sera ignorée lors du chargement depuis {0}" -#: src/rougail/user_data.py:566 +#: src/rougail/user_data.py:585 msgid "loaded from {0}" msgstr "chargée depuis {0}" -#: src/rougail/user_data.py:574 +#: src/rougail/user_data.py:593 msgid "{0} (the search key is \"{1}\")" msgstr "{0} (la clé recherchée est \"{1}\")" +#: src/rougail/user_data.py:652 src/rougail/user_data.py:666 +msgid "null is not a valid value for a multi" +msgstr "null est une valeur invalide pour une multi" + +#: src/rougail/user_data.py:655 src/rougail/user_data.py:668 +msgid "mandatory variable but has no value" +msgstr "variable obligatoire mais sans valeur" + +#: src/rougail/user_data.py:657 +msgid "mandatory variable at index \"{0}\" but has no value" +msgstr "la variable obligatoire à l'index \"{0}\" mais n'a pas de valeur" + +#: src/rougail/user_data.py:660 +msgid "" +"mandatory variable but is inaccessible and has no value or has null in value" +msgstr "" +"une variable obligatoire mais est inaccessible et n'a pas de valeur ou a une " +"valeur null" + +#: src/rougail/user_data.py:662 +msgid "" +"mandatory variable at index \"{0}\" but is inaccessible and has no value or " +"has null in value" +msgstr "" +"une variable obligatoire a l'index \"{0}\" mais est inaccessible et n'a pas " +"de valeur ou a une valeur null" + #: src/rougail/utils.py:56 msgid "" "invalid variable or family name \"{0}\" must only contains lowercase ascii " @@ -1064,26 +1095,32 @@ msgstr "" msgid "error for the variable \"{1}\" in jinja \"{0}\": {2}" msgstr "erreur pour la variable \"{1}\" dans le jinja \"{0}\": {2}" -#: src/rougail/utils.py:212 +#: src/rougail/utils.py:216 msgid "mandatory" msgstr "obligatoire" -#: src/rougail/utils.py:213 +#: src/rougail/utils.py:217 msgid "hidden" msgstr "cachée" -#: src/rougail/utils.py:214 +#: src/rougail/utils.py:218 msgid "disabled" msgstr "désactivé" -#: src/rougail/utils.py:215 +#: src/rougail/utils.py:219 msgid "unique" msgstr "unique" -#: src/rougail/utils.py:216 +#: src/rougail/utils.py:220 msgid "auto modified" msgstr "auto modifiée" +#~ msgid "type is not compatible with leadership family" +#~ msgstr "type n'est pas compatible avec une famille leadership" + +#~ msgid "type is not compatible with dynamic family" +#~ msgstr "type n'est pas compatible avec une famille dynamique" + #~ msgid "" #~ "variable or family \"{0}\" does not exist, it will be ignored when " #~ "loading from {1}" diff --git a/locale/rougail.pot b/locale/rougail.pot index 6d94ac222..a47a9501a 100644 --- a/locale/rougail.pot +++ b/locale/rougail.pot @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" -"POT-Creation-Date: 2026-01-21 08:42+0100\n" +"POT-Creation-Date: 2026-04-29 21:11+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -47,15 +47,15 @@ msgstr "" msgid "the variable \"{0}\" is in \"{1}\" mode but family has the higher family mode \"{2}\"" msgstr "" -#: src/rougail/annotator/property.py:181 +#: src/rougail/annotator/property.py:182 msgid "invalid tag name \"{0}\" should only contains lowercase ascii character, number or _" msgstr "" -#: src/rougail/annotator/property.py:186 +#: src/rougail/annotator/property.py:187 msgid "invalid tag name \"{0}\" should not be a name of an existing mode" msgstr "" -#: src/rougail/annotator/property.py:191 +#: src/rougail/annotator/property.py:192 msgid "invalid tag name \"{0}\" should not be the name of an available properties" msgstr "" @@ -115,178 +115,182 @@ msgstr "" msgid "the \"{0}\" default value is a calculation with itself" msgstr "" -#: src/rougail/annotator/variable.py:306 +#: src/rougail/annotator/variable.py:310 msgid "the variable \"{0}\" has regexp attribut but has not the \"regexp\" type" msgstr "" -#: src/rougail/annotator/variable.py:349 +#: src/rougail/annotator/variable.py:353 msgid "the variable \"{0}\" has choices attribut but has not the \"choice\" type" msgstr "" -#: src/rougail/annotator/variable.py:377 +#: src/rougail/annotator/variable.py:381 msgid "the variable \"{0}\" has an unvalid default value \"{1}\" should be in {2}" msgstr "" -#: src/rougail/config/__init__.py:272 +#: src/rougail/config/__init__.py:283 msgid "Default version of the structural file format" msgstr "" -#: src/rougail/config/__init__.py:273 +#: src/rougail/config/__init__.py:284 msgid "This value is only used if the version is not set in the structural file" msgstr "" -#: src/rougail/config/__init__.py:281 +#: src/rougail/config/__init__.py:292 msgid "File with personalize types" msgstr "" -#: src/rougail/config/__init__.py:282 +#: src/rougail/config/__init__.py:293 msgid "This file contains personalize types in Rougail format for structure files" msgstr "" -#: src/rougail/config/__init__.py:291 +#: src/rougail/config/__init__.py:302 msgid "File with functions" msgstr "" -#: src/rougail/config/__init__.py:292 +#: src/rougail/config/__init__.py:303 msgid "This file contains filters and additional Jinja2 functions usable in structure files" msgstr "" -#: src/rougail/config/__init__.py:303 +#: src/rougail/config/__init__.py:314 msgid "All modes level available" msgstr "" -#: src/rougail/config/__init__.py:315 +#: src/rougail/config/__init__.py:326 msgid "Default mode for a family" msgstr "" -#: src/rougail/config/__init__.py:321 +#: src/rougail/config/__init__.py:332 msgid "the first one defined in \"modes_level\"" msgstr "" -#: src/rougail/config/__init__.py:327 src/rougail/config/__init__.py:354 +#: src/rougail/config/__init__.py:338 src/rougail/config/__init__.py:365 msgid "when no mode is defined in \"modes_level\"" msgstr "" -#: src/rougail/config/__init__.py:334 src/rougail/config/__init__.py:361 +#: src/rougail/config/__init__.py:345 src/rougail/config/__init__.py:372 msgid "this mode must be available in \"modes_level\"" msgstr "" -#: src/rougail/config/__init__.py:338 +#: src/rougail/config/__init__.py:349 msgid "Default mode for a variable" msgstr "" -#: src/rougail/config/__init__.py:348 +#: src/rougail/config/__init__.py:359 msgid "if the variable \"modes_level\" is defined, the default value is the second available element, otherwise, the first" msgstr "" -#: src/rougail/config/__init__.py:365 +#: src/rougail/config/__init__.py:376 msgid "Option name for the base option" msgstr "" -#: src/rougail/config/__init__.py:370 +#: src/rougail/config/__init__.py:381 msgid "In cache file, do not importation of Tiramisu and other dependencies" msgstr "" -#: src/rougail/config/__init__.py:375 +#: src/rougail/config/__init__.py:386 msgid "Store Tiramisu cache filename" msgstr "" -#: src/rougail/config/__init__.py:376 +#: src/rougail/config/__init__.py:387 msgid "" "This file contains the Tiramisu instructions used internally to load the variables.\n" "\n" "This file can be used for debugging" msgstr "" -#: src/rougail/config/__init__.py:386 +#: src/rougail/config/__init__.py:398 msgid "Name of internal functions that we can use as a function" msgstr "" -#: src/rougail/config/__init__.py:392 +#: src/rougail/config/__init__.py:404 msgid "Name of extra annotators" msgstr "" -#: src/rougail/config/__init__.py:398 +#: src/rougail/config/__init__.py:410 msgid "Suffix add to generated options name" msgstr "" -#: src/rougail/config/__init__.py:404 +#: src/rougail/config/__init__.py:416 msgid "Every variables in calculation are optionals" msgstr "" -#: src/rougail/config/__init__.py:408 +#: src/rougail/config/__init__.py:420 msgid "Loads redefine variables even if there don't already exists" msgstr "" -#: src/rougail/config/__init__.py:412 +#: src/rougail/config/__init__.py:424 msgid "The secret manager" msgstr "" -#: src/rougail/config/__init__.py:415 +#: src/rougail/config/__init__.py:427 msgid "The secret pattern to constructing the name of the item searched for in the secret manager" msgstr "" -#: src/rougail/config/__init__.py:416 +#: src/rougail/config/__init__.py:428 msgid "The pattern is in Jinja2 format" msgstr "" -#: src/rougail/config/__init__.py:425 +#: src/rougail/config/__init__.py:437 msgid "structural" msgstr "" -#: src/rougail/config/__init__.py:426 +#: src/rougail/config/__init__.py:438 msgid "user datas" msgstr "" -#: src/rougail/config/__init__.py:427 +#: src/rougail/config/__init__.py:439 msgid "output" msgstr "" -#: src/rougail/config/__init__.py:448 -msgid "Select for {0}" +#: src/rougail/config/__init__.py:460 +msgid "select for {0}" msgstr "" -#: src/rougail/config/__init__.py:486 +#: src/rougail/config/__init__.py:498 msgid "outputs {0} did not allow user data" msgstr "" -#: src/rougail/config/__init__.py:512 +#: src/rougail/config/__init__.py:524 msgid "Override default parameters for option type" msgstr "" -#: src/rougail/config/__init__.py:515 +#: src/rougail/config/__init__.py:527 msgid "Default parameters for option type" msgstr "" -#: src/rougail/convert/convert.py:281 -msgid "unknown type {0} for {1}" +#: src/rougail/convert/convert.py:282 +msgid "unknown type \"{0}\" for \"{1}\"" msgstr "" -#: src/rougail/convert/convert.py:444 +#: src/rougail/convert/convert.py:441 msgid "family \"{0}\" define multiple time" msgstr "" -#: src/rougail/convert/convert.py:715 +#: src/rougail/convert/convert.py:739 msgid "variable \"{0}\" define multiple time" msgstr "" -#: src/rougail/convert/convert.py:808 src/rougail/convert/convert.py:815 +#: src/rougail/convert/convert.py:796 +msgid "the {0} \"{1}\" has an invalid \"{2}\": {3}" +msgstr "" + +#: src/rougail/convert/convert.py:836 src/rougail/convert/convert.py:843 msgid "params must be a dict for {0}" msgstr "" -#: src/rougail/convert/convert.py:836 +#: src/rougail/convert/convert.py:864 msgid "\"{0}\" has an invalid \"params\" for {1}: {2}" msgstr "" -#: src/rougail/convert/convert.py:850 +#: src/rougail/convert/convert.py:881 msgid "secret_manager must be a dict for {0}" msgstr "" -#: src/rougail/convert/convert.py:1190 +#: src/rougail/convert/convert.py:1257 msgid "Cannot execute annotate multiple time" msgstr "" -#: src/rougail/convert/convert.py:1197 +#: src/rougail/convert/convert.py:1264 msgid "invalid \"structural\" definition ({0}), we cannot load any structural file!" msgstr "" @@ -299,7 +303,7 @@ msgid "the variable \"{0}\" is in fact a family in attribute \"{1}\" for \"{2}\" msgstr "" #: src/rougail/convert/object_model.py:143 -#: src/rougail/convert/object_model.py:528 +#: src/rougail/convert/object_model.py:530 msgid "unknown object \"{0}\" in attribute \"{1}\" for \"{2}\"" msgstr "" @@ -319,118 +323,122 @@ msgstr "" msgid "the variable \"{0}\" is not a follower, so cannot have index type for param in \"{1}\"" msgstr "" -#: src/rougail/convert/object_model.py:263 +#: src/rougail/convert/object_model.py:264 msgid "\"warnings\" are only available with attribute \"{self.attribute_name}\" for variable \"{self.path}\"" msgstr "" -#: src/rougail/convert/object_model.py:325 +#: src/rougail/convert/object_model.py:326 msgid "the variable \"{0}\" has a depreciated return_type \"{1}\", please use \"{2}\" instead in {3}" msgstr "" -#: src/rougail/convert/object_model.py:413 -#: src/rougail/convert/object_model.py:447 +#: src/rougail/convert/object_model.py:414 +#: src/rougail/convert/object_model.py:448 msgid "variable \"{0}\" has a calculating \"{1}\" with an invalid return_type, should be boolean or string, not \"{2}\"" msgstr "" -#: src/rougail/convert/object_model.py:424 +#: src/rougail/convert/object_model.py:425 msgid "the variable \"{0}\" has a return_type \"{1}\", for attribute \"{2}\" but has not description in {3}" msgstr "" -#: src/rougail/convert/object_model.py:429 +#: src/rougail/convert/object_model.py:430 msgid "value is invalid" msgstr "" -#: src/rougail/convert/object_model.py:523 +#: src/rougail/convert/object_model.py:525 msgid "a variable \"{0}\" is needs in attribute \"{1}\" for \"{2}\" but it's a family" msgstr "" -#: src/rougail/convert/object_model.py:545 +#: src/rougail/convert/object_model.py:548 +msgid "variable \"{0}\" has an attribute \"{1}\" with an identifier \"{2}\" but the path has also the identifier \"{3}\"" +msgstr "" + +#: src/rougail/convert/object_model.py:556 msgid "variable \"{0}\" has an attribute \"{1}\" calculated with the unknown variable \"{2}\"" msgstr "" -#: src/rougail/convert/object_model.py:593 +#: src/rougail/convert/object_model.py:605 msgid "the variable \"{0}\" has an invalid \"{1}\" the variable \"{2}\" is in a sub dynamic option" msgstr "" -#: src/rougail/convert/object_model.py:602 +#: src/rougail/convert/object_model.py:614 msgid "the leader \"{0}\" has an invalid \"{1}\" the follower \"{2}\" is a multi" msgstr "" -#: src/rougail/convert/object_model.py:644 +#: src/rougail/convert/object_model.py:656 msgid "the variable \"{0}\" has an invalid attribute \"{1}\", the variable \"{2}\" must not be multi" msgstr "" -#: src/rougail/convert/object_model.py:658 +#: src/rougail/convert/object_model.py:670 msgid "the variable \"{0}\" has an invalid attribute \"{1}\", the variable must not be a multi or the variable \"{2}\" must be multi" msgstr "" -#: src/rougail/convert/object_model.py:672 +#: src/rougail/convert/object_model.py:684 msgid "the variable \"{0}\" has an invalid attribute \"{1}\", the variable must be a multi or the variable \"{2}\" must not be multi" msgstr "" -#: src/rougail/convert/object_model.py:686 +#: src/rougail/convert/object_model.py:698 msgid "the variable \"{0}\" has an invalid attribute \"{1}\", the variable \"{2}\" is multi but is inside a list" msgstr "" -#: src/rougail/convert/object_model.py:708 +#: src/rougail/convert/object_model.py:720 msgid "the variable \"{0}\" is waiting for a list as \"{1}\" but the attribute \"default\" is not a list (\"{2}\")" msgstr "" -#: src/rougail/convert/object_model.py:712 +#: src/rougail/convert/object_model.py:724 msgid "the variable \"{0}\" is not waiting for a list as \"{1}\" but the attribute \"default\" is a list (\"{2}\")" msgstr "" -#: src/rougail/convert/object_model.py:737 +#: src/rougail/convert/object_model.py:748 msgid "\"{0}\" attribut shall not have an \"optional\" attribute without the \"default\" attribute for variable \"{1}\"" msgstr "" -#: src/rougail/convert/object_model.py:759 +#: src/rougail/convert/object_model.py:770 msgid "variable \"{0}\" has a default value calculated with \"{1}\" which has incompatible type" msgstr "" -#: src/rougail/convert/object_model.py:805 +#: src/rougail/convert/object_model.py:816 msgid "the variable \"{0}\" is waiting for a boolean as \"{1}\" but the attribute \"default\" is not a boolean (\"{2}\")" msgstr "" -#: src/rougail/convert/object_model.py:828 +#: src/rougail/convert/object_model.py:840 msgid "\"when\" is not allowed in format version 1.0 for attribute \"{0}\" for variable \"{1}\"" msgstr "" -#: src/rougail/convert/object_model.py:833 +#: src/rougail/convert/object_model.py:845 msgid "the variable \"{0}\" has an invalid attribute \"{1}\", \"when\" and \"when_not\" cannot set together" msgstr "" -#: src/rougail/convert/object_model.py:841 +#: src/rougail/convert/object_model.py:853 msgid "\"when_not\" is not allowed in format version 1.0 for attribute \"{0}\" for variable \"{1}\"" msgstr "" -#: src/rougail/convert/object_model.py:852 +#: src/rougail/convert/object_model.py:864 msgid "\"when\" or \"when_not\" is mandatory for the not boolean variable \"{0}\" in attribute \"{1}\"" msgstr "" -#: src/rougail/convert/object_model.py:899 +#: src/rougail/convert/object_model.py:909 msgid "cannot find variable \"{0}\" for the information \"{1}\" when calculating \"{2}\"" msgstr "" -#: src/rougail/convert/object_model.py:904 +#: src/rougail/convert/object_model.py:914 msgid "identifier not allowed for the information \"{0}\" when calculating \"{1}\"" msgstr "" -#: src/rougail/convert/object_model.py:958 +#: src/rougail/convert/object_model.py:966 msgid "\"when\" is not allowed in format version 1.0 for attribute \"{0}\"" msgstr "" -#: src/rougail/convert/object_model.py:964 -#: src/rougail/convert/object_model.py:974 +#: src/rougail/convert/object_model.py:972 +#: src/rougail/convert/object_model.py:982 msgid "the identifier has an invalid attribute \"{0}\", \"when\" and \"when_not\" cannot set together" msgstr "" -#: src/rougail/convert/object_model.py:1001 +#: src/rougail/convert/object_model.py:1008 msgid "the variable \"{0}\" is not a follower, so cannot have index type for \"{1}\"" msgstr "" -#: src/rougail/convert/path.py:211 -msgid "A variable or a family located in the \"{0}\" namespace shall not be used in the \"{1}\" namespace" +#: src/rougail/convert/path.py:213 +msgid "The variable or the family \"{0}\" located in the \"{1}\" namespace shall not be used in the \"{2}\" namespace" msgstr "" #: src/rougail/convert/tiramisureflector.py:348 @@ -497,7 +505,7 @@ msgstr "" msgid "Directories where extra structural files are placed" msgstr "" -#: src/rougail/structural_directory/config.py:106 +#: src/rougail/structural_directory/config.py:104 msgid "directory is not in \"__.step.structural\"" msgstr "" @@ -678,122 +686,134 @@ msgstr "" msgid "the attribute \"{0}\" in {1} causes the error: {2}" msgstr "" -#: src/rougail/types.py:66 -msgid "type is not compatible with leadership family" -msgstr "" - -#: src/rougail/types.py:68 -msgid "type is not compatible with dynamic family" -msgstr "" - -#: src/rougail/user_data.py:104 +#: src/rougail/user_data.py:105 msgid "{0}, it will be ignored" msgstr "" -#: src/rougail/user_data.py:155 +#: src/rougail/user_data.py:156 msgid "cannot load variable path \"{0}\", the identifier \"{1}\" is not valid in {2}" msgstr "" -#: src/rougail/user_data.py:239 +#: src/rougail/user_data.py:240 msgid "the variable contains secrets and should not be defined in {0}" msgstr "" -#: src/rougail/user_data.py:318 +#: src/rougail/user_data.py:326 msgid "it's a family so we cannot set the value {0}, it has been loading from {1}" msgstr "" -#: src/rougail/user_data.py:322 +#: src/rougail/user_data.py:330 msgid "it's a family so we cannot set the value {0}, it will be ignored when loading from {1}" msgstr "" -#: src/rougail/user_data.py:332 +#: src/rougail/user_data.py:340 msgid "it's a symlink option so we cannot set the value {0}" msgstr "" -#: src/rougail/user_data.py:334 src/rougail/user_data.py:364 -#: src/rougail/user_data.py:493 src/rougail/user_data.py:505 -#: src/rougail/user_data.py:518 +#: src/rougail/user_data.py:342 src/rougail/user_data.py:372 +#: src/rougail/user_data.py:504 src/rougail/user_data.py:516 +#: src/rougail/user_data.py:529 msgid "{0}, it has been loading from {1}" msgstr "" -#: src/rougail/user_data.py:336 src/rougail/user_data.py:368 -#: src/rougail/user_data.py:497 src/rougail/user_data.py:509 -#: src/rougail/user_data.py:520 +#: src/rougail/user_data.py:344 src/rougail/user_data.py:376 +#: src/rougail/user_data.py:508 src/rougail/user_data.py:520 +#: src/rougail/user_data.py:531 msgid "{0}, it will be ignored when loading from {1}" msgstr "" -#: src/rougail/user_data.py:341 src/rougail/user_data.py:346 +#: src/rougail/user_data.py:349 src/rougail/user_data.py:354 msgid "{0}, it has been loaded from {1}" msgstr "" -#: src/rougail/user_data.py:360 +#: src/rougail/user_data.py:368 msgid "variable or family \"{0}\" does not exist so cannot load \"{1}\"" msgstr "" -#: src/rougail/user_data.py:377 +#: src/rougail/user_data.py:385 msgid "\"{0}\" is the name of a dynamic family, it has been loading from {1}" msgstr "" -#: src/rougail/user_data.py:381 +#: src/rougail/user_data.py:389 msgid "\"{0}\" is the name of a dynamic family, it will be ignored when loading from {1}" msgstr "" -#: src/rougail/user_data.py:387 +#: src/rougail/user_data.py:395 msgid "{0} loaded from {1}" msgstr "" -#: src/rougail/user_data.py:426 +#: src/rougail/user_data.py:436 msgid "variable {0} at index \"{1}\" is {2}, it has been loading from {3}" msgstr "" -#: src/rougail/user_data.py:430 +#: src/rougail/user_data.py:440 msgid "variable {0} at index \"{1}\" is {2}, it will be ignored when loading from {3}" msgstr "" -#: src/rougail/user_data.py:443 +#: src/rougail/user_data.py:453 msgid "family {0} is {1}, {2} at index \"{3}\", it has been loading from {4}" msgstr "" -#: src/rougail/user_data.py:447 +#: src/rougail/user_data.py:457 msgid "family {0} is {1}, {2} at index \"{3}\", it will be ignored when loading from {4}" msgstr "" -#: src/rougail/user_data.py:462 +#: src/rougail/user_data.py:472 msgid "variable has propery {0}, it has been loading from {1}" msgstr "" -#: src/rougail/user_data.py:466 +#: src/rougail/user_data.py:476 msgid "variable has property {0}, it will be ignored when loading from {1}" msgstr "" -#: src/rougail/user_data.py:476 +#: src/rougail/user_data.py:487 msgid "family {0} has property {1}, so cannot access to {2}, it has been loading from {3}" msgstr "" -#: src/rougail/user_data.py:480 +#: src/rougail/user_data.py:491 msgid "family {0} has property {1}, so cannot access to {2}, it will be ignored when loading from {3}" msgstr "" -#: src/rougail/user_data.py:525 +#: src/rougail/user_data.py:536 msgid "the value {0} is an invalid {1}, {2}" msgstr "" -#: src/rougail/user_data.py:531 +#: src/rougail/user_data.py:542 msgid ", it has been loading from {0}" msgstr "" -#: src/rougail/user_data.py:533 +#: src/rougail/user_data.py:544 msgid ", it will be ignored when loading from {0}" msgstr "" -#: src/rougail/user_data.py:566 +#: src/rougail/user_data.py:585 msgid "loaded from {0}" msgstr "" -#: src/rougail/user_data.py:574 +#: src/rougail/user_data.py:593 msgid "{0} (the search key is \"{1}\")" msgstr "" +#: src/rougail/user_data.py:652 src/rougail/user_data.py:666 +msgid "null is not a valid value for a multi" +msgstr "" + +#: src/rougail/user_data.py:655 src/rougail/user_data.py:668 +msgid "mandatory variable but has no value" +msgstr "" + +#: src/rougail/user_data.py:657 +msgid "mandatory variable at index \"{0}\" but has no value" +msgstr "" + +#: src/rougail/user_data.py:660 +msgid "mandatory variable but is inaccessible and has no value or has null in value" +msgstr "" + +#: src/rougail/user_data.py:662 +msgid "mandatory variable at index \"{0}\" but is inaccessible and has no value or has null in value" +msgstr "" + #: src/rougail/utils.py:56 msgid "invalid variable or family name \"{0}\" must only contains lowercase ascii character, number or _" msgstr "" @@ -802,23 +822,23 @@ msgstr "" msgid "error for the variable \"{1}\" in jinja \"{0}\": {2}" msgstr "" -#: src/rougail/utils.py:212 +#: src/rougail/utils.py:216 msgid "mandatory" msgstr "" -#: src/rougail/utils.py:213 +#: src/rougail/utils.py:217 msgid "hidden" msgstr "" -#: src/rougail/utils.py:214 +#: src/rougail/utils.py:218 msgid "disabled" msgstr "" -#: src/rougail/utils.py:215 +#: src/rougail/utils.py:219 msgid "unique" msgstr "" -#: src/rougail/utils.py:216 +#: src/rougail/utils.py:220 msgid "auto modified" msgstr "" diff --git a/src/rougail/__init__.py b/src/rougail/__init__.py index bcf9c3a78..98cc7be85 100644 --- a/src/rougail/__init__.py +++ b/src/rougail/__init__.py @@ -28,7 +28,7 @@ along with this program. If not, see . from .__version__ import __version__ try: - from .convert import Rougail + from .convert import Rougail, SUPPORTED_VERSION from .config import RougailConfig __all__ = ("Rougail", "RougailConfig", "__version__") diff --git a/src/rougail/config/__init__.py b/src/rougail/config/__init__.py index aa076ab0f..d213c0584 100644 --- a/src/rougail/config/__init__.py +++ b/src/rougail/config/__init__.py @@ -31,7 +31,7 @@ from tiramisu import Config from tiramisu.error import display_list from ruamel.yaml import YAML from ..utils import _, load_modules -from ..tiramisu import normalize_family +from ..tiramisu import normalize_family, tiramisu_display_name from ..convert import RougailConvert from ..convert.object_model import get_convert_option_types @@ -106,6 +106,7 @@ class _RougailConfig: ) self.config = Config( self.root, + display_name=tiramisu_display_name, ) self.extra_vars = extra_vars self.not_in_tiramisu = NOT_IN_TIRAMISU | extra_vars @@ -456,7 +457,7 @@ secret_manager: # {_("The secret manager")} rougail_process += f""" {process_name}: - description: {_('Select for {0}').format(tr_process_name)} + description: {_('select for {0}').format(tr_process_name)} """ if process != "structural": rougail_process += """ alternative_name: {NAME[0]} diff --git a/src/rougail/convert/__init__.py b/src/rougail/convert/__init__.py index 5f82d1564..5ccb5c64f 100644 --- a/src/rougail/convert/__init__.py +++ b/src/rougail/convert/__init__.py @@ -20,7 +20,7 @@ from typing import Optional from tiramisu import Config from warnings import warn -from .convert import RougailConvert +from .convert import RougailConvert, SUPPORTED_VERSION from ..types import rougail_type from ..config import RougailConfig from ..user_data import UserData diff --git a/src/rougail/convert/convert.py b/src/rougail/convert/convert.py index c6833f4d0..c5400e7ef 100644 --- a/src/rougail/convert/convert.py +++ b/src/rougail/convert/convert.py @@ -70,6 +70,7 @@ from ..error import DictConsistencyError property_types = Union[Literal[True], Calculation] properties_types = Dict[str, property_types] +SUPPORTED_VERSION = ["1.0", "1.1"] class Property: @@ -874,7 +875,7 @@ class ParserVariable: return if not isinstance(obj["secret_manager"], dict): if copy_before_set: - obj["secret_manager"] = obj["secret_manager"].copy() + obj["secret_manager"] = obj["secret_manager"].model_copy() return raise DictConsistencyError( _("secret_manager must be a dict for {0}").format(path), @@ -1126,8 +1127,6 @@ class ParserVariable: class RougailConvert(ParserVariable): """Main Rougail conversion""" - supported_version = ["1.0", "1.1"] - def __init__(self, rougailconfig, custom_variable_types: dict={}, @@ -1241,8 +1240,8 @@ class RougailConvert(ParserVariable): msg = '"version" attribut is mandatory in YAML file' raise DictConsistencyError(msg, 27, sources) - if version not in self.supported_version: - msg = f'version "{version}" is not supported, list of supported versions: {display_list(self.supported_version, separator="or", add_quote=True)}' + if version not in SUPPORTED_VERSION: + msg = f'version "{version}" is not supported, list of supported versions: {display_list(SUPPORTED_VERSION, separator="or", add_quote=True)}' raise DictConsistencyError(msg, 28, sources) return version diff --git a/src/rougail/locale/fr/LC_MESSAGES/rougail.mo b/src/rougail/locale/fr/LC_MESSAGES/rougail.mo index 14c17aded..1cf68e314 100644 Binary files a/src/rougail/locale/fr/LC_MESSAGES/rougail.mo and b/src/rougail/locale/fr/LC_MESSAGES/rougail.mo differ diff --git a/src/rougail/tiramisu.py b/src/rougail/tiramisu.py index 4a284ed43..e982ed708 100644 --- a/src/rougail/tiramisu.py +++ b/src/rougail/tiramisu.py @@ -131,7 +131,7 @@ CONVERT_OPTION = { example=42, ), "float": dict(opttype="FloatOption", func=float, example=1.42), - "boolean": dict(opttype="BoolOption", func=convert_boolean), + "boolean": dict(opttype="BoolOption", func=convert_boolean, example=True), "secret": dict(opttype="PasswordOption", params={ "min_len": {"description": _("minimum characters length for the secret"), "doc": _("minimum length for the secret is {0} characters")}, diff --git a/tests/dictionaries/00_6ip/tiramisu/base.py b/tests/dictionaries/00_6ip/tiramisu/base.py index 19fb53905..e90367c22 100644 --- a/tests/dictionaries/00_6ip/tiramisu/base.py +++ b/tests/dictionaries/00_6ip/tiramisu/base.py @@ -11,7 +11,7 @@ ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") option_2 = IPOption(name="var1", doc="an IP", default="1.1.1.1", allow_reserved=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/00_6ip/rougail/00-base.yml'], 'type': 'ip'}) -option_3 = IPOption(name="var2", doc="an IP in CIDR format", default="1.1.1.1/24", allow_reserved=True, cidr=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/00_6ip/rougail/00-base.yml'], 'type': 'ip', 'examples': ('192.168.0.128/25',)}) +option_3 = IPOption(name="var2", doc="an IP in CIDR format", default="1.1.1.1/24", allow_reserved=True, cidr=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/00_6ip/rougail/00-base.yml'], 'type': 'ip', 'examples': ('192.168.0.129/25',)}) option_4 = IPOption(name="var3", doc="an IP in CIDR format with obsolete CIDR type", default="1.1.1.1/24", cidr=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/00_6ip/rougail/00-base.yml'], 'type': 'cidr'}) optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_2, option_3, option_4], properties=frozenset({"standard"})) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1]) diff --git a/tests/dictionaries/00_6ip/tiramisu/no_namespace.py b/tests/dictionaries/00_6ip/tiramisu/no_namespace.py index 81a83e0ba..65728b7cd 100644 --- a/tests/dictionaries/00_6ip/tiramisu/no_namespace.py +++ b/tests/dictionaries/00_6ip/tiramisu/no_namespace.py @@ -11,6 +11,6 @@ ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") option_1 = IPOption(name="var1", doc="an IP", default="1.1.1.1", allow_reserved=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/00_6ip/rougail/00-base.yml'], 'type': 'ip'}) -option_2 = IPOption(name="var2", doc="an IP in CIDR format", default="1.1.1.1/24", allow_reserved=True, cidr=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/00_6ip/rougail/00-base.yml'], 'type': 'ip', 'examples': ('192.168.0.128/25',)}) +option_2 = IPOption(name="var2", doc="an IP in CIDR format", default="1.1.1.1/24", allow_reserved=True, cidr=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/00_6ip/rougail/00-base.yml'], 'type': 'ip', 'examples': ('192.168.0.129/25',)}) option_3 = IPOption(name="var3", doc="an IP in CIDR format with obsolete CIDR type", default="1.1.1.1/24", cidr=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/00_6ip/rougail/00-base.yml'], 'type': 'cidr'}) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_2, option_3]) diff --git a/tests/dictionaries/00_6secret_param/tiramisu/base.py b/tests/dictionaries/00_6secret_param/tiramisu/base.py index aa5ed64cf..f6765d88f 100644 --- a/tests/dictionaries/00_6secret_param/tiramisu/base.py +++ b/tests/dictionaries/00_6secret_param/tiramisu/base.py @@ -10,7 +10,7 @@ except: ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") -option_2 = PasswordOption(name="secret1", doc="the first variable", min_len=10, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['../rougail-tests/structures/00_6secret_param/rougail/00-base.yml'], 'type': 'secret'}) +option_2 = PasswordOption(name="secret1", doc="the first variable", min_len=10, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['../rougail-tests/structures/00_6secret_param/rougail/00-base.yml'], 'type': 'secret', 'examples': ('ALongS4cr4t',)}) option_3 = PasswordOption(name="secret2", doc="the second variable", default="value", max_len=10, forbidden_char=['$', '^'], properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/00_6secret_param/rougail/00-base.yml'], 'type': 'secret'}) option_4 = PasswordOption(name="secret3", doc="the third variable", default="value", max_len=10, forbidden_char=['$'], properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/00_6secret_param/rougail/00-base.yml'], 'type': 'secret'}) optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_2, option_3, option_4], properties=frozenset({"basic"})) diff --git a/tests/dictionaries/00_6secret_param/tiramisu/no_namespace.py b/tests/dictionaries/00_6secret_param/tiramisu/no_namespace.py index 7c8b233b9..eeb12fdcc 100644 --- a/tests/dictionaries/00_6secret_param/tiramisu/no_namespace.py +++ b/tests/dictionaries/00_6secret_param/tiramisu/no_namespace.py @@ -10,7 +10,7 @@ except: ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") -option_1 = PasswordOption(name="secret1", doc="the first variable", min_len=10, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['../rougail-tests/structures/00_6secret_param/rougail/00-base.yml'], 'type': 'secret'}) +option_1 = PasswordOption(name="secret1", doc="the first variable", min_len=10, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['../rougail-tests/structures/00_6secret_param/rougail/00-base.yml'], 'type': 'secret', 'examples': ('ALongS4cr4t',)}) option_2 = PasswordOption(name="secret2", doc="the second variable", default="value", max_len=10, forbidden_char=['$', '^'], properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/00_6secret_param/rougail/00-base.yml'], 'type': 'secret'}) option_3 = PasswordOption(name="secret3", doc="the third variable", default="value", max_len=10, forbidden_char=['$'], properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/00_6secret_param/rougail/00-base.yml'], 'type': 'secret'}) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_2, option_3]) diff --git a/tests/dictionaries/00_8calculation_information/tiramisu/base.py b/tests/dictionaries/00_8calculation_information/tiramisu/base.py index 71cd52fbe..5db290746 100644 --- a/tests/dictionaries/00_8calculation_information/tiramisu/base.py +++ b/tests/dictionaries/00_8calculation_information/tiramisu/base.py @@ -10,7 +10,7 @@ except: ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") -dict_env['default_rougail.variable'] = "{{test_information }}\n" +dict_env['default_rougail.variable'] = "{{ test_information }}\n" option_2 = StrOption(name="variable", doc="a variable", default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_rougail.variable"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(False), '__internal_files': ParamValue(['../rougail-tests/structures/00_8calculation_information/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("rougail.variable"), 'test_information': ParamInformation("test_information", None)})), properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/00_8calculation_information/rougail/00-base.yml'], 'type': 'string'}) optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_2], properties=frozenset({"standard"})) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1]) diff --git a/tests/dictionaries/00_8calculation_information/tiramisu/no_namespace.py b/tests/dictionaries/00_8calculation_information/tiramisu/no_namespace.py index e4a2f30fc..1697f9135 100644 --- a/tests/dictionaries/00_8calculation_information/tiramisu/no_namespace.py +++ b/tests/dictionaries/00_8calculation_information/tiramisu/no_namespace.py @@ -10,6 +10,6 @@ except: ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") -dict_env['default_variable'] = "{{test_information }}\n" +dict_env['default_variable'] = "{{ test_information }}\n" option_1 = StrOption(name="variable", doc="a variable", default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_variable"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(False), '__internal_files': ParamValue(['../rougail-tests/structures/00_8calculation_information/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("variable"), 'test_information': ParamInformation("test_information", None)})), properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/00_8calculation_information/rougail/00-base.yml'], 'type': 'string'}) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1]) diff --git a/tests/dictionaries/00_9default_calculation_information/informations.json b/tests/dictionaries/00_9default_calculation_information/informations.json deleted file mode 100644 index 388b2508d..000000000 --- a/tests/dictionaries/00_9default_calculation_information/informations.json +++ /dev/null @@ -1 +0,0 @@ -{"rougail.var": "value"} diff --git a/tests/dictionaries/00_9default_calculation_information_other_variable/informations.json b/tests/dictionaries/00_9default_calculation_information_other_variable/informations.json deleted file mode 100644 index 8922f27d2..000000000 --- a/tests/dictionaries/00_9default_calculation_information_other_variable/informations.json +++ /dev/null @@ -1 +0,0 @@ -{"rougail.var1": "value"} diff --git a/tests/dictionaries/00_9default_information_other_variable/informations.json b/tests/dictionaries/00_9default_information_other_variable/informations.json deleted file mode 100644 index 8922f27d2..000000000 --- a/tests/dictionaries/00_9default_information_other_variable/informations.json +++ /dev/null @@ -1 +0,0 @@ -{"rougail.var1": "value"} diff --git a/tests/dictionaries/04_1jinja_and_hidden/makedict/after.json b/tests/dictionaries/04_1jinja_and_hidden/makedict/after.json new file mode 100644 index 000000000..cb00f446b --- /dev/null +++ b/tests/dictionaries/04_1jinja_and_hidden/makedict/after.json @@ -0,0 +1,6 @@ +{ + "rougail.var1": { + "owner": "default", + "value": true + } +} diff --git a/tests/dictionaries/04_1jinja_and_hidden/makedict/base.json b/tests/dictionaries/04_1jinja_and_hidden/makedict/base.json new file mode 100644 index 000000000..2460cca58 --- /dev/null +++ b/tests/dictionaries/04_1jinja_and_hidden/makedict/base.json @@ -0,0 +1,3 @@ +{ + "rougail.var1": true +} diff --git a/tests/dictionaries/04_1jinja_and_hidden/makedict/before.json b/tests/dictionaries/04_1jinja_and_hidden/makedict/before.json new file mode 100644 index 000000000..cb00f446b --- /dev/null +++ b/tests/dictionaries/04_1jinja_and_hidden/makedict/before.json @@ -0,0 +1,6 @@ +{ + "rougail.var1": { + "owner": "default", + "value": true + } +} diff --git a/tests/dictionaries/04_1jinja_and_hidden/makedict/mandatory.json b/tests/dictionaries/04_1jinja_and_hidden/makedict/mandatory.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/tests/dictionaries/04_1jinja_and_hidden/makedict/mandatory.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/tests/dictionaries/04_1jinja_and_hidden/makedict/read_write.json b/tests/dictionaries/04_1jinja_and_hidden/makedict/read_write.json new file mode 100644 index 000000000..0967ef424 --- /dev/null +++ b/tests/dictionaries/04_1jinja_and_hidden/makedict/read_write.json @@ -0,0 +1 @@ +{} diff --git a/tests/dictionaries/04_1jinja_and_hidden/tiramisu/base.py b/tests/dictionaries/04_1jinja_and_hidden/tiramisu/base.py new file mode 100644 index 000000000..a79edde13 --- /dev/null +++ b/tests/dictionaries/04_1jinja_and_hidden/tiramisu/base.py @@ -0,0 +1,17 @@ +from tiramisu import * +from tiramisu.setting import ALLOWED_LEADER_PROPERTIES +from re import compile as re_compile +from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription +load_functions('../rougail-tests/funcs/test.py') +try: + groups.namespace +except: + groups.addgroup('namespace') +ALLOWED_LEADER_PROPERTIES.add("basic") +ALLOWED_LEADER_PROPERTIES.add("standard") +ALLOWED_LEADER_PROPERTIES.add("advanced") +dict_env['default_rougail.var1'] = "true" +option_2 = BoolOption(name="var1", doc="A first variable", default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_rougail.var1"), '__internal_type': ParamValue("boolean"), '__internal_multi': ParamValue(False), '__internal_files': ParamValue(['../rougail-tests/structures/04_1jinja_and_hidden/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("rougail.var1")})), properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/04_1jinja_and_hidden/rougail/00-base.yml'], 'type': 'boolean'}) +option_3 = StrOption(name="var2", doc="A second variable", properties=frozenset({"basic", "mandatory", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_2), 'prop': ParamValue("disabled"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['../rougail-tests/structures/04_1jinja_and_hidden/rougail/00-base.yml'], 'type': 'string'}) +optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_2, option_3], properties=frozenset({"basic"})) +option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1]) diff --git a/tests/dictionaries/04_1jinja_and_hidden/tiramisu/no_namespace.py b/tests/dictionaries/04_1jinja_and_hidden/tiramisu/no_namespace.py new file mode 100644 index 000000000..389d1ee1d --- /dev/null +++ b/tests/dictionaries/04_1jinja_and_hidden/tiramisu/no_namespace.py @@ -0,0 +1,16 @@ +from tiramisu import * +from tiramisu.setting import ALLOWED_LEADER_PROPERTIES +from re import compile as re_compile +from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription +load_functions('../rougail-tests/funcs/test.py') +try: + groups.namespace +except: + groups.addgroup('namespace') +ALLOWED_LEADER_PROPERTIES.add("basic") +ALLOWED_LEADER_PROPERTIES.add("standard") +ALLOWED_LEADER_PROPERTIES.add("advanced") +dict_env['default_var1'] = "true" +option_1 = BoolOption(name="var1", doc="A first variable", default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_var1"), '__internal_type': ParamValue("boolean"), '__internal_multi': ParamValue(False), '__internal_files': ParamValue(['../rougail-tests/structures/04_1jinja_and_hidden/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("var1")})), properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/04_1jinja_and_hidden/rougail/00-base.yml'], 'type': 'boolean'}) +option_2 = StrOption(name="var2", doc="A second variable", properties=frozenset({"basic", "mandatory", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['../rougail-tests/structures/04_1jinja_and_hidden/rougail/00-base.yml'], 'type': 'string'}) +option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_2]) diff --git a/tests/dictionaries/20_9default_information_parent/informations.json b/tests/dictionaries/20_9default_information_parent/informations.json deleted file mode 100644 index 3300fa6eb..000000000 --- a/tests/dictionaries/20_9default_information_parent/informations.json +++ /dev/null @@ -1 +0,0 @@ -{"rougail.family": "value"} diff --git a/tests/dictionaries/40_0leadership_reduce/tiramisu/base.py b/tests/dictionaries/40_0leadership_reduce/tiramisu/base.py index bd015a764..8573522ef 100644 --- a/tests/dictionaries/40_0leadership_reduce/tiramisu/base.py +++ b/tests/dictionaries/40_0leadership_reduce/tiramisu/base.py @@ -10,7 +10,7 @@ except: ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") -option_3 = StrOption(name="leader", doc="a leader", multi=True, default=["value_1", "value_2", "value_3"], properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/40_0leadership_reduce/rougail/00-base.yml'], 'type': 'string', 'test': ('val1', 'val2')}) +option_3 = StrOption(name="leader", doc="a leader", multi=True, default=["value_1", "value_2", "value_3"], properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/40_0leadership_reduce/rougail/00-base.yml'], 'type': 'string', 'examples': ('val1', 'val2')}) option_4 = StrOption(name="follower", doc="a follower", multi=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['../rougail-tests/structures/40_0leadership_reduce/rougail/00-base.yml'], 'type': 'string'}) optiondescription_2 = Leadership(name="leadership", doc="a leadership", children=[option_3, option_4], properties=frozenset({"basic"}), informations={'ymlfiles': ['../rougail-tests/structures/40_0leadership_reduce/rougail/00-base.yml']}) optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[optiondescription_2], properties=frozenset({"basic"})) diff --git a/tests/dictionaries/40_0leadership_reduce/tiramisu/no_namespace.py b/tests/dictionaries/40_0leadership_reduce/tiramisu/no_namespace.py index d762cdae6..dcbd5822d 100644 --- a/tests/dictionaries/40_0leadership_reduce/tiramisu/no_namespace.py +++ b/tests/dictionaries/40_0leadership_reduce/tiramisu/no_namespace.py @@ -10,7 +10,7 @@ except: ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") -option_2 = StrOption(name="leader", doc="a leader", multi=True, default=["value_1", "value_2", "value_3"], properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/40_0leadership_reduce/rougail/00-base.yml'], 'type': 'string', 'test': ('val1', 'val2')}) +option_2 = StrOption(name="leader", doc="a leader", multi=True, default=["value_1", "value_2", "value_3"], properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/40_0leadership_reduce/rougail/00-base.yml'], 'type': 'string', 'examples': ('val1', 'val2')}) option_3 = StrOption(name="follower", doc="a follower", multi=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['../rougail-tests/structures/40_0leadership_reduce/rougail/00-base.yml'], 'type': 'string'}) optiondescription_1 = Leadership(name="leadership", doc="a leadership", children=[option_2, option_3], properties=frozenset({"basic"}), informations={'ymlfiles': ['../rougail-tests/structures/40_0leadership_reduce/rougail/00-base.yml']}) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1]) diff --git a/tests/dictionaries/60_0family_dynamic_jinja_integer_empty2/makedict/after.json b/tests/dictionaries/60_0family_dynamic_jinja_integer_empty2/makedict/after.json new file mode 100644 index 000000000..1e7f5d7ff --- /dev/null +++ b/tests/dictionaries/60_0family_dynamic_jinja_integer_empty2/makedict/after.json @@ -0,0 +1,10 @@ +{ + "rougail.var": { + "owner": "default", + "value": [] + }, + "rougail.var2": { + "owner": "default", + "value": null + } +} diff --git a/tests/dictionaries/60_0family_dynamic_jinja_integer_empty2/makedict/base.json b/tests/dictionaries/60_0family_dynamic_jinja_integer_empty2/makedict/base.json new file mode 100644 index 000000000..cd9083c3d --- /dev/null +++ b/tests/dictionaries/60_0family_dynamic_jinja_integer_empty2/makedict/base.json @@ -0,0 +1,4 @@ +{ + "rougail.var": [], + "rougail.var2": null +} diff --git a/tests/dictionaries/60_0family_dynamic_jinja_integer_empty2/makedict/before.json b/tests/dictionaries/60_0family_dynamic_jinja_integer_empty2/makedict/before.json new file mode 100644 index 000000000..1e7f5d7ff --- /dev/null +++ b/tests/dictionaries/60_0family_dynamic_jinja_integer_empty2/makedict/before.json @@ -0,0 +1,10 @@ +{ + "rougail.var": { + "owner": "default", + "value": [] + }, + "rougail.var2": { + "owner": "default", + "value": null + } +} diff --git a/tests/dictionaries/60_0family_dynamic_jinja_integer_empty2/makedict/mandatory.json b/tests/dictionaries/60_0family_dynamic_jinja_integer_empty2/makedict/mandatory.json new file mode 100644 index 000000000..4fb69ce52 --- /dev/null +++ b/tests/dictionaries/60_0family_dynamic_jinja_integer_empty2/makedict/mandatory.json @@ -0,0 +1 @@ +["rougail.var2"] \ No newline at end of file diff --git a/tests/dictionaries/60_0family_dynamic_jinja_integer_empty2/makedict/read_write.json b/tests/dictionaries/60_0family_dynamic_jinja_integer_empty2/makedict/read_write.json new file mode 100644 index 000000000..cd9083c3d --- /dev/null +++ b/tests/dictionaries/60_0family_dynamic_jinja_integer_empty2/makedict/read_write.json @@ -0,0 +1,4 @@ +{ + "rougail.var": [], + "rougail.var2": null +} diff --git a/tests/dictionaries/60_0family_dynamic_jinja_integer_empty2/tiramisu/base.py b/tests/dictionaries/60_0family_dynamic_jinja_integer_empty2/tiramisu/base.py new file mode 100644 index 000000000..9488f004e --- /dev/null +++ b/tests/dictionaries/60_0family_dynamic_jinja_integer_empty2/tiramisu/base.py @@ -0,0 +1,19 @@ +from tiramisu import * +from tiramisu.setting import ALLOWED_LEADER_PROPERTIES +from re import compile as re_compile +from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription +load_functions('../rougail-tests/funcs/test.py') +try: + groups.namespace +except: + groups.addgroup('namespace') +ALLOWED_LEADER_PROPERTIES.add("basic") +ALLOWED_LEADER_PROPERTIES.add("standard") +ALLOWED_LEADER_PROPERTIES.add("advanced") +dict_env['default_rougail.var2'] = "{% if rougail.dyn1 is defined %}\n{{ rougail.dyn1.var }}\n{% endif %}\n" +option_2 = IntOption(name="var", doc="a suffix variable", multi=True, properties=frozenset({"standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_0family_dynamic_jinja_integer_empty2/rougail/00-base.yml'], 'type': 'integer', 'test': (1, 2)}) +option_4 = StrOption(name="var", doc="a variable inside dynamic family from \"{{ identifier }}\"", default="val", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_0family_dynamic_jinja_integer_empty2/rougail/00-base.yml'], 'type': 'string'}) +optiondescription_3 = ConvertDynOptionDescription(name="dyn{{ identifier }}", doc="a dynamic family", identifiers=Calculation(func['calc_value'], Params((ParamOption(option_2)))), children=[option_4], properties=frozenset({"standard"}), informations={'dynamic_variable': 'rougail.var', 'ymlfiles': ['../rougail-tests/structures/60_0family_dynamic_jinja_integer_empty2/rougail/00-base.yml']}) +option_5 = StrOption(name="var2", doc="a variable", default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_rougail.var2"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(False), '__internal_files': ParamValue(['../rougail-tests/structures/60_0family_dynamic_jinja_integer_empty2/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("rougail.var2"), 'rougail.dyn1.var': ParamDynOption(option_4, ["1"], optional=True, notraisepropertyerror=True)})), properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_0family_dynamic_jinja_integer_empty2/rougail/00-base.yml'], 'type': 'string'}) +optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_2, optiondescription_3, option_5], properties=frozenset({"standard"})) +option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1]) diff --git a/tests/dictionaries/60_5family_dynamic_calc_description/tiramisu/base.py b/tests/dictionaries/60_5family_dynamic_calc_description/tiramisu/base.py index 0f4636c54..674d7e3d4 100644 --- a/tests/dictionaries/60_5family_dynamic_calc_description/tiramisu/base.py +++ b/tests/dictionaries/60_5family_dynamic_calc_description/tiramisu/base.py @@ -10,9 +10,9 @@ except: ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") -option_3 = StrOption(name="var", doc="A dynamic variable for {{ identifier }}", properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_description/rougail/00-base.yml'], 'type': 'string'}) -optiondescription_2 = ConvertDynOptionDescription(name="dyn{{ identifier }}", doc="A dynamic famify for {{ identifier }}", identifiers=["val1", "val2"], children=[option_3], properties=frozenset({"basic"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_description/rougail/00-base.yml']}) -option_4 = StrOption(name="var1", doc="A new variable", properties=frozenset({"basic", "mandatory", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamDynOption(option_3, ["val1"]), 'prop': ParamValue("disabled"), 'when': ParamValue("val"), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_description/rougail/00-base.yml'], 'type': 'string'}) -option_5 = StrOption(name="var2", doc="A new variable", multi=True, default=Calculation(func['calc_value'], Params((ParamOption(option_3)), kwargs={'__internal_multi': ParamValue(True)})), properties=frozenset({"mandatory", "notunique", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_description/rougail/00-base.yml'], 'type': 'string'}) +option_3 = StrOption(name="var", doc="a dynamic variable for {{ identifier }}", properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_description/rougail/00-base.yml'], 'type': 'string'}) +optiondescription_2 = ConvertDynOptionDescription(name="dyn{{ identifier }}", doc="a dynamic famify for {{ identifier }}", identifiers=["val1", "val2"], children=[option_3], properties=frozenset({"basic"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_description/rougail/00-base.yml']}) +option_4 = StrOption(name="var1", doc="a new variable", properties=frozenset({"basic", "mandatory", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamDynOption(option_3, ["val1"]), 'prop': ParamValue("disabled"), 'when': ParamValue("val"), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_description/rougail/00-base.yml'], 'type': 'string'}) +option_5 = StrOption(name="var2", doc="a new variable", multi=True, default=Calculation(func['calc_value'], Params((ParamOption(option_3)), kwargs={'__internal_multi': ParamValue(True)})), properties=frozenset({"mandatory", "notunique", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_description/rougail/00-base.yml'], 'type': 'string'}) optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[optiondescription_2, option_4, option_5], properties=frozenset({"basic"})) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1]) diff --git a/tests/dictionaries/60_5family_dynamic_calc_description/tiramisu/no_namespace.py b/tests/dictionaries/60_5family_dynamic_calc_description/tiramisu/no_namespace.py index 4b6bd587e..b1a6c03fd 100644 --- a/tests/dictionaries/60_5family_dynamic_calc_description/tiramisu/no_namespace.py +++ b/tests/dictionaries/60_5family_dynamic_calc_description/tiramisu/no_namespace.py @@ -10,8 +10,8 @@ except: ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") -option_2 = StrOption(name="var", doc="A dynamic variable for {{ identifier }}", properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_description/rougail/00-base.yml'], 'type': 'string'}) -optiondescription_1 = ConvertDynOptionDescription(name="dyn{{ identifier }}", doc="A dynamic famify for {{ identifier }}", identifiers=["val1", "val2"], children=[option_2], properties=frozenset({"basic"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_description/rougail/00-base.yml']}) -option_3 = StrOption(name="var1", doc="A new variable", properties=frozenset({"basic", "mandatory", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamDynOption(option_2, ["val1"]), 'prop': ParamValue("disabled"), 'when': ParamValue("val"), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_description/rougail/00-base.yml'], 'type': 'string'}) -option_4 = StrOption(name="var2", doc="A new variable", multi=True, default=Calculation(func['calc_value'], Params((ParamOption(option_2)), kwargs={'__internal_multi': ParamValue(True)})), properties=frozenset({"mandatory", "notunique", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_description/rougail/00-base.yml'], 'type': 'string'}) +option_2 = StrOption(name="var", doc="a dynamic variable for {{ identifier }}", properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_description/rougail/00-base.yml'], 'type': 'string'}) +optiondescription_1 = ConvertDynOptionDescription(name="dyn{{ identifier }}", doc="a dynamic famify for {{ identifier }}", identifiers=["val1", "val2"], children=[option_2], properties=frozenset({"basic"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_description/rougail/00-base.yml']}) +option_3 = StrOption(name="var1", doc="a new variable", properties=frozenset({"basic", "mandatory", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamDynOption(option_2, ["val1"]), 'prop': ParamValue("disabled"), 'when': ParamValue("val"), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_description/rougail/00-base.yml'], 'type': 'string'}) +option_4 = StrOption(name="var2", doc="a new variable", multi=True, default=Calculation(func['calc_value'], Params((ParamOption(option_2)), kwargs={'__internal_multi': ParamValue(True)})), properties=frozenset({"mandatory", "notunique", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_description/rougail/00-base.yml'], 'type': 'string'}) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1, option_3, option_4]) diff --git a/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/makedict/after.json b/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/makedict/after.json index fec8f4dc2..ef75061d6 100644 --- a/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/makedict/after.json +++ b/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/makedict/after.json @@ -1,7 +1,9 @@ { "rougail.var1": { "owner": "default", - "value": [] + "value": [ + "val1" + ] }, "rougail.var2": { "owner": "default", diff --git a/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/makedict/base.json b/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/makedict/base.json index a20d18a3f..45b545c84 100644 --- a/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/makedict/base.json +++ b/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/makedict/base.json @@ -1,4 +1,6 @@ { - "rougail.var1": [], + "rougail.var1": [ + "val1" + ], "rougail.var2": null } diff --git a/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/makedict/before.json b/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/makedict/before.json index fec8f4dc2..ef75061d6 100644 --- a/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/makedict/before.json +++ b/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/makedict/before.json @@ -1,7 +1,9 @@ { "rougail.var1": { "owner": "default", - "value": [] + "value": [ + "val1" + ] }, "rougail.var2": { "owner": "default", diff --git a/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/makedict/read_write.json b/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/makedict/read_write.json index a20d18a3f..45b545c84 100644 --- a/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/makedict/read_write.json +++ b/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/makedict/read_write.json @@ -1,4 +1,6 @@ { - "rougail.var1": [], + "rougail.var1": [ + "val1" + ], "rougail.var2": null } diff --git a/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/tiramisu/base.py b/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/tiramisu/base.py index 7672fcf52..1b63aa8cb 100644 --- a/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/tiramisu/base.py +++ b/tests/dictionaries/60_5family_dynamic_calc_suffix_disabled2/tiramisu/base.py @@ -10,9 +10,9 @@ except: ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") -option_2 = StrOption(name="var1", doc="A suffix variable", multi=True, properties=frozenset({"standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_suffix_disabled2/rougail/00-base.yml'], 'type': 'string', 'test': ('val1', 'val2')}) +option_2 = StrOption(name="var1", doc="A suffix variable", multi=True, default=["val1"], default_multi="val1", properties=frozenset({"standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_suffix_disabled2/rougail/00-base.yml'], 'type': 'string', 'test': ('val1', 'val2')}) option_4 = StrOption(name="var", doc="A dynamic variable", properties=frozenset({"basic", "disabled", "mandatory"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_suffix_disabled2/rougail/00-base.yml'], 'type': 'string'}) optiondescription_3 = ConvertDynOptionDescription(name="dyn{{ identifier }}", doc="dyn{{ identifier }}", identifiers=Calculation(func['calc_value'], Params((ParamOption(option_2)))), children=[option_4], properties=frozenset({"basic"}), informations={'dynamic_variable': 'rougail.var1', 'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_suffix_disabled2/rougail/00-base.yml']}) -option_5 = StrOption(name="var2", doc="A variable calculated", default=Calculation(func['calc_value'], Params((ParamDynOption(option_4, ["val1"], optional=True)))), properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_suffix_disabled2/rougail/00-base.yml'], 'type': 'string'}) +option_5 = StrOption(name="var2", doc="A variable calculated", default=Calculation(func['calc_value'], Params((ParamDynOption(option_4, ["val1"], notraisepropertyerror=True)))), properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_calc_suffix_disabled2/rougail/00-base.yml'], 'type': 'string'}) optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_2, optiondescription_3, option_5], properties=frozenset({"basic"})) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1]) diff --git a/tests/dictionaries/60_5family_dynamic_unknown_suffix/tiramisu/base.py b/tests/dictionaries/60_5family_dynamic_unknown_suffix/tiramisu/base.py index 11482a5e3..b202ea52c 100644 --- a/tests/dictionaries/60_5family_dynamic_unknown_suffix/tiramisu/base.py +++ b/tests/dictionaries/60_5family_dynamic_unknown_suffix/tiramisu/base.py @@ -11,7 +11,7 @@ ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") dict_env['disabled_rougail.{{ identifier }}_dyn.var4'] = "{% if 'val4' not in __.var %}\nval4 is not a valid value\n{% endif %}\n" -option_2 = StrOption(name="var", doc="a suffix variable", multi=True, default=["val1", "val2"], default_multi="val1", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_unknown_suffix/rougail/00-base.yml'], 'type': 'string', 'test': ('val1', 'val2', 'val3', 'val4')}) +option_2 = StrOption(name="var", doc="a suffix variable", multi=True, default=["val1", "val2"], default_multi="val1", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_unknown_suffix/rougail/00-base.yml'], 'type': 'string', 'examples': ('val1', 'val2', 'val3', 'val4')}) option_4 = StrOption(name="var1", doc="a variable 1", default=Calculation(func['calc_value'], Params((ParamIdentifier()))), properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_unknown_suffix/rougail/00-base.yml'], 'type': 'string'}) option_5 = StrOption(name="var2", doc="a variable 2", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_unknown_suffix/rougail/00-base.yml'], 'type': 'string'}) option_6 = StrOption(name="var3", doc="a variable 3", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_5family_dynamic_unknown_suffix/rougail/00-base.yml'], 'type': 'string'}) diff --git a/tests/dictionaries/60_6family_dynamic_inside_identifier/makedict/after.json b/tests/dictionaries/60_6family_dynamic_inside_identifier/makedict/after.json new file mode 100644 index 000000000..e70d9e62d --- /dev/null +++ b/tests/dictionaries/60_6family_dynamic_inside_identifier/makedict/after.json @@ -0,0 +1,41 @@ +{ + "rougail.var": { + "owner": "default", + "value": [ + "val1", + "val2" + ] + }, + "rougail.val1_dyn.var1": { + "owner": "default", + "value": "val1" + }, + "rougail.val1_dyn.var2": { + "owner": "default", + "value": "val1" + }, + "rougail.val1_dyn.var3": { + "owner": "default", + "value": "val1" + }, + "rougail.val1_dyn.var4": { + "owner": "default", + "value": "val1" + }, + "rougail.val2_dyn.var1": { + "owner": "default", + "value": "val2" + }, + "rougail.val2_dyn.var2": { + "owner": "default", + "value": "val2" + }, + "rougail.val2_dyn.var3": { + "owner": "default", + "value": "val2" + }, + "rougail.val2_dyn.var4": { + "owner": "default", + "value": "val1" + } +} diff --git a/tests/dictionaries/60_6family_dynamic_inside_identifier/makedict/base.json b/tests/dictionaries/60_6family_dynamic_inside_identifier/makedict/base.json new file mode 100644 index 000000000..a34bde9c4 --- /dev/null +++ b/tests/dictionaries/60_6family_dynamic_inside_identifier/makedict/base.json @@ -0,0 +1,14 @@ +{ + "rougail.var": [ + "val1", + "val2" + ], + "rougail.val1_dyn.var1": "val1", + "rougail.val1_dyn.var2": "val1", + "rougail.val1_dyn.var3": "val1", + "rougail.val1_dyn.var4": "val1", + "rougail.val2_dyn.var1": "val2", + "rougail.val2_dyn.var2": "val2", + "rougail.val2_dyn.var3": "val2", + "rougail.val2_dyn.var4": "val1" +} diff --git a/tests/dictionaries/60_6family_dynamic_inside_identifier/makedict/before.json b/tests/dictionaries/60_6family_dynamic_inside_identifier/makedict/before.json new file mode 100644 index 000000000..e70d9e62d --- /dev/null +++ b/tests/dictionaries/60_6family_dynamic_inside_identifier/makedict/before.json @@ -0,0 +1,41 @@ +{ + "rougail.var": { + "owner": "default", + "value": [ + "val1", + "val2" + ] + }, + "rougail.val1_dyn.var1": { + "owner": "default", + "value": "val1" + }, + "rougail.val1_dyn.var2": { + "owner": "default", + "value": "val1" + }, + "rougail.val1_dyn.var3": { + "owner": "default", + "value": "val1" + }, + "rougail.val1_dyn.var4": { + "owner": "default", + "value": "val1" + }, + "rougail.val2_dyn.var1": { + "owner": "default", + "value": "val2" + }, + "rougail.val2_dyn.var2": { + "owner": "default", + "value": "val2" + }, + "rougail.val2_dyn.var3": { + "owner": "default", + "value": "val2" + }, + "rougail.val2_dyn.var4": { + "owner": "default", + "value": "val1" + } +} diff --git a/tests/dictionaries/60_6family_dynamic_inside_identifier/makedict/mandatory.json b/tests/dictionaries/60_6family_dynamic_inside_identifier/makedict/mandatory.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/tests/dictionaries/60_6family_dynamic_inside_identifier/makedict/mandatory.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/tests/dictionaries/60_6family_dynamic_inside_identifier/makedict/read_write.json b/tests/dictionaries/60_6family_dynamic_inside_identifier/makedict/read_write.json new file mode 100644 index 000000000..a34bde9c4 --- /dev/null +++ b/tests/dictionaries/60_6family_dynamic_inside_identifier/makedict/read_write.json @@ -0,0 +1,14 @@ +{ + "rougail.var": [ + "val1", + "val2" + ], + "rougail.val1_dyn.var1": "val1", + "rougail.val1_dyn.var2": "val1", + "rougail.val1_dyn.var3": "val1", + "rougail.val1_dyn.var4": "val1", + "rougail.val2_dyn.var1": "val2", + "rougail.val2_dyn.var2": "val2", + "rougail.val2_dyn.var3": "val2", + "rougail.val2_dyn.var4": "val1" +} diff --git a/tests/dictionaries/60_6family_dynamic_inside_identifier/tiramisu/base.py b/tests/dictionaries/60_6family_dynamic_inside_identifier/tiramisu/base.py new file mode 100644 index 000000000..9f1cfb3d7 --- /dev/null +++ b/tests/dictionaries/60_6family_dynamic_inside_identifier/tiramisu/base.py @@ -0,0 +1,20 @@ +from tiramisu import * +from tiramisu.setting import ALLOWED_LEADER_PROPERTIES +from re import compile as re_compile +from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription +load_functions('../rougail-tests/funcs/test.py') +try: + groups.namespace +except: + groups.addgroup('namespace') +ALLOWED_LEADER_PROPERTIES.add("basic") +ALLOWED_LEADER_PROPERTIES.add("standard") +ALLOWED_LEADER_PROPERTIES.add("advanced") +option_2 = StrOption(name="var", doc="a suffix variable", multi=True, default=["val1", "val2"], default_multi="val1", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_6family_dynamic_inside_identifier/rougail/00-base.yml'], 'type': 'string'}) +option_4 = StrOption(name="var1", doc="value is suffix for {{ identifier }}", default=Calculation(func['calc_value'], Params((ParamIdentifier()))), properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_6family_dynamic_inside_identifier/rougail/00-base.yml'], 'type': 'string'}) +option_5 = StrOption(name="var2", doc="value is first variable", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_6family_dynamic_inside_identifier/rougail/00-base.yml'], 'type': 'string'}) +option_6 = StrOption(name="var3", doc="value is relative first variable", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_6family_dynamic_inside_identifier/rougail/00-base.yml'], 'type': 'string'}) +option_7 = StrOption(name="var4", doc="value is first variable of val1", default=Calculation(func['calc_value'], Params((ParamDynOption(option_4, ["val1"])))), properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_6family_dynamic_inside_identifier/rougail/00-base.yml'], 'type': 'string'}) +optiondescription_3 = ConvertDynOptionDescription(name="{{ identifier }}_dyn", doc="a dynamic family", identifiers=Calculation(func['calc_value'], Params((ParamOption(option_2)))), children=[option_4, option_5, option_6, option_7], properties=frozenset({"standard"}), informations={'dynamic_variable': 'rougail.var', 'ymlfiles': ['../rougail-tests/structures/60_6family_dynamic_inside_identifier/rougail/00-base.yml']}) +optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_2, optiondescription_3], properties=frozenset({"standard"})) +option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1]) diff --git a/tests/dictionaries/60_6family_subdynamic_inside/makedict/after.json b/tests/dictionaries/60_6family_subdynamic_inside/makedict/after.json new file mode 100644 index 000000000..7959652c6 --- /dev/null +++ b/tests/dictionaries/60_6family_subdynamic_inside/makedict/after.json @@ -0,0 +1,53 @@ +{ + "rougail.var": { + "owner": "default", + "value": [ + "val1", + "val2" + ] + }, + "rougail.dynval1.dynval1.var1": { + "owner": "default", + "value": null + }, + "rougail.dynval1.dynval1.var2": { + "owner": "default", + "value": [ + null, + null + ] + }, + "rougail.dynval1.dynval2.var1": { + "owner": "default", + "value": null + }, + "rougail.dynval1.dynval2.var2": { + "owner": "default", + "value": [ + null, + null + ] + }, + "rougail.dynval2.dynval1.var1": { + "owner": "default", + "value": null + }, + "rougail.dynval2.dynval1.var2": { + "owner": "default", + "value": [ + null, + null + ] + }, + "rougail.dynval2.dynval2.var1": { + "owner": "default", + "value": null + }, + "rougail.dynval2.dynval2.var2": { + "owner": "default", + "value": [ + null, + null + ] + } +} diff --git a/tests/dictionaries/60_6family_subdynamic_inside/makedict/base.json b/tests/dictionaries/60_6family_subdynamic_inside/makedict/base.json new file mode 100644 index 000000000..08d073c3f --- /dev/null +++ b/tests/dictionaries/60_6family_subdynamic_inside/makedict/base.json @@ -0,0 +1,26 @@ +{ + "rougail.var": [ + "val1", + "val2" + ], + "rougail.dynval1.dynval1.var1": null, + "rougail.dynval1.dynval1.var2": [ + null, + null + ], + "rougail.dynval1.dynval2.var1": null, + "rougail.dynval1.dynval2.var2": [ + null, + null + ], + "rougail.dynval2.dynval1.var1": null, + "rougail.dynval2.dynval1.var2": [ + null, + null + ], + "rougail.dynval2.dynval2.var1": null, + "rougail.dynval2.dynval2.var2": [ + null, + null + ] +} diff --git a/tests/dictionaries/60_6family_subdynamic_inside/makedict/before.json b/tests/dictionaries/60_6family_subdynamic_inside/makedict/before.json new file mode 100644 index 000000000..7959652c6 --- /dev/null +++ b/tests/dictionaries/60_6family_subdynamic_inside/makedict/before.json @@ -0,0 +1,53 @@ +{ + "rougail.var": { + "owner": "default", + "value": [ + "val1", + "val2" + ] + }, + "rougail.dynval1.dynval1.var1": { + "owner": "default", + "value": null + }, + "rougail.dynval1.dynval1.var2": { + "owner": "default", + "value": [ + null, + null + ] + }, + "rougail.dynval1.dynval2.var1": { + "owner": "default", + "value": null + }, + "rougail.dynval1.dynval2.var2": { + "owner": "default", + "value": [ + null, + null + ] + }, + "rougail.dynval2.dynval1.var1": { + "owner": "default", + "value": null + }, + "rougail.dynval2.dynval1.var2": { + "owner": "default", + "value": [ + null, + null + ] + }, + "rougail.dynval2.dynval2.var1": { + "owner": "default", + "value": null + }, + "rougail.dynval2.dynval2.var2": { + "owner": "default", + "value": [ + null, + null + ] + } +} diff --git a/tests/dictionaries/60_6family_subdynamic_inside/makedict/mandatory.json b/tests/dictionaries/60_6family_subdynamic_inside/makedict/mandatory.json new file mode 100644 index 000000000..bd555488c --- /dev/null +++ b/tests/dictionaries/60_6family_subdynamic_inside/makedict/mandatory.json @@ -0,0 +1 @@ +["rougail.dynval1.dynval1.var1", "rougail.dynval1.dynval1.var2", "rougail.dynval1.dynval2.var1", "rougail.dynval1.dynval2.var2", "rougail.dynval2.dynval1.var1", "rougail.dynval2.dynval1.var2", "rougail.dynval2.dynval2.var1", "rougail.dynval2.dynval2.var2"] \ No newline at end of file diff --git a/tests/dictionaries/60_6family_subdynamic_inside/makedict/read_write.json b/tests/dictionaries/60_6family_subdynamic_inside/makedict/read_write.json new file mode 100644 index 000000000..08d073c3f --- /dev/null +++ b/tests/dictionaries/60_6family_subdynamic_inside/makedict/read_write.json @@ -0,0 +1,26 @@ +{ + "rougail.var": [ + "val1", + "val2" + ], + "rougail.dynval1.dynval1.var1": null, + "rougail.dynval1.dynval1.var2": [ + null, + null + ], + "rougail.dynval1.dynval2.var1": null, + "rougail.dynval1.dynval2.var2": [ + null, + null + ], + "rougail.dynval2.dynval1.var1": null, + "rougail.dynval2.dynval1.var2": [ + null, + null + ], + "rougail.dynval2.dynval2.var1": null, + "rougail.dynval2.dynval2.var2": [ + null, + null + ] +} diff --git a/tests/dictionaries/60_6family_subdynamic_inside/tiramisu/base.py b/tests/dictionaries/60_6family_subdynamic_inside/tiramisu/base.py new file mode 100644 index 000000000..92115629e --- /dev/null +++ b/tests/dictionaries/60_6family_subdynamic_inside/tiramisu/base.py @@ -0,0 +1,19 @@ +from tiramisu import * +from tiramisu.setting import ALLOWED_LEADER_PROPERTIES +from re import compile as re_compile +from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription +load_functions('../rougail-tests/funcs/test.py') +try: + groups.namespace +except: + groups.addgroup('namespace') +ALLOWED_LEADER_PROPERTIES.add("basic") +ALLOWED_LEADER_PROPERTIES.add("standard") +ALLOWED_LEADER_PROPERTIES.add("advanced") +option_2 = StrOption(name="var", doc="A suffix variable", multi=True, default=["val1", "val2"], default_multi="val1", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_6family_subdynamic_inside/rougail/00-base.yml'], 'type': 'string'}) +option_5 = StrOption(name="var1", doc="A dynamic variable", properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['../rougail-tests/structures/60_6family_subdynamic_inside/rougail/00-base.yml'], 'type': 'string'}) +option_6 = StrOption(name="var2", doc="A variable calculated", multi=True, default=Calculation(func['calc_value'], Params((ParamDynOption(option_5, ["val2", None])), kwargs={'__internal_multi': ParamValue(True)})), properties=frozenset({"mandatory", "notunique", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_6family_subdynamic_inside/rougail/00-base.yml'], 'type': 'string'}) +optiondescription_4 = ConvertDynOptionDescription(name="dyn{{ identifier }}", doc="dyn{{ identifier }}", identifiers=Calculation(func['calc_value'], Params((ParamOption(option_2)))), children=[option_5, option_6], properties=frozenset({"basic"}), informations={'dynamic_variable': 'rougail.var', 'ymlfiles': ['../rougail-tests/structures/60_6family_subdynamic_inside/rougail/00-base.yml']}) +optiondescription_3 = ConvertDynOptionDescription(name="dyn{{ identifier }}", doc="dyn{{ identifier }}", identifiers=Calculation(func['calc_value'], Params((ParamOption(option_2)))), children=[optiondescription_4], properties=frozenset({"basic"}), informations={'dynamic_variable': 'rougail.var', 'ymlfiles': ['../rougail-tests/structures/60_6family_subdynamic_inside/rougail/00-base.yml']}) +optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_2, optiondescription_3], properties=frozenset({"basic"})) +option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1]) diff --git a/tests/dictionaries/60_6family_subdynamic_inside/tiramisu/no_namespace.py b/tests/dictionaries/60_6family_subdynamic_inside/tiramisu/no_namespace.py new file mode 100644 index 000000000..2668e17e6 --- /dev/null +++ b/tests/dictionaries/60_6family_subdynamic_inside/tiramisu/no_namespace.py @@ -0,0 +1,18 @@ +from tiramisu import * +from tiramisu.setting import ALLOWED_LEADER_PROPERTIES +from re import compile as re_compile +from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription +load_functions('../rougail-tests/funcs/test.py') +try: + groups.namespace +except: + groups.addgroup('namespace') +ALLOWED_LEADER_PROPERTIES.add("basic") +ALLOWED_LEADER_PROPERTIES.add("standard") +ALLOWED_LEADER_PROPERTIES.add("advanced") +option_1 = StrOption(name="var", doc="A suffix variable", multi=True, default=["val1", "val2"], default_multi="val1", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_6family_subdynamic_inside/rougail/00-base.yml'], 'type': 'string'}) +option_4 = StrOption(name="var1", doc="A dynamic variable", properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['../rougail-tests/structures/60_6family_subdynamic_inside/rougail/00-base.yml'], 'type': 'string'}) +option_5 = StrOption(name="var2", doc="A variable calculated", multi=True, default=Calculation(func['calc_value'], Params((ParamDynOption(option_4, ["val2", None])), kwargs={'__internal_multi': ParamValue(True)})), properties=frozenset({"mandatory", "notunique", "standard"}), informations={'ymlfiles': ['../rougail-tests/structures/60_6family_subdynamic_inside/rougail/00-base.yml'], 'type': 'string'}) +optiondescription_3 = ConvertDynOptionDescription(name="dyn{{ identifier }}", doc="dyn{{ identifier }}", identifiers=Calculation(func['calc_value'], Params((ParamOption(option_1)))), children=[option_4, option_5], properties=frozenset({"basic"}), informations={'dynamic_variable': 'var', 'ymlfiles': ['../rougail-tests/structures/60_6family_subdynamic_inside/rougail/00-base.yml']}) +optiondescription_2 = ConvertDynOptionDescription(name="dyn{{ identifier }}", doc="dyn{{ identifier }}", identifiers=Calculation(func['calc_value'], Params((ParamOption(option_1)))), children=[optiondescription_3], properties=frozenset({"basic"}), informations={'dynamic_variable': 'var', 'ymlfiles': ['../rougail-tests/structures/60_6family_subdynamic_inside/rougail/00-base.yml']}) +option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, optiondescription_2]) diff --git a/tests/result_tutorial/081/tiramisu.py b/tests/result_tutorial/081/tiramisu.py index 7898e4df6..5c64fdd9a 100644 --- a/tests/result_tutorial/081/tiramisu.py +++ b/tests/result_tutorial/081/tiramisu.py @@ -14,12 +14,12 @@ option_4 = DomainnameOption(name="address", doc="Proxy address", type="domainnam option_5 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_3 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_4, option_5], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_6 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_8 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_9 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) -optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_11 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_12 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_8 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "force_default_on_freeze", "mandatory", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_9 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) +option_11 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_12 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_13 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) -optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) +optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_2 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_3, option_6, optiondescription_7, optiondescription_10], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, optiondescription_2]) diff --git a/tests/result_tutorial/082/tiramisu.py b/tests/result_tutorial/082/tiramisu.py new file mode 100644 index 000000000..7898e4df6 --- /dev/null +++ b/tests/result_tutorial/082/tiramisu.py @@ -0,0 +1,25 @@ +from tiramisu import * +from tiramisu.setting import ALLOWED_LEADER_PROPERTIES +from re import compile as re_compile +from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription +try: + groups.namespace +except: + groups.addgroup('namespace') +ALLOWED_LEADER_PROPERTIES.add("basic") +ALLOWED_LEADER_PROPERTIES.add("standard") +ALLOWED_LEADER_PROPERTIES.add("advanced") +option_1 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) +option_4 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_5 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +optiondescription_3 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_4, option_5], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) +option_6 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) +option_8 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_9 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) +option_11 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_12 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_13 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) +optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) +optiondescription_2 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_3, option_6, optiondescription_7, optiondescription_10], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) +option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, optiondescription_2]) diff --git a/tests/result_tutorial/083/tiramisu.py b/tests/result_tutorial/083/tiramisu.py new file mode 100644 index 000000000..155cdbbbd --- /dev/null +++ b/tests/result_tutorial/083/tiramisu.py @@ -0,0 +1,25 @@ +from tiramisu import * +from tiramisu.setting import ALLOWED_LEADER_PROPERTIES +from re import compile as re_compile +from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription +try: + groups.namespace +except: + groups.addgroup('namespace') +ALLOWED_LEADER_PROPERTIES.add("basic") +ALLOWED_LEADER_PROPERTIES.add("standard") +ALLOWED_LEADER_PROPERTIES.add("advanced") +option_1 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) +option_4 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_5 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +optiondescription_3 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_4, option_5], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) +option_6 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) +option_8 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_9 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) +option_11 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_12 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_13 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) +optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) +optiondescription_2 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_3, option_6, optiondescription_7, optiondescription_10], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) +option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, optiondescription_2]) diff --git a/tests/result_tutorial/090/tiramisu.py b/tests/result_tutorial/090/tiramisu.py index 60dc98b85..dcbfccb8a 100644 --- a/tests/result_tutorial/090/tiramisu.py +++ b/tests/result_tutorial/090/tiramisu.py @@ -10,15 +10,15 @@ ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") option_1 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_4 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_5 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_4 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_5 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_3 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_4, option_5], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_6 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_8 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_9 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_8 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_9 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_11 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_12 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_11 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_12 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_13 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_2 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_3, option_6, optiondescription_7, optiondescription_10], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/100/tiramisu.py b/tests/result_tutorial/100/tiramisu.py index 1dea95167..63292bea1 100644 --- a/tests/result_tutorial/100/tiramisu.py +++ b/tests/result_tutorial/100/tiramisu.py @@ -10,15 +10,15 @@ ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") option_1 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_4 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_5 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_4 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_5 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_3 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_4, option_5], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_6 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_8 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_9 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_8 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_9 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_11 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_12 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_11 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_12 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_13 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_2 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_3, option_6, optiondescription_7, optiondescription_10], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/101/tiramisu.py b/tests/result_tutorial/101/tiramisu.py index e0db566e3..e867f7dd2 100644 --- a/tests/result_tutorial/101/tiramisu.py +++ b/tests/result_tutorial/101/tiramisu.py @@ -10,15 +10,15 @@ ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") option_1 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_4 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_5 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_4 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_5 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_3 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_4, option_5], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_6 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_8 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_9 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_8 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_9 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_11 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_12 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_11 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_12 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_13 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_2 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_3, option_6, optiondescription_7, optiondescription_10], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/102/tiramisu.py b/tests/result_tutorial/102/tiramisu.py index c5b8b24db..b2eb363e6 100644 --- a/tests/result_tutorial/102/tiramisu.py +++ b/tests/result_tutorial/102/tiramisu.py @@ -10,15 +10,15 @@ ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") option_1 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_4 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_5 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_4 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_5 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_3 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_4, option_5], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_6 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_8 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_9 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_8 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_9 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_11 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_12 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_11 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_12 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_13 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_2 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_3, option_6, optiondescription_7, optiondescription_10], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/103/tiramisu.py b/tests/result_tutorial/103/tiramisu.py index 2b1725e71..8914a1e0e 100644 --- a/tests/result_tutorial/103/tiramisu.py +++ b/tests/result_tutorial/103/tiramisu.py @@ -10,15 +10,15 @@ ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") option_1 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_4 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_5 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_4 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_5 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_3 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_4, option_5], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_6 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_8 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_9 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_8 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_9 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_11 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_12 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_11 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_12 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_13 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_2 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_3, option_6, optiondescription_7, optiondescription_10], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/104/tiramisu.py b/tests/result_tutorial/104/tiramisu.py index cb19cf343..b1990e17e 100644 --- a/tests/result_tutorial/104/tiramisu.py +++ b/tests/result_tutorial/104/tiramisu.py @@ -10,15 +10,15 @@ ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") option_1 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_4 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_5 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_4 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_5 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_3 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_4, option_5], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_6 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_8 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_9 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_8 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_9 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_11 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_12 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_11 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_12 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_13 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_2 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_3, option_6, optiondescription_7, optiondescription_10], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/110/tiramisu.py b/tests/result_tutorial/110/tiramisu.py index 88d85fa48..5b72859a7 100644 --- a/tests/result_tutorial/110/tiramisu.py +++ b/tests/result_tutorial/110/tiramisu.py @@ -10,15 +10,15 @@ ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") option_1 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_4 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_5 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_4 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_5 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_3 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_4, option_5], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_6 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_8 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_9 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_8 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_9 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_11 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_12 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_11 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_12 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_13 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_2 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_3, option_6, optiondescription_7, optiondescription_10], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/111/tiramisu.py b/tests/result_tutorial/111/tiramisu.py index ca28e3454..d5e7154aa 100644 --- a/tests/result_tutorial/111/tiramisu.py +++ b/tests/result_tutorial/111/tiramisu.py @@ -10,15 +10,15 @@ ALLOWED_LEADER_PROPERTIES.add("basic") ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") option_1 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_4 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_5 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_4 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_5 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_3 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_4, option_5], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_6 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_8 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_9 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_8 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_9 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_11 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_12 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_11 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_12 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_13 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_2 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_3, option_6, optiondescription_7, optiondescription_10], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/112/tiramisu.py b/tests/result_tutorial/112/tiramisu.py index 89bddddd2..2e3f4d904 100644 --- a/tests/result_tutorial/112/tiramisu.py +++ b/tests/result_tutorial/112/tiramisu.py @@ -11,15 +11,15 @@ ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") dict_env['disabled_proxy_dns_socks5'] = "{{ _.proxy_mode != \"Manual proxy configuration\" or _.manual.socks_proxy.version == 'v4' }}" option_1 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_4 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_5 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_4 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_5 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_3 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_4, option_5], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_6 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_8 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_9 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_8 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_9 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_11 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_12 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_11 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_12 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_13 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_2 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_3, option_6, optiondescription_7, optiondescription_10], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/120/tiramisu.py b/tests/result_tutorial/120/tiramisu.py index e90418676..837a39cd6 100644 --- a/tests/result_tutorial/120/tiramisu.py +++ b/tests/result_tutorial/120/tiramisu.py @@ -11,15 +11,15 @@ ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") dict_env['disabled_proxy_dns_socks5'] = "{{ _.manual.socks_proxy.version is propertyerror or _.manual.socks_proxy.version == 'v4' }}" option_1 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_4 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_5 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_4 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_5 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_3 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_4, option_5], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_6 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_8 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_9 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_8 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_9 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_11 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_12 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_11 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_12 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_13 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_2 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_3, option_6, optiondescription_7, optiondescription_10], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/130/tiramisu.py b/tests/result_tutorial/130/tiramisu.py index 226829a43..3db62d42d 100644 --- a/tests/result_tutorial/130/tiramisu.py +++ b/tests/result_tutorial/130/tiramisu.py @@ -11,15 +11,15 @@ ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") dict_env['disabled_proxy_dns_socks5'] = "{{ _.manual.socks_proxy.version is propertyerror or _.manual.socks_proxy.version == 'v4' }}" option_1 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_4 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_5 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_4 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_5 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_3 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_4, option_5], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_6 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_8 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_9 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_8 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_9 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_11 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_12 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_11 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_12 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_13 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_2 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_3, option_6, optiondescription_7, optiondescription_10], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/140/tiramisu.py b/tests/result_tutorial/140/tiramisu.py index 055254147..996b6effe 100644 --- a/tests/result_tutorial/140/tiramisu.py +++ b/tests/result_tutorial/140/tiramisu.py @@ -11,15 +11,15 @@ ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") dict_env['disabled_proxy_dns_socks5'] = "{{ _.manual.socks_proxy.version is propertyerror or _.manual.socks_proxy.version == 'v4' }}" option_1 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_4 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_5 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_4 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_5 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_3 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_4, option_5], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_6 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_8 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_9 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_8 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_9 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_11 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_12 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_11 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_12 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_13 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_2 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_3, option_6, optiondescription_7, optiondescription_10], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/141/tiramisu.py b/tests/result_tutorial/141/tiramisu.py index 806531063..f721e21ba 100644 --- a/tests/result_tutorial/141/tiramisu.py +++ b/tests/result_tutorial/141/tiramisu.py @@ -11,15 +11,15 @@ ALLOWED_LEADER_PROPERTIES.add("standard") ALLOWED_LEADER_PROPERTIES.add("advanced") dict_env['disabled_proxy_dns_socks5'] = "{{ _.manual.socks_proxy.version is propertyerror or _.manual.socks_proxy.version == 'v4' }}" option_1 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_4 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_5 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_4 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_5 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_3 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_4, option_5], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_6 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_8 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_9 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_8 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_9 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_11 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_12 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_11 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_12 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_13 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_2 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_3, option_6, optiondescription_7, optiondescription_10], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/142/tiramisu.py b/tests/result_tutorial/142/tiramisu.py index 515b24962..04aaf5ffb 100644 --- a/tests/result_tutorial/142/tiramisu.py +++ b/tests/result_tutorial/142/tiramisu.py @@ -12,15 +12,15 @@ ALLOWED_LEADER_PROPERTIES.add("advanced") dict_env['disabled_proxy_dns_socks5'] = "{{ _.manual.socks_proxy.version is propertyerror or _.manual.socks_proxy.version == 'v4' }}" dict_env['disabled_dns_over_https.custom_dns_url'] = "{{ _.provider is propertyerror or _.provider != 'Custom' }}" option_1 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_4 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_5 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_4 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_5 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_3 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_4, option_5], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_6 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_8 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_9 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_8 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_9 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_11 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_12 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_11 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_12 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_13 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_2 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_3, option_6, optiondescription_7, optiondescription_10], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/150/tiramisu.py b/tests/result_tutorial/150/tiramisu.py index 78111a499..692d76df6 100644 --- a/tests/result_tutorial/150/tiramisu.py +++ b/tests/result_tutorial/150/tiramisu.py @@ -13,15 +13,15 @@ dict_env['disabled_proxy_dns_socks5'] = "{{ _.manual.socks_proxy.version is prop dict_env['validators_dns_over_https.custom_dns_url'] = "{{ _.custom_dns_url.startswith(\"http://\") }}" dict_env['disabled_dns_over_https.custom_dns_url'] = "{{ _.provider is propertyerror or _.provider != 'Custom' }}" option_1 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_4 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_5 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_4 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_5 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_3 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_4, option_5], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_6 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_8 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_9 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_8 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_9 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_7 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_8, option_9], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_6), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_11 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_12 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_11 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_4)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_12 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_13 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_10 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_11, option_12, option_13], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_2 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_3, option_6, optiondescription_7, optiondescription_10], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_1), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/160/tiramisu.py b/tests/result_tutorial/160/tiramisu.py index a0f44f4f1..21e8dce69 100644 --- a/tests/result_tutorial/160/tiramisu.py +++ b/tests/result_tutorial/160/tiramisu.py @@ -13,15 +13,15 @@ dict_env['disabled_firefox.proxy_dns_socks5'] = "{{ _.manual.socks_proxy.version dict_env['validators_firefox.dns_over_https.custom_dns_url'] = "{{ _.custom_dns_url.startswith(\"http://\") }}" dict_env['disabled_firefox.dns_over_https.custom_dns_url'] = "{{ _.provider is propertyerror or _.provider != 'Custom' }}" option_2 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_5 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_6 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_5 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_6 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_4 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_5, option_6], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_7 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_9 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_10 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_9 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_10 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_8 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_9, option_10], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_12 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_13 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_12 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_13 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_14 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_11 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_12, option_13, option_14], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_3 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_4, option_7, optiondescription_8, optiondescription_11], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_2), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/161/tiramisu.py b/tests/result_tutorial/161/tiramisu.py index 01308a605..fa7c880c7 100644 --- a/tests/result_tutorial/161/tiramisu.py +++ b/tests/result_tutorial/161/tiramisu.py @@ -13,15 +13,15 @@ dict_env['disabled_firefox.proxy_dns_socks5'] = "{{ _.manual.socks_proxy.version dict_env['validators_firefox.dns_over_https.custom_dns_url'] = "{{ _.custom_dns_url.startswith(\"http://\") }}" dict_env['disabled_firefox.dns_over_https.custom_dns_url'] = "{{ _.provider is propertyerror or _.provider != 'Custom' }}" option_2 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_5 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_6 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_5 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_6 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_4 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_5, option_6], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_7 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_9 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_10 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_9 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_10 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_8 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_9, option_10], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_12 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_13 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_12 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_13 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_14 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_11 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_12, option_13, option_14], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_3 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_4, option_7, optiondescription_8, optiondescription_11], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_2), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/170/tiramisu.py b/tests/result_tutorial/170/tiramisu.py index 3075d30ec..c6f893323 100644 --- a/tests/result_tutorial/170/tiramisu.py +++ b/tests/result_tutorial/170/tiramisu.py @@ -13,15 +13,15 @@ dict_env['disabled_firefox.proxy_dns_socks5'] = "{{ _.manual.socks_proxy.version dict_env['validators_firefox.dns_over_https.custom_dns_url'] = "{{ _.custom_dns_url.startswith(\"http://\") }}" dict_env['disabled_firefox.dns_over_https.custom_dns_url'] = "{{ _.provider is propertyerror or _.provider != 'Custom' }}" option_2 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_5 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_6 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_5 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_6 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_4 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_5, option_6], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_7 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_9 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_10 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_9 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_10 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_8 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_9, option_10], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_12 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_13 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_12 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_13 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_14 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_11 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_12, option_13, option_14], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_3 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_4, option_7, optiondescription_8, optiondescription_11], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_2), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/180/tiramisu.py b/tests/result_tutorial/180/tiramisu.py index fb677279b..4c8970c5d 100644 --- a/tests/result_tutorial/180/tiramisu.py +++ b/tests/result_tutorial/180/tiramisu.py @@ -18,15 +18,15 @@ dict_env['disabled_firefox.proxy_dns_socks5'] = "{{ _.manual.socks_proxy.version dict_env['validators_firefox.dns_over_https.custom_dns_url'] = "{{ _.custom_dns_url.startswith(\"http://\") }}" dict_env['disabled_firefox.dns_over_https.custom_dns_url'] = "{{ _.provider is propertyerror or _.provider != 'Custom' }}" option_2 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_5 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_6 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_5 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_6 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_4 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_5, option_6], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_7 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_9 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_10 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_9 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_10 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_8 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_9, option_10], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_12 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_13 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_12 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_13 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_14 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_11 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_12, option_13, option_14], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_3 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_4, option_7, optiondescription_8, optiondescription_11], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_2), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/181/tiramisu.py b/tests/result_tutorial/181/tiramisu.py index f1fce266a..e42f5a500 100644 --- a/tests/result_tutorial/181/tiramisu.py +++ b/tests/result_tutorial/181/tiramisu.py @@ -19,15 +19,15 @@ dict_env['validators_firefox.dns_over_https.custom_dns_url'] = "{{ _.custom_dns_ dict_env['disabled_firefox.dns_over_https.custom_dns_url'] = "{{ _.provider is propertyerror or _.provider != 'Custom' }}" dict_env['default_foxyproxy.proxies.color'] = "#{%- for i in range(6) -%}{{- '0123456789abcdef' | random -}}{%- endfor -%}" option_2 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_5 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_6 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_5 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_6 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_4 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_5, option_6], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_7 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_9 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_10 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_9 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_10 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_8 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_9, option_10], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_12 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_13 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_12 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_13 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_14 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_11 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_12, option_13, option_14], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_3 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_4, option_7, optiondescription_8, optiondescription_11], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_2), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/182/tiramisu.py b/tests/result_tutorial/182/tiramisu.py index f9b8f4938..fd56d7255 100644 --- a/tests/result_tutorial/182/tiramisu.py +++ b/tests/result_tutorial/182/tiramisu.py @@ -19,15 +19,15 @@ dict_env['validators_firefox.dns_over_https.custom_dns_url'] = "{{ _.custom_dns_ dict_env['disabled_firefox.dns_over_https.custom_dns_url'] = "{{ _.provider is propertyerror or _.provider != 'Custom' }}" dict_env['default_foxyproxy.proxies.color'] = "#{%- for i in range(6) -%}{{- '0123456789abcdef' | random -}}{%- endfor -%}" option_2 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_5 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_6 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_5 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_6 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_4 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_5, option_6], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_7 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_9 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_10 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_9 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_10 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_8 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_9, option_10], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_12 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_13 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_12 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_13 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_14 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_11 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_12, option_13, option_14], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_3 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_4, option_7, optiondescription_8, optiondescription_11], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_2), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/190/tiramisu.py b/tests/result_tutorial/190/tiramisu.py index 3ca6643f6..58476b1d9 100644 --- a/tests/result_tutorial/190/tiramisu.py +++ b/tests/result_tutorial/190/tiramisu.py @@ -19,15 +19,15 @@ dict_env['validators_firefox.dns_over_https.custom_dns_url'] = "{{ _.custom_dns_ dict_env['disabled_firefox.dns_over_https.custom_dns_url'] = "{{ _.provider is propertyerror or _.provider != 'Custom' }}" dict_env['default_foxyproxy.proxies.color'] = "#{%- for i in range(6) -%}{{- '0123456789abcdef' | random -}}{%- endfor -%}" option_2 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_5 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_6 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_5 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_6 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_4 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_5, option_6], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_7 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_9 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_10 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_9 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_10 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_8 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_9, option_10], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_12 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_13 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_12 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_13 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_14 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_11 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_12, option_13, option_14], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_3 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_4, option_7, optiondescription_8, optiondescription_11], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_2), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/200/tiramisu.py b/tests/result_tutorial/200/tiramisu.py index cc49d1815..faed4c8bd 100644 --- a/tests/result_tutorial/200/tiramisu.py +++ b/tests/result_tutorial/200/tiramisu.py @@ -22,15 +22,15 @@ dict_env['disabled_foxyproxy.proxies.address'] = "{{ _.type not in ['HTTP', 'HTT dict_env['disabled_foxyproxy.proxies.port'] = "{{ _.type not in ['HTTP', 'HTTPS/SSL', 'SOCKS4', 'SOCKS5'] }}" dict_env['disabled_foxyproxy.proxies.url'] = "{{ _.type not in ['PAC URL', 'WPAD'] }}" option_2 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_5 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_6 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_5 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_6 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_4 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_5, option_6], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_7 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_9 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_10 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_9 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_10 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_8 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_9, option_10], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_12 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_13 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_12 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_13 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_14 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_11 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_12, option_13, option_14], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_3 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_4, option_7, optiondescription_8, optiondescription_11], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_2), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/210/tiramisu.py b/tests/result_tutorial/210/tiramisu.py index 51bcdf39d..7c0a3bbcd 100644 --- a/tests/result_tutorial/210/tiramisu.py +++ b/tests/result_tutorial/210/tiramisu.py @@ -25,15 +25,15 @@ dict_env['mandatory_foxyproxy.proxies.username'] = "{% if _.password is not prop dict_env['disabled_foxyproxy.proxies.password'] = "{{ _.type not in ['HTTP', 'HTTPS/SSL', 'SOCKS4', 'SOCKS5'] }}" dict_env['disabled_foxyproxy.proxies.url'] = "{{ _.type not in ['PAC URL', 'WPAD'] }}" option_2 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_5 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_6 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_5 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_6 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_4 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_5, option_6], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_7 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_9 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_10 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_9 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_10 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_8 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_9, option_10], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_12 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_13 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_12 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_13 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_14 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_11 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_12, option_13, option_14], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_3 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_4, option_7, optiondescription_8, optiondescription_11], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_2), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/result_tutorial/211/tiramisu.py b/tests/result_tutorial/211/tiramisu.py index 51e6ab881..a6a365612 100644 --- a/tests/result_tutorial/211/tiramisu.py +++ b/tests/result_tutorial/211/tiramisu.py @@ -26,15 +26,15 @@ dict_env['disabled_foxyproxy.proxies.password'] = "{{ _.type not in ['HTTP', 'HT dict_env['frozen_foxyproxy.proxies.password'] = "{{ not _.username }}" dict_env['disabled_foxyproxy.proxies.url'] = "{{ _.type not in ['PAC URL', 'WPAD'] }}" option_2 = ChoiceOption(name="proxy_mode", doc="Configure Proxy Access to the Internet", values=("No proxy", "Auto-detect proxy settings for this network", "Use system proxy settings", "Manual proxy configuration", "Automatic proxy configuration URL"), default="No proxy", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/00-proxy.yml'], 'type': 'choice'}) -option_5 = DomainnameOption(name="address", doc="Proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) -option_6 = PortOption(name="port", doc="Proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) +option_5 = DomainnameOption(name="address", doc="HTTP proxy address", type="domainname", allow_ip=True, properties=frozenset({"basic", "mandatory"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'domainname'}) +option_6 = PortOption(name="port", doc="HTTP proxy port", default="8080", allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml'], 'type': 'port'}) optiondescription_4 = OptionDescription(name="http_proxy", doc="HTTP Proxy", children=[option_5, option_6], properties=frozenset({"basic"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/10-manual.yml']}) option_7 = BoolOption(name="use_for_https", doc="Also use this proxy for HTTPS", default=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'boolean'}) -option_9 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_10 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_9 = DomainnameOption(name="address", doc="HTTPS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_10 = PortOption(name="port", doc="HTTPS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"force_default_on_freeze", "mandatory", "standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("frozen"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) optiondescription_8 = OptionDescription(name="https_proxy", doc="HTTPS Proxy", children=[option_9, option_10], properties=frozenset({"standard", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_7), 'prop': ParamValue("hidden"), 'when': ParamValue(True), 'inverse': ParamValue(False)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) -option_12 = DomainnameOption(name="address", doc="Proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) -option_13 = PortOption(name="port", doc="Proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) +option_12 = DomainnameOption(name="address", doc="SOCKS proxy address", default=Calculation(func['calc_value'], Params((ParamOption(option_5)))), type="domainname", allow_ip=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'domainname'}) +option_13 = PortOption(name="port", doc="SOCKS proxy port", default=Calculation(func['calc_value'], Params((ParamOption(option_6)))), allow_private=True, properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'port'}) option_14 = ChoiceOption(name="version", doc="SOCKS host version used by proxy", values=("v4", "v5"), default="v5", properties=frozenset({"mandatory", "standard"}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/20-manual.yml'], 'type': 'choice'}) optiondescription_11 = OptionDescription(name="socks_proxy", doc="SOCKS Proxy", children=[option_12, option_13, option_14], properties=frozenset({"standard"}), informations={'ymlfiles': ['tutorial_tmp/types/00-type.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) optiondescription_3 = OptionDescription(name="manual", doc="Manual proxy configuration", children=[optiondescription_4, option_7, optiondescription_8, optiondescription_11], properties=frozenset({"basic", Calculation(func['variable_to_property'], Params((), kwargs={'value': ParamOption(option_2), 'prop': ParamValue("disabled"), 'when': ParamValue("Manual proxy configuration"), 'inverse': ParamValue(True)}), help_function=func['variable_to_property'])}), informations={'ymlfiles': ['tutorial_tmp/structural/firefox/10-manual.yml', 'tutorial_tmp/structural/firefox/20-manual.yml']}) diff --git a/tests/test_1_flattener.py b/tests/test_1_flattener.py index 7a67fd488..839b3fbb1 100644 --- a/tests/test_1_flattener.py +++ b/tests/test_1_flattener.py @@ -47,7 +47,7 @@ excludes = set([ ]) test_ok -= excludes test_raise -= excludes -# test_ok = ['01_6string_multi_length'] +# test_ok = ['00_9default_calculation_information'] #test_ok = [] # test_raise = ['80unknown_default_variable_inside_dynamic_family'] #test_raise = [] diff --git a/tests/test_2_makedict.py b/tests/test_2_makedict.py index c33ac3523..95cd3c5bd 100644 --- a/tests/test_2_makedict.py +++ b/tests/test_2_makedict.py @@ -12,6 +12,7 @@ from tiramisu.error import PropertiesOptionError dico_dirs = 'tests/dictionaries' +ori_dico_dirs = Path('../rougail-tests/structures') test_ok = set() @@ -31,7 +32,7 @@ excludes = set([]) # excludes = set(['60_5family_dynamic_variable_outside_sub_suffix']) test_ok -= excludes -# test_ok = ['01_6string_multi_length'] +# test_ok = ['60_5family_dynamic_calc_suffix_disabled2'] test_ok = list(test_ok) @@ -82,7 +83,8 @@ def launch_flattener(test_dir, makedict_read_write = join(makedict_dir, 'read_write.json') makedict_before = join(makedict_dir, 'before.json') makedict_after = join(makedict_dir, 'after.json') - informations_file = join(test_dir, 'informations.json') + informations_file = ori_dico_dirs / Path(test_dir).name / 'informations.json' +# informations_file = join(test_dir, 'informations.json') mandatory_file = Path(makedict_dir) / 'mandatory.json' modulepath = join(test_dir, 'tiramisu', filename + '.py') @@ -105,8 +107,8 @@ def launch_flattener(test_dir, config.property.read_only() config.property.remove('mandatory') config.information.set('info', 'value') - if isfile(informations_file): - with open(informations_file) as informations: + if informations_file.is_file(): + with informations_file.open() as informations: for key, value in load(informations).items(): if filename == 'base': config.option(key).information.set('test_information', value)