Skip to content

Commit f0125e4

Browse files
authored
Updated wordy tests toml and regenerated test file. (exercism#3925)
1 parent 184bbc2 commit f0125e4

File tree

2 files changed

+35
-4
lines changed

2 files changed

+35
-4
lines changed

exercises/practice/wordy/.meta/tests.toml

Lines changed: 22 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,32 @@
1-
# This is an auto-generated file. Regular comments will be removed when this
2-
# file is regenerated. Regenerating will not touch any manually added keys,
3-
# so comments can be added in a "comment" key.
1+
# This is an auto-generated file.
2+
#
3+
# Regenerating this file via `configlet sync` will:
4+
# - Recreate every `description` key/value pair
5+
# - Recreate every `reimplements` key/value pair, where they exist in problem-specifications
6+
# - Remove any `include = true` key/value pair (an omitted `include` key implies inclusion)
7+
# - Preserve any other key/value pair
8+
#
9+
# As user-added comments (using the # character) will be removed when this file
10+
# is regenerated, comments can be added via a `comment` key.
411

512
[88bf4b28-0de3-4883-93c7-db1b14aa806e]
613
description = "just a number"
714

15+
[18983214-1dfc-4ebd-ac77-c110dde699ce]
16+
description = "just a zero"
17+
18+
[607c08ee-2241-4288-916d-dae5455c87e6]
19+
description = "just a negative number"
20+
821
[bb8c655c-cf42-4dfc-90e0-152fcfd8d4e0]
922
description = "addition"
1023

24+
[bb9f2082-171c-46ad-ad4e-c3f72087c1b5]
25+
description = "addition with a left hand zero"
26+
27+
[6fa05f17-405a-4742-80ae-5d1a8edb0d5d]
28+
description = "addition with a right hand zero"
29+
1130
[79e49e06-c5ae-40aa-a352-7a3a01f70015]
1231
description = "more addition"
1332

exercises/practice/wordy/wordy_test.py

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# These tests are auto-generated with test data from:
22
# https://github.com/exercism/problem-specifications/tree/main/exercises/wordy/canonical-data.json
3-
# File last updated on 2025-02-15
3+
# File last updated on 2025-06-20
44

55
import unittest
66

@@ -13,9 +13,21 @@ class WordyTest(unittest.TestCase):
1313
def test_just_a_number(self):
1414
self.assertEqual(answer("What is 5?"), 5)
1515

16+
def test_just_a_zero(self):
17+
self.assertEqual(answer("What is 0?"), 0)
18+
19+
def test_just_a_negative_number(self):
20+
self.assertEqual(answer("What is -123?"), -123)
21+
1622
def test_addition(self):
1723
self.assertEqual(answer("What is 1 plus 1?"), 2)
1824

25+
def test_addition_with_a_left_hand_zero(self):
26+
self.assertEqual(answer("What is 0 plus 2?"), 2)
27+
28+
def test_addition_with_a_right_hand_zero(self):
29+
self.assertEqual(answer("What is 3 plus 0?"), 3)
30+
1931
def test_more_addition(self):
2032
self.assertEqual(answer("What is 53 plus 2?"), 55)
2133

0 commit comments

Comments
 (0)