From 399349698b863119044aea28e3f7c4982c31ddbe Mon Sep 17 00:00:00 2001 From: wolf99 <281700+wolf99@users.noreply.github.com> Date: Wed, 30 Dec 2020 22:18:17 +0000 Subject: [PATCH 1/2] Hamming: remove tests that dont make sense --- exercises/hamming/canonical-data.json | 20 -------------------- 1 file changed, 20 deletions(-) diff --git a/exercises/hamming/canonical-data.json b/exercises/hamming/canonical-data.json index 5aa0560b63..373890b62b 100644 --- a/exercises/hamming/canonical-data.json +++ b/exercises/hamming/canonical-data.json @@ -79,26 +79,6 @@ "strand2": "AGTG" }, "expected": {"error": "left and right strands must be of equal length"} - }, - { - "uuid": "5dce058b-28d4-4ca7-aa64-adfe4e17784c", - "description": "disallow left empty strand", - "property": "distance", - "input": { - "strand1": "", - "strand2": "G" - }, - "expected": {"error": "left strand must not be empty"} - }, - { - "uuid": "38826d4b-16fb-4639-ac3e-ba027dec8b5f", - "description": "disallow right empty strand", - "property": "distance", - "input": { - "strand1": "G", - "strand2": "" - }, - "expected": {"error": "right strand must not be empty"} } ] } From 99f129d2f99b1d5f5454f7a3946cffc417ad26c1 Mon Sep 17 00:00:00 2001 From: wolf99 <281700+wolf99@users.noreply.github.com> Date: Thu, 31 Dec 2020 23:56:02 +0000 Subject: [PATCH 2/2] return tests & normalise error messages --- exercises/hamming/canonical-data.json | 44 +++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/exercises/hamming/canonical-data.json b/exercises/hamming/canonical-data.json index 373890b62b..b5c09b1f13 100644 --- a/exercises/hamming/canonical-data.json +++ b/exercises/hamming/canonical-data.json @@ -79,6 +79,50 @@ "strand2": "AGTG" }, "expected": {"error": "left and right strands must be of equal length"} + }, + { + "uuid": "5dce058b-28d4-4ca7-aa64-adfe4e17784c", + "description": "disallow left empty strand", + "property": "distance", + "input": { + "strand1": "", + "strand2": "G" + }, + "expected": {"error": "left strand must not be empty"} + }, + { + "uuid": "db92e77e-7c72-499d-8fe6-9354d2bfd504", + "description": "disallow left empty strand", + "comments": ["Normalises error messages"], + "reimplements": "5dce058b-28d4-4ca7-aa64-adfe4e17784c", + "property": "distance", + "input": { + "strand1": "", + "strand2": "G" + }, + "expected": {"error": "left and right strands must be of equal length"} + }, + { + "uuid": "38826d4b-16fb-4639-ac3e-ba027dec8b5f", + "description": "disallow right empty strand", + "property": "distance", + "input": { + "strand1": "G", + "strand2": "" + }, + "expected": {"error": "right strand must not be empty"} + }, + { + "uuid": "920cd6e3-18f4-4143-b6b8-74270bb8f8a3", + "description": "disallow right empty strand", + "comments": ["Normalises error messages"], + "reimplements": "38826d4b-16fb-4639-ac3e-ba027dec8b5f", + "property": "distance", + "input": { + "strand1": "G", + "strand2": "" + }, + "expected": {"error": "left and right strands must be of equal length"} } ] }