public async Task ItDoesNotBlowUpWhenCancelingNonExistentTasks() { var taskQueue = TaskQueueTestFixture.UniqueRedisTaskQueue(); var taskScheduler = new TaskScheduler(taskQueue); (await taskScheduler.CancelTask("hello")).Should().BeFalse(); }
/// <summary> /// On Death event triggered by the Status Effect: Dead /// </summary> public virtual void OnDeath() { gameObject.GetComponent <Rigidbody>().isKinematic = true; gameObject.GetComponent <Collider>().enabled = false; gameObject.layer = LayerMask.NameToLayer("Ignore Raycast"); NavMeshAgent.enabled = false; TaskScheduler.CancelTask(); }