From e98a43fc67d108074f79ccba42e56653512adaad Mon Sep 17 00:00:00 2001 From: Nick Snyder Date: Mon, 17 Jun 2019 10:54:31 -0700 Subject: [PATCH] more test --- v2/i18n/localizer_test.go | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/v2/i18n/localizer_test.go b/v2/i18n/localizer_test.go index 718cdd77..7349cb3a 100644 --- a/v2/i18n/localizer_test.go +++ b/v2/i18n/localizer_test.go @@ -1,6 +1,7 @@ package i18n import ( + "fmt" "reflect" "testing" @@ -654,6 +655,14 @@ func TestMessageIDMismatchError(t *testing.T) { } } +func TestInvalidPluralCountError(t *testing.T) { + actual := (&invalidPluralCountErr{messageID: "hello", pluralCount: "blah", err: fmt.Errorf("error")}).Error() + expected := `invalid plural count "blah" for message id "hello": error` + if actual != expected { + t.Fatalf("expected %q; got %q", expected, actual) + } +} + func TestMustLocalize(t *testing.T) { defer func() { if recover() == nil {