Ejemplo n.º 1
0
 def test_trigger_func_non_default_extension_schema(self):
     default_extension_schema = versioning_manager.options["extension_schema"]
     versioning_manager.options["extension_schema"] = "extension"
     trigger_func = str(CreateTriggerFunctionSQL.for_manager(versioning_manager, self.Article))
     assert "OPERATOR(extension.-)" in trigger_func
     assert "OPERATOR(extension.=)" in trigger_func
     assert trigger_func.count("extension.hstore(") == 3
     versioning_manager.options["extension_schema"] = default_extension_schema
Ejemplo n.º 2
0
 def test_trigger_func_non_default_extension_schema(self):
     default_extension_schema = versioning_manager.options[
         "extension_schema"]
     versioning_manager.options["extension_schema"] = "extension"
     trigger_func = str(
         CreateTriggerFunctionSQL.for_manager(versioning_manager,
                                              self.Article))
     assert "OPERATOR(extension.-)" in trigger_func
     assert "OPERATOR(extension.=)" in trigger_func
     assert trigger_func.count("extension.hstore(") == 3
     versioning_manager.options[
         "extension_schema"] = default_extension_schema
Ejemplo n.º 3
0
 def test_trigger_func_default_extension_schema(self):
     trigger_func = str(
         CreateTriggerFunctionSQL.for_manager(versioning_manager,
                                              self.Article))
     assert "OPERATOR(-)" in trigger_func
Ejemplo n.º 4
0
 def test_trigger_func_default_extension_schema(self):
     trigger_func = str(CreateTriggerFunctionSQL.for_manager(versioning_manager, self.Article))
     assert "OPERATOR(-)" in trigger_func