Search in sources :

Example 1 with DefaultStateMachineConfigDOTGenerator

use of org.killbill.automaton.dot.DefaultStateMachineConfigDOTGenerator in project killbill by killbill.

the class TestDefaultStateMachineConfigDOTGenerator method testStateMachine.

@Test(groups = "fast")
public void testStateMachine() throws Exception {
    final DefaultStateMachineConfig sms = XMLLoader.getObjectFromString(Resources.getResource("org/killbill/billing/payment/PaymentStates.xml").toExternalForm(), DefaultStateMachineConfig.class);
    final DefaultStateMachineConfigDOTGenerator generator = new DefaultStateMachineConfigDOTGenerator("Payment", sms);
    generator.build();
    System.out.println(generator.toString());
    System.out.flush();
//Files.write((new File("/var/tmp/PaymentStates.dot")).toPath(), generator.toString().getBytes());
}
Also used : DefaultStateMachineConfigDOTGenerator(org.killbill.automaton.dot.DefaultStateMachineConfigDOTGenerator) DefaultStateMachineConfig(org.killbill.automaton.DefaultStateMachineConfig) Test(org.testng.annotations.Test)

Aggregations

DefaultStateMachineConfig (org.killbill.automaton.DefaultStateMachineConfig)1 DefaultStateMachineConfigDOTGenerator (org.killbill.automaton.dot.DefaultStateMachineConfigDOTGenerator)1 Test (org.testng.annotations.Test)1