office-alexander-logistics/office-alexander-logistics-app/src/test/java/com/alexanderlogistics/TestModelMatcher.java

33 lines
845 B
Java

package com.alexanderlogistics;
import static org.junit.jupiter.api.Assertions.assertFalse;
import static org.junit.jupiter.api.Assertions.assertTrue;
import org.imixs.workflow.ItemCollection;
import org.junit.jupiter.api.Test;
/**
* This test tests the InvoicePlugin isCargosoft method
*
* @author rsoika
*
*/
public class TestModelMatcher {
@Test
public void testModels() {
ItemCollection workitem = new ItemCollection();
workitem.setModelVersion("rechnungseingang-de-1.0");
assertTrue(InvoicePlugin.isCargoRechnung(workitem));
workitem.setModelVersion("rechnungseingang-pl-1.2");
assertTrue(InvoicePlugin.isCargoRechnung(workitem));
workitem.setModelVersion("rechnungseingang-sachrechnung-pl-1.2");
assertFalse(InvoicePlugin.isCargoRechnung(workitem));
}
}