se mueve asignacion de ProfileID a objetos de factura

FossilOrigin-Name: 495e73349c8479f846c628397eea242912b982b83c4a294d8682b35c762f61f2
This commit is contained in:
bit4bit
2022-10-14 21:36:26 +00:00
parent b00eadb9e5
commit 2171da658a
5 changed files with 30 additions and 4 deletions

View File

@@ -33,7 +33,24 @@ def test_invoicesimple_build_with_cufe(simple_invoice):
cufe = xml.get_element_text('/fe:Invoice/cbc:UUID')
assert cufe != ''
def test_invoice_profile_id(simple_invoice):
xml = DIANInvoiceXML(simple_invoice)
cufe_extension = fe.DianXMLExtensionCUFE(simple_invoice)
xml.add_extension(cufe_extension)
assert xml.get_element_text('/fe:Invoice/cbc:ProfileID') == 'DIAN 2.1: Factura Electrónica de Venta'
def test_debit_note_profile_id(simple_invoice):
xml = DIANDebitNoteXML(simple_invoice)
cufe_extension = fe.DianXMLExtensionCUFE(simple_invoice)
xml.add_extension(cufe_extension)
assert xml.get_element_text('/fe:DebitNote/cbc:ProfileID') == 'DIAN 2.1 Nota Débito de Factura Electrónica de Venta'
def test_credit_note_profile_id(simple_invoice):
xml = DIANCreditNoteXML(simple_invoice)
cufe_extension = fe.DianXMLExtensionCUFE(simple_invoice)
xml.add_extension(cufe_extension)
assert xml.get_element_text('/fe:CreditNote/cbc:ProfileID') == 'DIAN 2.1: Nota Crédito de Factura Electrónica de Venta'
def test_invoicesimple_xml_signed(monkeypatch, simple_invoice):
xml = DIANInvoiceXML(simple_invoice)