public void RemoveSubMachineWithIDFromLayerByObj() { Layer layer = stateMachine.AddLayer("newLayer"); stateMachine.AddSubStateMachine("newSubState", "newSubMachine"); Assert.IsTrue(stateMachine.HasSubStateMachine(SubStateMachineSelection.ID, "newSubState", layer)); stateMachine.RemoveSubStateMachine(SubStateMachineSelection.ID, "newSubState", layer); Assert.IsFalse(stateMachine.HasSubStateMachine(SubStateMachineSelection.ID, "newSubState", layer)); }
public void AddLayer3paramInListLocationWithInvalidIDLayerTest() { StateMachinePack.StateMachine stateMachine = new StateMachinePack.StateMachine(); Assert.ThrowsException <ArgumentException>(() => stateMachine.AddLayer("ALidaf?>?\\@!$!$#")); }
public void AddLayer2paramsNullIDLayerTest() { StateMachinePack.StateMachine stateMachine = new StateMachinePack.StateMachine(); Assert.ThrowsException <NullReferenceException>(() => stateMachine.AddLayer(null)); }
public void AddLayer2paramsDefaultWithSpacesLayerTest() { StateMachinePack.StateMachine stateMachine = new StateMachinePack.StateMachine(); Assert.ThrowsException <ArgumentException>(() => stateMachine.AddLayer(" DEFAULT ")); }
public void AddSubMachineToLayerByObjectWithIsLoopWithStateTransitionType_ReturnsSubMachine() { Layer layer = stateMachine.AddLayer(layerName); Assert.IsNotNull(stateMachine.AddSubStateMachine(iD, subMachineName, layer, true, StateTransitionType.Default)); }