From c83cfdfb26ff7ec0a0446b10dac0886c7b1e8211 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Wed, 21 Oct 2020 23:11:13 +0200 Subject: [PATCH] Convert read column into proper type with SQLite As SQLite has few basic types, we must use column names cast parsing to ensure to read values in proper type. issue9652 review310801004 --- tests/scenario_product_cost_history.rst | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/scenario_product_cost_history.rst b/tests/scenario_product_cost_history.rst index 6ee257184b..93a6120959 100644 --- a/tests/scenario_product_cost_history.rst +++ b/tests/scenario_product_cost_history.rst @@ -104,10 +104,10 @@ Check cost history:: >>> [c.cost_price for c in ProductCostHistory.find([], order=order)] == [ ... Decimal('100.0000'), Decimal('120.0000'), Decimal('110.0000')] True - >>> [str(c.date) for c in ProductCostHistory.find([], order=order)] == [ - ... str(today - dt.timedelta(days=2)), - ... str(today - dt.timedelta(days=1)), - ... str(today)] + >>> [c.date for c in ProductCostHistory.find([], order=order)] == [ + ... today - dt.timedelta(days=2), + ... today - dt.timedelta(days=1), + ... today] True Check cost price history on product::