From 37ed8efaa355f2b66eb1784fbfc5cd89f983eae8 Mon Sep 17 00:00:00 2001 From: Russell Date: Sat, 24 Jun 2017 09:23:53 +0100 Subject: [PATCH 1/2] fix pangram test for duplicate mixed-case chars From what I can see, the last test case is inteded to catch incorrect programs such as this, which don't take into account different-cased duplicates: isPangram = (== 26) . length . nub . filter isAlpha However the above program passed the final test as the count of distinct upper and lower case characters is 27, rather than 26. This commit changes the test text to a non-pangram that has exactly 26 distinct upper and lower case characters, which causes the above, incorrect program to fail. --- exercises/pangram/package.yaml | 2 +- exercises/pangram/test/Tests.hs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/exercises/pangram/package.yaml b/exercises/pangram/package.yaml index 461fbb482..6d23d64aa 100644 --- a/exercises/pangram/package.yaml +++ b/exercises/pangram/package.yaml @@ -1,5 +1,5 @@ name: pangram -version: 1.0.0.2 +version: 1.0.0.3 dependencies: - base diff --git a/exercises/pangram/test/Tests.hs b/exercises/pangram/test/Tests.hs index 22834d454..630968db9 100644 --- a/exercises/pangram/test/Tests.hs +++ b/exercises/pangram/test/Tests.hs @@ -53,7 +53,7 @@ cases = [ Case { description = "sentence empty" , expected = True } , Case { description = "upper and lower case versions of the same character should not be counted separately" - , input = "the quick brown fox jumped over the lazy FOX" + , input = "the quick brown fox jumps over with lazy FX" , expected = False } ] From e64ff8df41bfdae2ca15259bdcdb300f8b1c9c53 Mon Sep 17 00:00:00 2001 From: Peter Tseng Date: Tue, 27 Jun 2017 18:17:39 -0700 Subject: [PATCH 2/2] it's 1.1.0.3 not 1.0.0.3 --- exercises/pangram/package.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/exercises/pangram/package.yaml b/exercises/pangram/package.yaml index 6d23d64aa..40da4a015 100644 --- a/exercises/pangram/package.yaml +++ b/exercises/pangram/package.yaml @@ -1,5 +1,5 @@ name: pangram -version: 1.0.0.3 +version: 1.1.0.3 dependencies: - base