From 8122b126cc29edad6f2d52cb58388f60be52f609 Mon Sep 17 00:00:00 2001 From: Ben Yu Date: Sun, 8 Oct 2023 20:57:08 -0700 Subject: [PATCH] parseOrThrow() --- mug/src/test/java/com/google/mu/util/StringFormatTest.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mug/src/test/java/com/google/mu/util/StringFormatTest.java b/mug/src/test/java/com/google/mu/util/StringFormatTest.java index cdfad8c6a4..a42be1006e 100644 --- a/mug/src/test/java/com/google/mu/util/StringFormatTest.java +++ b/mug/src/test/java/com/google/mu/util/StringFormatTest.java @@ -163,6 +163,8 @@ public void parse_withOneArgLambda_lambdaReturnsNull(@TestParameter Mode mode) { assertThrows( NullPointerException.class, () -> mode.formatOf("1 is {what}").parseOrThrow("1 is one", w -> null)); + assertThat(thrown).hasMessageThat().contains("format string '1 is {what}'"); + assertThat(thrown).hasMessageThat().contains("input '1 is one'"); } @Test