From b91a03314132bb1a45d48d6c361aac186f7e04dc Mon Sep 17 00:00:00 2001 From: actionless Date: Fri, 28 May 2021 00:04:25 +0200 Subject: [PATCH] test(menubar): don't try to cover deprecated methods (calling any of them will make the warning-check fail in tests) --- lib/menubar/utils.lua | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/menubar/utils.lua b/lib/menubar/utils.lua index 119ca2b4e..9c8f283fd 100644 --- a/lib/menubar/utils.lua +++ b/lib/menubar/utils.lua @@ -409,6 +409,8 @@ function utils.parse_dir(dir_path, callback) end) end +-- luacov: disable + function utils.compute_textbox_width(textbox, s) gdebug.deprecate("Use 'width, _ = textbox:get_preferred_size(s)' directly.", {deprecated_in=4}) s = screen[s or mouse.screen] @@ -421,6 +423,8 @@ function utils.compute_text_width(text, s, font) return w_textbox.get_markup_geometry(text, s, font)['width'] end +-- luacov: enable + return utils -- vim: filetype=lua:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:textwidth=80