public void StateCount_IsZero_BeforeInitializeStateMachine() { // Arrange _parentGameObject = new GameObject("ParentGameObject"); BouncyBallModel bouncyBallModel = _parentGameObject.AddComponent <BouncyBallModel>(); // Act int stateCount = bouncyBallModel.StateMachine.States.Count; // Assert Assert.That(stateCount, Is.EqualTo(0)); }
public void StateCount_Is2_AfterInitializeStateMachine() { // Arrange _parentGameObject = new GameObject("ParentGameObject"); BouncyBallController bouncyBallController = _parentGameObject.AddComponent <BouncyBallController>(); BouncyBallModel bouncyBallModel = _parentGameObject.AddComponent <BouncyBallModel>(); // Act bouncyBallModel.InitializeStateMachine(bouncyBallController); int stateCount = bouncyBallModel.StateMachine.States.Count; // Assert Assert.That(stateCount, Is.EqualTo(2)); }