Ë
    H6kÿ	  ã                   ó:   — d Z ddlmZ ddlmZmZ  G d„ de«      Zy)zeExport SQL aux noms de tables de la production : seules les instructions de structure sont reecrites.é    )ÚSimpleTestCase)Úbuild_rewriterÚproduction_table_namesc                   ó*   — e Zd Zd„ Zd„ Zd„ Zd„ Zd„ Zy)ÚExportProductionRewriteTestsc                 ó*   — t        dddœ«      | _        y )NÚG_Erreur_actionÚG_Erreur_adresseip)Úg_erreur_actionÚg_erreur_adresseip)r   Úrewrite)Úselfs    úr/home/exaucensingi/Documents/ProjectPython/GBM_FacControl/faccontrol_acokin/facturation/tests_export_production.pyÚsetUpz"ExportProductionRewriteTests.setUp	   s   € Ü%Ø 1ÐI]Ñ^ó
ˆ�ó    c                 óº   — t        «       }| j                  |d   d«       | j                  |d   d«       | j                  |d   d«       | j                  d|«       y )Nr   r	   Úg_taux_regletauxÚG_taux_regletauxÚ2g_affectation_ligneoperationaffectation_transfertsÚ2G_Affectation_ligneoperationaffectation_transfertsÚfacturation_commande)r   ÚassertEqualÚassertNotIn)r   Úmappings     r   Ú+test_models_with_capital_letters_are_mappedzHExportProductionRewriteTests.test_models_with_capital_letters_are_mapped   se   € Ü(Ó*ˆØ×Ñ˜Ð!2Ñ3Ð5FÔGØ×Ñ˜Ð!3Ñ4Ð6HÔIØ×ÑØÐHÑIØ@ô	
ð 	×ÑÐ/°Õ9r   c                 óZ   — dD ]&  \  }}| j                  | j                  |«      |«       Œ( y )N))s(   DROP TABLE IF EXISTS `g_erreur_action`;
s(   DROP TABLE IF EXISTS `G_Erreur_action`;
)s!   CREATE TABLE `g_erreur_action` (
s!   CREATE TABLE `G_Erreur_action` (
)s%   LOCK TABLES `g_erreur_action` WRITE;
s%   LOCK TABLES `G_Erreur_action` WRITE;
)s8   /*!40000 ALTER TABLE `g_erreur_action` DISABLE KEYS */;
s8   /*!40000 ALTER TABLE `G_Erreur_action` DISABLE KEYS */;
)sR     CONSTRAINT `fk_ip` FOREIGN KEY (`ip_id`) REFERENCES `g_erreur_adresseip` (`id`)
sR     CONSTRAINT `fk_ip` FOREIGN KEY (`ip_id`) REFERENCES `G_Erreur_adresseip` (`id`)
©r   r   )r   ÚlineÚexpecteds      r   Ú1test_structure_statements_get_the_production_namezNExportProductionRewriteTests.test_structure_statements_get_the_production_name   s2   € ð
ò 	;‰NˆD�(ð ×Ñ˜TŸ\™\¨$Ó/°Õ:ñ	;r   c                 óJ   — d}| j                  | j                  |«      d«       y )NsO   INSERT INTO `g_erreur_action` VALUES (1,'voir `g_erreur_action` dans la doc');
sO   INSERT INTO `G_Erreur_action` VALUES (1,'voir `g_erreur_action` dans la doc');
r   ©r   r   s     r   Ú:test_insert_header_is_renamed_but_values_are_never_touchedzWExportProductionRewriteTests.test_insert_header_is_renamed_but_values_are_never_touched(   s$   € ØbˆØ×ÑØ�L‰L˜ÓØ_õ	
r   c                 óT   — dD ]#  }| j                  | j                  |«      |«       Œ% y )N)s&   CREATE TABLE `facturation_commande` (
s<     `libelle` varchar(50) NOT NULL DEFAULT 'g_erreur_action',
sC   INSERT INTO `facturation_commande` VALUES (1,'`g_erreur_action`');
r   r"   s     r   Ú0test_other_tables_and_plain_lines_are_left_alonezMExportProductionRewriteTests.test_other_tables_and_plain_lines_are_left_alone/   s.   € ð
ò 	7ˆDð
 ×Ñ˜TŸ\™\¨$Ó/°Õ6ñ	7r   N)Ú__name__Ú
__module__Ú__qualname__r   r   r    r#   r%   © r   r   r   r      s   „ ò
ò
:ò;ò 
ó7r   r   N)Ú__doc__Údjango.testr   Ú8facturation.management.commands.exporter_base_productionr   r   r   r)   r   r   ú<module>r-      s   ðÙ kå &ç kô-7 >õ -7r   