From b00a4fc56ea8f29429980d5f6658d369e198b920 Mon Sep 17 00:00:00 2001 From: Isaac Good Date: Mon, 24 Jun 2024 16:44:25 -0700 Subject: [PATCH] Sync new protein translation test case; sync docs and metadata --- exercises/practice/pig-latin/.docs/instructions.md | 4 ++-- exercises/practice/poker/.docs/instructions.md | 2 +- exercises/practice/protein-translation/.meta/tests.toml | 3 +++ .../practice/protein-translation/protein_translation.bats | 7 +++++++ .../practice/resistor-color-duo/.docs/instructions.md | 2 +- exercises/practice/yacht/.meta/config.json | 2 +- 6 files changed, 15 insertions(+), 5 deletions(-) diff --git a/exercises/practice/pig-latin/.docs/instructions.md b/exercises/practice/pig-latin/.docs/instructions.md index 6c843080..a9645ac2 100644 --- a/exercises/practice/pig-latin/.docs/instructions.md +++ b/exercises/practice/pig-latin/.docs/instructions.md @@ -19,7 +19,7 @@ For example: ## Rule 2 -If a word begins with a one or more consonants, first move those consonants to the end of the word and then add an `"ay"` sound to the end of the word. +If a word begins with one or more consonants, first move those consonants to the end of the word and then add an `"ay"` sound to the end of the word. For example: @@ -33,7 +33,7 @@ If a word starts with zero or more consonants followed by `"qu"`, first move tho For example: -- `"quick"` -> `"ickqu"` -> `"ay"` (starts with `"qu"`, no preceding consonants) +- `"quick"` -> `"ickqu"` -> `"ickquay"` (starts with `"qu"`, no preceding consonants) - `"square"` -> `"aresqu"` -> `"aresquay"` (starts with one consonant followed by `"qu`") ## Rule 4 diff --git a/exercises/practice/poker/.docs/instructions.md b/exercises/practice/poker/.docs/instructions.md index 492fc4c9..107cd49d 100644 --- a/exercises/practice/poker/.docs/instructions.md +++ b/exercises/practice/poker/.docs/instructions.md @@ -2,6 +2,6 @@ Pick the best hand(s) from a list of poker hands. -See [wikipedia][poker-hands] for an overview of poker hands. +See [Wikipedia][poker-hands] for an overview of poker hands. [poker-hands]: https://en.wikipedia.org/wiki/List_of_poker_hands diff --git a/exercises/practice/protein-translation/.meta/tests.toml b/exercises/practice/protein-translation/.meta/tests.toml index 5fb18907..e27a6b4f 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" diff --git a/exercises/practice/protein-translation/protein_translation.bats b/exercises/practice/protein-translation/protein_translation.bats index 49ee3ea7..a6ec167d 100644 --- a/exercises/practice/protein-translation/protein_translation.bats +++ b/exercises/practice/protein-translation/protein_translation.bats @@ -184,6 +184,13 @@ load bats-extra assert_output "Tryptophan Cysteine Tyrosine" } +@test "Sequence of two non-STOP codons does not translate to a STOP codon" { + [[ $BATS_RUN_SKIPPED == "true" ]] || skip + run bash protein_translation.sh "AUGAUG" + assert_success + assert_output "Methionine Methionine" +} + @test "Error case" { [[ $BATS_RUN_SKIPPED == "true" ]] || skip run bash protein_translation.sh "UGG---AUG" diff --git a/exercises/practice/resistor-color-duo/.docs/instructions.md b/exercises/practice/resistor-color-duo/.docs/instructions.md index bdcd549b..18ee4078 100644 --- a/exercises/practice/resistor-color-duo/.docs/instructions.md +++ b/exercises/practice/resistor-color-duo/.docs/instructions.md @@ -29,5 +29,5 @@ The band colors are encoded as follows: - White: 9 From the example above: -brown-green should return 15 +brown-green should return 15, and brown-green-violet should return 15 too, ignoring the third color. diff --git a/exercises/practice/yacht/.meta/config.json b/exercises/practice/yacht/.meta/config.json index 197de63b..7c277706 100644 --- a/exercises/practice/yacht/.meta/config.json +++ b/exercises/practice/yacht/.meta/config.json @@ -20,6 +20,6 @@ ] }, "blurb": "Score a single throw of dice in the game Yacht.", - "source": "James Kilfiger, using wikipedia", + "source": "James Kilfiger, using Wikipedia", "source_url": "https://en.wikipedia.org/wiki/Yacht_(dice_game)" }