diff --git a/exercises/practice/protein-translation/.meta/tests.toml b/exercises/practice/protein-translation/.meta/tests.toml index 804b446e..de680e39 100644 --- a/exercises/practice/protein-translation/.meta/tests.toml +++ b/exercises/practice/protein-translation/.meta/tests.toml @@ -87,6 +87,9 @@ description = "Translation stops if STOP codon in middle of three-codon sequence [2c2a2a60-401f-4a80-b977-e0715b23b93d] description = "Translation stops if STOP codon in middle of six-codon sequence" +[f6f92714-769f-4187-9524-e353e8a41a80] +description = "Sequence of two non-STOP codons does not translate to a STOP codon" + [1e75ea2a-f907-4994-ae5c-118632a1cb0f] description = "Non-existing codon can't translate" include = false diff --git a/exercises/practice/protein-translation/protein-translation-test.el b/exercises/practice/protein-translation/protein-translation-test.el index 60575dbb..3e435098 100644 --- a/exercises/practice/protein-translation/protein-translation-test.el +++ b/exercises/practice/protein-translation/protein-translation-test.el @@ -139,6 +139,11 @@ (proteins "UGGUGUUAUUAAUGGUUU")))) +(ert-deftest sequence-of-two-non-stop-codons-does-not-translate-to-a-stop-codon () + (should (equal '("Methionine" "Methionine") + (proteins "AUGAUG")))) + + (ert-deftest unknown-amino-acids-not-part-of-a-codon-cant-translate () (should-error (proteins "XYZ")))