diff --git a/modules/edocument_peppol_peppyrus/tests/scenario_edocument_peppol_peppyrus.rst b/modules/edocument_peppol_peppyrus/tests/scenario_edocument_peppol_peppyrus.rst index 4b7404d239..96877189ed 100644 --- a/modules/edocument_peppol_peppyrus/tests/scenario_edocument_peppol_peppyrus.rst +++ b/modules/edocument_peppol_peppyrus/tests/scenario_edocument_peppol_peppyrus.rst @@ -19,12 +19,13 @@ Patch Peppol:: >>> render = patch.object(Peppol, 'render').start() >>> participant_scheme, participant_id = ( ... os.getenv('PEPPYRUS_PARTICIPANT_ID').split(':', 1)) + >>> participant_vat = os.getenv('PEPPYRUS_PARTICIPANT_VAT') >>> with file_open('edocument_peppol_peppyrus/tests/invoice.xml', mode='r') as fp: ... render.return_value = ( ... fp.read() ... .replace('PARTICIPANT_SCHEME', participant_scheme) ... .replace('PARTICIPANT_ID', participant_id) - ... .replace('PARTICIPANT_VAT', participant_id.upper()) + ... .replace('PARTICIPANT_VAT', participant_vat.upper()) ... .encode()) Activate modules:: diff --git a/modules/edocument_peppol_peppyrus/tests/test_scenario.py b/modules/edocument_peppol_peppyrus/tests/test_scenario.py index b5be9b6307..92652b668e 100644 --- a/modules/edocument_peppol_peppyrus/tests/test_scenario.py +++ b/modules/edocument_peppol_peppyrus/tests/test_scenario.py @@ -9,7 +9,8 @@ from trytond.tests.test_tryton import TEST_NETWORK, load_doc_tests def load_tests(*args, **kwargs): if (not TEST_NETWORK or not (os.getenv('PEPPYRUS_API_KEY') - and os.getenv('PEPPYRUS_PARTICIPANT_ID'))): + and os.getenv('PEPPYRUS_PARTICIPANT_ID') + and os.getenv('PEPPYRUS_PARTICIPANT_VAT'))): kwargs.setdefault('skips', set()).update({ 'scenario_edocument_peppol_peppyrus.rst', })