| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent c9c67a8 commit ca3f65e
2 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -20,6 +20,7 @@ description = "credit and debit" | |||
| 20 | 20 | ||
| 21 | 21 | [502c4106-0371-4e7c-a7d8-9ce33f16ccb1] | |
| 22 | 22 | description = "multiple entries on same date ordered by description" | |
| 23 | + include = false | ||
| 23 | 24 | ||
| 24 | 25 | [29dd3659-6c2d-4380-94a8-6d96086e28e1] | |
| 25 | 26 | description = "final order tie breaker is change" | |
@@ -41,3 +42,7 @@ description = "Dutch negative number with 3 digits before decimal point" | |||
| 41 | 42 | ||
| 42 | 43 | [29670d1c-56be-492a-9c5e-427e4b766309] | |
| 43 | 44 | description = "American negative number with 3 digits before decimal point" | |
| 45 | + | ||
| 46 | + [9c70709f-cbbd-4b3b-b367-81d7c6101de4] | ||
| 47 | + description = "multiple entries on same date ordered by description" | ||
| 48 | + reimplements = "502c4106-0371-4e7c-a7d8-9ce33f16ccb1" | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,6 +1,6 @@ | |||
| 1 | 1 | # These tests are auto-generated with test data from: | |
| 2 | 2 | # https://github.com/exercism/problem-specifications/tree/main/exercises/ledger/canonical-data.json | |
| 3 | - # File last updated on 2023-07-19 | ||
| 3 | + # File last updated on 2023-12-27 | ||
| 4 | 4 | ||
| 5 | 5 | import unittest | |
| 6 | 6 | ||
@@ -54,22 +54,6 @@ def test_credit_and_debit(self): | |||
| 54 | 54 | ) | |
| 55 | 55 | self.assertEqual(format_entries(currency, locale, entries), expected) | |
| 56 | 56 | ||
| 57 | - def test_multiple_entries_on_same_date_ordered_by_description(self): | ||
| 58 | - currency = "USD" | ||
| 59 | - locale = "en_US" | ||
| 60 | - entries = [ | ||
| 61 | - create_entry("2015-01-02", "Get present", 1000), | ||
| 62 | - create_entry("2015-01-01", "Buy present", -1000), | ||
| 63 | - ] | ||
| 64 | - expected = "\n".join( | ||
| 65 | - [ | ||
| 66 | - "Date | Description | Change ", | ||
| 67 | - "01/01/2015 | Buy present | ($10.00)", | ||
| 68 | - "01/02/2015 | Get present | $10.00 ", | ||
| 69 | - ] | ||
| 70 | - ) | ||
| 71 | - self.assertEqual(format_entries(currency, locale, entries), expected) | ||
| 72 | - | ||
| 73 | 57 | def test_final_order_tie_breaker_is_change(self): | |
| 74 | 58 | currency = "USD" | |
| 75 | 59 | locale = "en_US" | |
@@ -171,3 +155,19 @@ def test_american_negative_number_with_3_digits_before_decimal_point(self): | |||
| 171 | 155 | ] | |
| 172 | 156 | ) | |
| 173 | 157 | self.assertEqual(format_entries(currency, locale, entries), expected) | |
| 158 | + | ||
| 159 | + def test_multiple_entries_on_same_date_ordered_by_description(self): | ||
| 160 | + currency = "USD" | ||
| 161 | + locale = "en_US" | ||
| 162 | + entries = [ | ||
| 163 | + create_entry("2015-01-01", "Get present", 1000), | ||
| 164 | + create_entry("2015-01-01", "Buy present", -1000), | ||
| 165 | + ] | ||
| 166 | + expected = "\n".join( | ||
| 167 | + [ | ||
| 168 | + "Date | Description | Change ", | ||
| 169 | + "01/01/2015 | Buy present | ($10.00)", | ||
| 170 | + "01/01/2015 | Get present | $10.00 ", | ||
| 171 | + ] | ||
| 172 | + ) | ||
| 173 | + self.assertEqual(format_entries(currency, locale, entries), expected) | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments