From f495945b87f1081fca5a0e6105075d63a91b7e1b Mon Sep 17 00:00:00 2001 From: Jesse Duffield Date: Wed, 28 Dec 2022 10:29:32 +1100 Subject: [PATCH] fix bug --- pkg/integration/components/view.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/integration/components/view.go b/pkg/integration/components/view.go index f809c3a4a..6386ebf3f 100644 --- a/pkg/integration/components/view.go +++ b/pkg/integration/components/view.go @@ -212,7 +212,7 @@ func (self *View) LineCount(expectedCount int) *View { // if the view has a single blank line (often the case) we want to treat that as having no lines if len(lines) == 1 && expectedCount == 1 { actual := strings.TrimSpace(self.getView().Buffer()) - return actual == "", fmt.Sprintf("unexpected number of lines in view. Expected %d, got 0", expectedCount) + return actual != "", "unexpected number of lines in view. Expected 1, got 0" } return len(lines) == expectedCount, fmt.Sprintf("unexpected number of lines in view. Expected %d, got %d", expectedCount, len(lines))