From 98e762e5f72c32b286428de4b341da811076638c Mon Sep 17 00:00:00 2001 From: Uli Schlachter Date: Thu, 24 Aug 2017 22:53:27 +0200 Subject: [PATCH] fix(tests: menubar): ignore warning about opening applications dir in /dev/null --- tests/test-menubar.lua | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/test-menubar.lua b/tests/test-menubar.lua index 6c31c353..0eb5d43e 100644 --- a/tests/test-menubar.lua +++ b/tests/test-menubar.lua @@ -27,12 +27,12 @@ end -- word "error" appears in our output, the test is considered to have failed. do local gdebug = require("gears.debug") - local orig_error = gdebug.print_error - function gdebug.print_error(msg) + local orig_warning = gdebug.print_warning + function gdebug.print_warning(msg) msg = tostring(msg) - if (msg ~= "Error opening directory '/dev/null/.local/share/applications': Not a directory") and + if (not msg:match("/dev/null/.local/share/applications")) and (not msg:match("No such file or directory")) then - orig_error(msg) + orig_warning(msg) end end end