From 71565959ead37575ac7984e8b23bab97e18bc043 Mon Sep 17 00:00:00 2001 From: Kah Goh Date: Fri, 24 Apr 2026 20:50:42 +0800 Subject: [PATCH] Remove tests accidentally added by resync According to the tests.toml, the removed tests reimplement tests that were once excluded. It is likely that there were accidentally added back when the tests were updated to sync back up with the problem specs. Fixes #3107 --- .../largest-series-product/.meta/tests.toml | 2 ++ .../LargestSeriesProductCalculatorTest.java | 23 ------------------- 2 files changed, 2 insertions(+), 23 deletions(-) diff --git a/exercises/practice/largest-series-product/.meta/tests.toml b/exercises/practice/largest-series-product/.meta/tests.toml index 982f517cc..8da9250e0 100644 --- a/exercises/practice/largest-series-product/.meta/tests.toml +++ b/exercises/practice/largest-series-product/.meta/tests.toml @@ -58,6 +58,7 @@ include = false [6cf66098-a6af-4223-aab1-26aeeefc7402] description = "rejects empty string and nonzero span" +include = false reimplements = "6d96c691-4374-4404-80ee-2ea8f3613dd4" [7a38f2d6-3c35-45f6-8d6f-12e6e32d4d74] @@ -69,4 +70,5 @@ include = false [c859f34a-9bfe-4897-9c2f-6d7f8598e7f0] description = "rejects negative span" +include = false reimplements = "5fe3c0e5-a945-49f2-b584-f0814b4dd1ef" diff --git a/exercises/practice/largest-series-product/src/test/java/LargestSeriesProductCalculatorTest.java b/exercises/practice/largest-series-product/src/test/java/LargestSeriesProductCalculatorTest.java index 417878d1e..554eaa0fe 100644 --- a/exercises/practice/largest-series-product/src/test/java/LargestSeriesProductCalculatorTest.java +++ b/exercises/practice/largest-series-product/src/test/java/LargestSeriesProductCalculatorTest.java @@ -127,17 +127,6 @@ public void testSeriesLengthLongerThanLengthOfStringToTestIsRejected() { .withMessage("Series length must be less than or equal to the length of the string to search."); } - @Disabled("Remove to run test") - @Test - @DisplayName("rejects empty string and nonzero span") - public void testEmptyStringAndNonZeroSpanIsRejected() { - LargestSeriesProductCalculator calculator = new LargestSeriesProductCalculator(""); - - assertThatExceptionOfType(IllegalArgumentException.class) - .isThrownBy(() -> calculator.calculateLargestProductForSeriesLength(1)) - .withMessage("Series length must be less than or equal to the length of the string to search."); - } - @Disabled("Remove to run test") @Test @DisplayName("rejects invalid character in digits") @@ -147,17 +136,6 @@ public void testStringToSearchContainingNonDigitCharacterIsRejected() { .withMessage("String to search may only contain digits."); } - @Disabled("Remove to run test") - @Test - @DisplayName("rejects negative span") - public void testNegativeSeriesLengthIsRejected() { - LargestSeriesProductCalculator calculator = new LargestSeriesProductCalculator("12345"); - - assertThatExceptionOfType(IllegalArgumentException.class) - .isThrownBy(() -> calculator.calculateLargestProductForSeriesLength(-1)) - .withMessage("Series length must be non-negative."); - } - @Disabled("Remove to run test") @Test @DisplayName("integer overflow") @@ -169,5 +147,4 @@ public void testForIntegerOverflow() { assertThat(actualProduct).isEqualTo(expectedProduct); } - }