From 599afcd69d452c7197da5a2a7ba79ae67ba27ee1 Mon Sep 17 00:00:00 2001 From: Eric Willigers Date: Fri, 14 Aug 2026 13:18:53 +1000 Subject: [PATCH] line-up: sync tests --- exercises/practice/line-up/.meta/tests.toml | 31 +++++++++++++++++++-- exercises/practice/line-up/run_test.v | 24 ++++++++++++++++ 2 files changed, 52 insertions(+), 3 deletions(-) diff --git a/exercises/practice/line-up/.meta/tests.toml b/exercises/practice/line-up/.meta/tests.toml index 12e9750..dd66fc1 100644 --- a/exercises/practice/line-up/.meta/tests.toml +++ b/exercises/practice/line-up/.meta/tests.toml @@ -1,6 +1,13 @@ -# This is an auto-generated file. Regular comments will be removed when this -# file is regenerated. Regenerating will not touch any manually added keys, -# so comments can be added in a "comment" key. +# 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. [7760d1b8-4864-4db4-953b-0fa7c047dbc0] description = "format smallest non-exceptional ordinal numeral 4" @@ -44,9 +51,24 @@ description = "format non-exceptional ordinal numeral 13" [2bdcebc5-c029-4874-b6cc-e9bec80d603a] description = "format exceptional ordinal numeral 21" +[a98e2e22-ab41-4557-a7c2-efedc19c16da] +description = "format exceptional ordinal numeral 22 ending in nd even though it is a multiple of 11" + +[ab45d2fb-e0ee-4016-b605-76917584db0a] +description = "format exceptional ordinal numeral 33 ending in rd even though it is a multiple of 11" + +[c9243603-9f17-45b3-9a41-db9ebdbf08e1] +description = "format exceptional ordinal numeral 52 ending in nd even though it is a multiple of 13" + [74ee2317-0295-49d2-baf0-d56bcefa14e3] description = "format exceptional ordinal numeral 62" +[3f6c408c-4331-42b6-bb6c-3ad0823e568a] +description = "format non-exceptional ordinal numeral 72 ending in nd even though it is a multiple of 12" + +[8db52cd9-9689-413f-a812-6c36fcfd0d07] +description = "format exceptional ordinal numeral 91 ending in st even though it is a multiple of 13" + [b37c332d-7f68-40e3-8503-e43cbd67a0c4] description = "format exceptional ordinal numeral 100" @@ -58,3 +80,6 @@ description = "format non-exceptional ordinal numeral 112" [06b62efe-199e-4ce7-970d-4bf73945713f] description = "format exceptional ordinal numeral 123" + +[6792c54e-59a7-4faf-839a-c4bb61014229] +description = "format large number 972 ending in nd even though it is a multiple of 12" diff --git a/exercises/practice/line-up/run_test.v b/exercises/practice/line-up/run_test.v index 0fb68ec..1de997e 100644 --- a/exercises/practice/line-up/run_test.v +++ b/exercises/practice/line-up/run_test.v @@ -56,10 +56,30 @@ fn test_format_exceptional_ordinal_numeral_21() { assert format('Washi', 21) == 'Washi, you are the 21st customer we serve today. Thank you!' } +fn test_format_exceptional_ordinal_numeral_22_ending_in_nd_even_though_it_is_a_multiple_of_11() { + assert format('Ingrid', 22) == 'Ingrid, you are the 22nd customer we serve today. Thank you!' +} + +fn test_format_exceptional_ordinal_numeral_33_ending_in_rd_even_though_it_is_a_multiple_of_11() { + assert format('Mario', 33) == 'Mario, you are the 33rd customer we serve today. Thank you!' +} + +fn test_format_exceptional_ordinal_numeral_52_ending_in_nd_even_though_it_is_a_multiple_of_13() { + assert format('Quentin', 52) == 'Quentin, you are the 52nd customer we serve today. Thank you!' +} + fn test_format_exceptional_ordinal_numeral_62() { assert format('Nayra', 62) == 'Nayra, you are the 62nd customer we serve today. Thank you!' } +fn test_format_non_exceptional_ordinal_numeral_72_ending_in_nd_even_though_it_is_a_multiple_of_12() { + assert format('Ugo', 72) == 'Ugo, you are the 72nd customer we serve today. Thank you!' +} + +fn test_format_exceptional_ordinal_numeral_91_ending_in_st_even_though_it_is_a_multiple_of_13() { + assert format('Boris', 91) == 'Boris, you are the 91st customer we serve today. Thank you!' +} + fn test_format_exceptional_ordinal_numeral_100() { assert format('John', 100) == 'John, you are the 100th customer we serve today. Thank you!' } @@ -75,3 +95,7 @@ fn test_format_non_exceptional_ordinal_numeral_112() { fn test_format_exceptional_ordinal_numeral_123() { assert format('Yma', 123) == 'Yma, you are the 123rd customer we serve today. Thank you!' } + +fn test_format_large_number_972_ending_in_nd_even_though_it_is_a_multiple_of_12() { + assert format('Elias', 972) == 'Elias, you are the 972nd customer we serve today. Thank you!' +}