From ecd04fb92b195c7afb5769a3f2659bd4d98b47f8 Mon Sep 17 00:00:00 2001 From: Raimon Esteve Date: Fri, 2 Feb 2018 13:22:53 +0100 Subject: [PATCH] Style register class --- __init__.py | 11 +++++------ tests/test_account_invoice_facturae.py | 14 +++----------- 2 files changed, 8 insertions(+), 17 deletions(-) diff --git a/__init__.py b/__init__.py index 04ec904..2928642 100644 --- a/__init__.py +++ b/__init__.py @@ -1,12 +1,11 @@ # The COPYRIGHT file at the top level of this repository contains the full # copyright notices and license terms. from trytond.pool import Pool - -import company -import invoice -import party -import payment_type -import account +from . import company +from . import invoice +from . import party +from . import payment_type +from . import account def register(): diff --git a/tests/test_account_invoice_facturae.py b/tests/test_account_invoice_facturae.py index b8c500a..d7eadea 100644 --- a/tests/test_account_invoice_facturae.py +++ b/tests/test_account_invoice_facturae.py @@ -4,13 +4,9 @@ import os.path import unittest from decimal import Decimal - import trytond.tests.test_tryton from trytond.pool import Pool from trytond.tests.test_tryton import ModuleTestCase, with_transaction -# from trytond.tests.test_tryton import doctest_setup, doctest_teardown -# from trytond.tests.test_tryton import doctest_checker - from trytond.modules.account.tests import get_fiscalyear from trytond.modules.account_es.tests import create_chart from trytond.modules.company.tests import create_company, set_company @@ -19,7 +15,7 @@ from trytond.modules.account_invoice.tests import set_invoice_sequences CURRENT_PATH = os.path.dirname(os.path.abspath(__file__)) -class TestCase(ModuleTestCase): +class TestAccountInvoiceFacturaeCase(ModuleTestCase): 'Test account_invoice_facturae module' module = 'account_invoice_facturae' @@ -161,10 +157,6 @@ class TestCase(ModuleTestCase): def suite(): suite = trytond.tests.test_tryton.suite() - suite.addTests(unittest.TestLoader().loadTestsFromTestCase(TestCase)) - # suite.addTests(doctest.DocFileSuite( - # 'scenario_account_invoice_facturae.rst', - # setUp=doctest_setup, tearDown=doctest_teardown, encoding='utf-8', - # checker=doctest_checker, - # optionflags=doctest.REPORT_ONLY_FIRST_FAILURE)) + suite.addTests(unittest.TestLoader().loadTestsFromTestCase( + TestAccountInvoiceFacturaeCase)) return suite