changeset 41907c7087fe in modules/account_es:default
details:
https://hg.tryton.org/modules/account_es?cmd=changeset&node=41907c7087fe
description:
Use boolean comparision for VAT List amounts
The number of decimals is diferent depending on the backend
issue10030
diffstat:
tests/scenario_reporting_cancelled_invoices.rst | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
diffs (36 lines):
diff -r d99557e3231b -r 41907c7087fe
tests/scenario_reporting_cancelled_invoices.rst
--- a/tests/scenario_reporting_cancelled_invoices.rst Thu Apr 29 11:22:23
2021 +0200
+++ b/tests/scenario_reporting_cancelled_invoices.rst Thu Apr 29 12:06:50
2021 +0200
@@ -128,8 +128,8 @@
>>> with config.set_context(vat_list_context):
... vat_list_records = VatList.find([])
>>> vat_list_record, = vat_list_records
- >>> vat_list_record.amount
- Decimal('0.0')
+ >>> vat_list_record.amount == Decimal(0)
+ True
>>> with config.set_context(vat_book_context):
... vat_book_records = VatBook.find([])
>>> len(vat_book_records)
@@ -149,8 +149,8 @@
>>> with config.set_context(vat_list_context):
... vat_list_records = VatList.find([])
>>> vat_list_record, = vat_list_records
- >>> vat_list_record.amount
- Decimal('242.0')
+ >>> vat_list_record.amount == Decimal('242.0')
+ True
>>> with config.set_context(vat_book_context):
... vat_book_records = VatBook.find([])
>>> len(vat_book_records)
@@ -164,8 +164,8 @@
>>> with config.set_context(vat_list_context):
... vat_list_records = VatList.find([])
>>> vat_list_record, = vat_list_records
- >>> vat_list_record.amount
- Decimal('0.0')
+ >>> vat_list_record.amount == Decimal(0)
+ True
>>> with config.set_context(vat_book_context):
... vat_book_records = VatBook.find([])
>>> len(vat_book_records)