From 534db3efc721e1a2ec7b67292321bd62b795f143 Mon Sep 17 00:00:00 2001 From: Badlop Date: Mon, 13 Jan 2025 00:00:40 +0100 Subject: [PATCH] fix test configuration: enable modules so ejabberd creates their sql tables and later those tables can be updated without errors by mod_admin_update_sql when ci.yml calls "make test" --- test/ejabberd_SUITE.erl | 6 ++++++ test/ejabberd_SUITE_data/ejabberd.pgsql.yml | 8 ++++++++ 2 files changed, 14 insertions(+) diff --git a/test/ejabberd_SUITE.erl b/test/ejabberd_SUITE.erl index ef94e67763c..452558aadbc 100644 --- a/test/ejabberd_SUITE.erl +++ b/test/ejabberd_SUITE.erl @@ -57,11 +57,17 @@ init_per_suite(Config) -> inet_db:set_domain(binary_to_list(p1_rand:get_string())), inet_db:set_lookup([file, native]), start_ejabberd(NewConfig), + stop_temporary_modules(NewConfig), NewConfig. start_ejabberd(_) -> {ok, _} = application:ensure_all_started(ejabberd, transient). +stop_temporary_modules(Config) -> + Host = ?config(server, Config), + Modules = [mod_shared_roster], + [gen_mod:stop_module(Host, M) || M <- Modules]. + end_per_suite(_Config) -> application:stop(ejabberd). diff --git a/test/ejabberd_SUITE_data/ejabberd.pgsql.yml b/test/ejabberd_SUITE_data/ejabberd.pgsql.yml index c0cd0b0d656..014e1c058cc 100644 --- a/test/ejabberd_SUITE_data/ejabberd.pgsql.yml +++ b/test/ejabberd_SUITE_data/ejabberd.pgsql.yml @@ -70,3 +70,11 @@ Welcome to this XMPP server." mod_stats: [] mod_time: [] mod_version: [] + mod_mix: + db_type: sql + mod_mix_pam: + db_type: sql + mod_mqtt: + db_type: sql + mod_shared_roster: + db_type: sql