improved test for the importer
This commit is contained in:
@@ -47,11 +47,15 @@ public class ZF2ZInvoiceImporterTest extends TestCase {
|
|||||||
|
|
||||||
ZUGFeRDInvoiceImporter zii=new ZUGFeRDInvoiceImporter(TARGET_PDF);
|
ZUGFeRDInvoiceImporter zii=new ZUGFeRDInvoiceImporter(TARGET_PDF);
|
||||||
|
|
||||||
|
ZUGFeRD2PushProvider invoice=zii.extractInvoice();
|
||||||
// Reading ZUGFeRD
|
// Reading ZUGFeRD
|
||||||
assertEquals("Bei Spiel GmbH", zii.extractInvoice().getOwnOrganisationName());
|
assertEquals("Bei Spiel GmbH", invoice.getOwnOrganisationName());
|
||||||
assertEquals(3, zii.extractInvoice().getZFItems().length);
|
assertEquals(3, invoice.getZFItems().length);
|
||||||
assertEquals("160.0000", zii.extractInvoice().getZFItems()[0].getPrice().toString());
|
assertEquals("160.0000", invoice.getZFItems()[0].getPrice().toString());
|
||||||
|
assertEquals("400.0000", invoice.getZFItems()[1].getQuantity().toString());
|
||||||
|
assertEquals("Heiße Luft pro Liter", invoice.getZFItems()[2].getProduct().getName());
|
||||||
|
assertEquals("7", invoice.getZFItems()[0].getProduct().getVATPercent().toString());
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user