From fcd6e70a9c10bb97bff6a3bb7288bafafdcf0776 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Fri, 31 Jan 2014 00:03:29 +0100 Subject: [PATCH] Drop support of Python 2.6 review2691002 --- INSTALL | 2 +- setup.py | 1 - tests/scenario_carrier_weight.rst | 44 +++++++++++++++---------------- 3 files changed, 23 insertions(+), 24 deletions(-) diff --git a/INSTALL b/INSTALL index 34adbe8b01..4880a77c53 100644 --- a/INSTALL +++ b/INSTALL @@ -4,7 +4,7 @@ Installing trytond_carrier_weight Prerequisites ------------- - * Python 2.6 or later (http://www.python.org/) + * Python 2.7 or later (http://www.python.org/) * trytond (http://www.tryton.org/) * trytond_product (http://www.tryton.org/) * trytond_product_measurements (http://www.tryton.org/) diff --git a/setup.py b/setup.py index cf682f6952..61f8561184 100644 --- a/setup.py +++ b/setup.py @@ -65,7 +65,6 @@ setup(name='trytond_carrier_weight', 'Natural Language :: Slovenian', 'Natural Language :: Spanish', 'Operating System :: OS Independent', - 'Programming Language :: Python :: 2.6', 'Programming Language :: Python :: 2.7', 'Topic :: Office/Business', ], diff --git a/tests/scenario_carrier_weight.rst b/tests/scenario_carrier_weight.rst index 42411271bf..63348749ce 100644 --- a/tests/scenario_carrier_weight.rst +++ b/tests/scenario_carrier_weight.rst @@ -203,11 +203,11 @@ Receive a single product line:: >>> move.to_location = shipment.warehouse.input_location >>> move.product = product >>> move.quantity = 4 - >>> move.unit_price == Decimal(8) - True + >>> move.unit_price + Decimal('8') >>> shipment.carrier = carrier - >>> shipment.cost == Decimal(25) - True + >>> shipment.cost + Decimal('25') >>> shipment.cost_currency == currency True >>> shipment.save() @@ -216,8 +216,8 @@ Receive a single product line:: >>> shipment.state u'received' >>> move, = shipment.incoming_moves - >>> move.unit_price == Decimal('14.25') - True + >>> move.unit_price + Decimal('14.2500') Create payment term:: @@ -247,16 +247,16 @@ Sale products with cost on shipment:: True >>> cost_line.quantity == 1 True - >>> cost_line.amount == Decimal(40) - True + >>> cost_line.amount + Decimal('40.00') >>> sale.save() >>> Sale.quote([sale.id], config.context) >>> Sale.confirm([sale.id], config.context) >>> Sale.process([sale.id], config.context) >>> sale.state u'processing' - >>> sale.untaxed_amount == Decimal(140) - True + >>> sale.untaxed_amount + Decimal('140.00') Send products:: @@ -264,14 +264,14 @@ Send products:: >>> shipment, = sale.shipments >>> shipment.carrier == carrier True - >>> shipment.cost == Decimal(40) - True + >>> shipment.cost + Decimal('40') >>> shipment.cost_currency == currency True >>> move, = shipment.inventory_moves >>> move.quantity = 4 - >>> shipment.cost == Decimal(25) - True + >>> shipment.cost + Decimal('25') >>> shipment.cost_currency == currency True >>> shipment.state @@ -294,8 +294,8 @@ Check customer invoice:: >>> sale.reload() >>> invoice, = sale.invoices - >>> invoice.untaxed_amount == Decimal('105') - True + >>> invoice.untaxed_amount + Decimal('105.00') Sale products with cost on order:: @@ -314,16 +314,16 @@ Sale products with cost on order:: True >>> cost_line.quantity == 1 True - >>> cost_line.amount == Decimal(25) - True + >>> cost_line.amount + Decimal('25.00') >>> sale.save() >>> Sale.quote([sale.id], config.context) >>> Sale.confirm([sale.id], config.context) >>> Sale.process([sale.id], config.context) >>> sale.state u'processing' - >>> sale.untaxed_amount == Decimal(85) - True + >>> sale.untaxed_amount + Decimal('85.00') Check customer shipment:: @@ -335,5 +335,5 @@ Check customer invoice:: >>> sale.reload() >>> invoice, = sale.invoices - >>> invoice.untaxed_amount == Decimal(85) - True + >>> invoice.untaxed_amount + Decimal('85.00')