From 5abc03f89b85f5cdefb706177792fccd12bb5d05 Mon Sep 17 00:00:00 2001 From: Thijs Schreijer Date: Thu, 6 Dec 2018 06:21:59 +0100 Subject: [PATCH] add testcase for describe-level pending string only when a pending is added on describe level, without a function argument, it is never shown. --- spec/cl_pending.lua | 2 ++ spec/cl_spec.lua | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/spec/cl_pending.lua b/spec/cl_pending.lua index 00fa7255..5ca05c0b 100644 --- a/spec/cl_pending.lua +++ b/spec/cl_pending.lua @@ -12,5 +12,7 @@ describe('Tests the busted pending functions through the commandline', function( error('this should not run') end) end) + + pending('is a pending inside a describe, but without func argument') end) diff --git a/spec/cl_spec.lua b/spec/cl_spec.lua index 30e83040..28d3c043 100644 --- a/spec/cl_spec.lua +++ b/spec/cl_spec.lua @@ -546,8 +546,8 @@ describe('Tests pending through the commandline', function() local line1 = result:match('.-\n') local _, pendingDots = line1:gsub('%.', '') local _, numPending = result:gsub('Pending %-> .-\n', '') - assert.is_equal(2, pendingDots) - assert.is_equal(2, numPending) + assert.is_equal(3, pendingDots) + assert.is_equal(3, numPending) end) it('--suppress-pending option is honored', function()