test: Enable engine logging if test harness verbose flag is set

This commit is contained in:
Michael Gratton 2020-04-10 14:31:41 +10:00
parent c98efafb28
commit d84899e064
2 changed files with 12 additions and 0 deletions

View file

@ -39,6 +39,12 @@ int main(string[] args) {
Geary.RFC822.init();
Geary.HTML.init();
Geary.Logging.init();
if (GLib.Test.verbose()) {
Geary.Logging.enable_flags(ALL);
GLib.Log.set_writer_func(Geary.Logging.default_log_writer);
Geary.Logging.enable_flags(ALL);
Geary.Logging.log_to(GLib.stdout);
}
/*
* Hook up all tests into appropriate suites

View file

@ -22,6 +22,12 @@ int main(string[] args) {
Geary.RFC822.init();
Geary.HTML.init();
Geary.Logging.init();
if (GLib.Test.verbose()) {
Geary.Logging.enable_flags(ALL);
GLib.Log.set_writer_func(Geary.Logging.default_log_writer);
Geary.Logging.enable_flags(ALL);
Geary.Logging.log_to(GLib.stdout);
}
/*
* Hook up all tests into appropriate suites