Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No hay tests que chequeen como parseamos observaciones #96

Open
WhyNotHugo opened this issue Aug 26, 2021 · 0 comments
Open

No hay tests que chequeen como parseamos observaciones #96

WhyNotHugo opened this issue Aug 26, 2021 · 0 comments

Comments

@WhyNotHugo
Copy link
Owner

El único tests acá está comentado:

@skip("Currently not working -- needs to get looked at.")
def test_validation_with_observations(self):
receipt = factories.ReceiptFactory(
document_number=20291144404,
document_type__code=80,
point_of_sales=models.PointOfSales.objects.first(),
receipt_type__code=1,
)
factories.VatFactory(vat_type__code=5, receipt=receipt)
factories.TaxFactory(tax_type__code=3, receipt=receipt)
errs = models.Receipt.objects.all().validate()
assert len(errs) == 0
assert receipt.validation.result == models.ReceiptValidation.RESULT_APPROVED
assert models.ReceiptValidation.objects.count() == 1
assert models.Observation.objects.count() == 1
assert receipt.validation.observations.count() == 1

Habría que buscar un caso que sepamos con certeza siempre devuelve observaciones, y crear un test de ese.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant