public void BeforeTest() { var dispatcher = new GameObject().AddComponent <TestUnityMessageEventDispatcherComponent>(); dispatcher.TestAwake(); dispatcher.gameObject.AddComponent <MockInputBinderComponent>(); dispatcher.gameObject.AddComponent <MockActionStateMachineComponent>(); var character = dispatcher.gameObject.AddComponent <TestCharacterComponent>(); character.ActiveController = new GameObject().AddComponent <TestControllerComponent>(); _postProcess = character.ActiveController.gameObject.AddComponent <MockCameraPostProcessingComponent>(); _effects = dispatcher.gameObject.AddComponent <TestPlayerEffectsComponent>(); _effects.TestStart(); // Make different so we can identify values _effects.FadeOutTime = _effects.FadeInTime + 1.0f; }
public void AfterTest() { _effects.TestDestroy(); _postProcess = null; }