From aad7a74053e16611de04da4151e3e3be50746e3d Mon Sep 17 00:00:00 2001 From: TJ DeVries Date: Thu, 26 Mar 2020 14:24:04 -0400 Subject: vim.validate(): include stacktrace in message --- test/helpers.lua | 3 +++ 1 file changed, 3 insertions(+) (limited to 'test/helpers.lua') diff --git a/test/helpers.lua b/test/helpers.lua index 5acd2ea0bd..d59ce2a7c7 100644 --- a/test/helpers.lua +++ b/test/helpers.lua @@ -99,6 +99,9 @@ function module.matches(pat, actual) end error(string.format('Pattern does not match.\nPattern:\n%s\nActual:\n%s', pat, actual)) end +function module.contains(pat, actual) + return module.matches(".*" .. pat .. ".*", actual) +end --- Asserts that `pat` matches one or more lines in the tail of $NVIM_LOG_FILE. --- -- cgit