aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorÉamonn McManus <emcmanus@google.com>2022-10-24 17:47:38 -0700
committerGitHub <noreply@github.com>2022-10-24 17:47:38 -0700
commit4705518e12fe205b9c880b14fd15efa6aae4a5bd (patch)
treea3bb06ad851554396f45e63271b1a9e9a17e9dd9
parent7bca5c4061726164e8b68f2496118b7b5243eefe (diff)
downloadgson-4705518e12fe205b9c880b14fd15efa6aae4a5bd.tar.gz
Revise the version regex in `GsonVersionDiagnosticsTest`. (#2228)
Before we can release 2.10 we must support two-digit components. Additionally, there's no reason to require a patch number (2.10.0 rather than 2.10).
-rw-r--r--gson/src/test/java/com/google/gson/functional/GsonVersionDiagnosticsTest.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/gson/src/test/java/com/google/gson/functional/GsonVersionDiagnosticsTest.java b/gson/src/test/java/com/google/gson/functional/GsonVersionDiagnosticsTest.java
index aa6f4ccb..daa7aa48 100644
--- a/gson/src/test/java/com/google/gson/functional/GsonVersionDiagnosticsTest.java
+++ b/gson/src/test/java/com/google/gson/functional/GsonVersionDiagnosticsTest.java
@@ -35,7 +35,7 @@ import junit.framework.TestCase;
* @author Inderjeet Singh
*/
public class GsonVersionDiagnosticsTest extends TestCase {
- private static final Pattern GSON_VERSION_PATTERN = Pattern.compile("(\\(GSON \\d\\.\\d\\.\\d)(?:[-.][A-Z]+)?\\)$");
+ private static final Pattern GSON_VERSION_PATTERN = Pattern.compile("(\\(GSON \\d\\.\\d+(\\.\\d)?)(?:[-.][A-Z]+)?\\)$");
private Gson gson;