diff --git a/exercises/practice/resistor-color-trio/.meta/tests.toml b/exercises/practice/resistor-color-trio/.meta/tests.toml index 30211d5..b7d45fa 100644 --- a/exercises/practice/resistor-color-trio/.meta/tests.toml +++ b/exercises/practice/resistor-color-trio/.meta/tests.toml @@ -1,17 +1,40 @@ -[canonical-tests] +# This is an auto-generated file. +# +# Regenerating this file via `configlet sync` will: +# - Recreate every `description` key/value pair +# - Recreate every `reimplements` key/value pair, where they exist in problem-specifications +# - Remove any `include = true` key/value pair (an omitted `include` key implies inclusion) +# - Preserve any other key/value pair +# +# As user-added comments (using the # character) will be removed when this file +# is regenerated, comments can be added via a `comment` key. -# Orange and orange and black -"d6863355-15b7-40bb-abe0-bfb1a25512ed" = true +[d6863355-15b7-40bb-abe0-bfb1a25512ed] +description = "Orange and orange and black" -# Blue and grey and brown -"1224a3a9-8c8e-4032-843a-5224e04647d6" = true +[1224a3a9-8c8e-4032-843a-5224e04647d6] +description = "Blue and grey and brown" -# Red and black and red -"b8bda7dc-6b95-4539-abb2-2ad51d66a207" = true +[b8bda7dc-6b95-4539-abb2-2ad51d66a207] +description = "Red and black and red" -# Green and brown and orange -"5b1e74bc-d838-4eda-bbb3-eaba988e733b" = true +[5b1e74bc-d838-4eda-bbb3-eaba988e733b] +description = "Green and brown and orange" -# Yellow and violet and yellow -"f5d37ef9-1919-4719-a90d-a33c5a6934c9" = true +[f5d37ef9-1919-4719-a90d-a33c5a6934c9] +description = "Yellow and violet and yellow" +[5f6404a7-5bb3-4283-877d-3d39bcc33854] +description = "Blue and violet and blue" + +[7d3a6ab8-e40e-46c3-98b1-91639fff2344] +description = "Minimum possible value" + +[ca0aa0ac-3825-42de-9f07-dac68cc580fd] +description = "Maximum possible value" + +[0061a76c-903a-4714-8ce2-f26ce23b0e09] +description = "First two colors make an invalid octal number" + +[30872c92-f567-4b69-a105-8455611c10c4] +description = "Ignore extra colors" diff --git a/exercises/practice/resistor-color-trio/resistor-color-trio-test.red b/exercises/practice/resistor-color-trio/resistor-color-trio-test.red index 7d7e190..c8b0f2d 100644 --- a/exercises/practice/resistor-color-trio/resistor-color-trio-test.red +++ b/exercises/practice/resistor-color-trio/resistor-color-trio-test.red @@ -63,6 +63,61 @@ canonical-cases: [#( ) function: "label" uuid: "f5d37ef9-1919-4719-a90d-a33c5a6934c9" +) #( + description: "Blue and violet and blue" + input: #( + colors: ["blue" "violet" "blue"] + ) + expected: #( + value: 67 + unit: "megaohms" + ) + function: "label" + uuid: "5f6404a7-5bb3-4283-877d-3d39bcc33854" +) #( + description: "Minimum possible value" + input: #( + colors: ["black" "black" "black"] + ) + expected: #( + value: 0 + unit: "ohms" + ) + function: "label" + uuid: "7d3a6ab8-e40e-46c3-98b1-91639fff2344" +) #( + description: "Maximum possible value" + input: #( + colors: ["white" "white" "white"] + ) + expected: #( + value: 99 + unit: "gigaohms" + ) + function: "label" + uuid: "ca0aa0ac-3825-42de-9f07-dac68cc580fd" +) #( + description: "First two colors make an invalid octal number" + input: #( + colors: ["black" "grey" "black"] + ) + expected: #( + value: 8 + unit: "ohms" + ) + function: "label" + uuid: "0061a76c-903a-4714-8ce2-f26ce23b0e09" +) #( + description: "Ignore extra colors" + input: #( + colors: ["blue" "green" "yellow" "orange"] + ) + expected: #( + value: 650 + unit: "kiloohms" + ) + function: "label" + uuid: "872c92-f567-4b69-a105-8455611c10c4" )]