private void startTest(object parameters) { // Deserialize the parameters again. TODO: Come up with a solution around having to do this. Simply casting did not work out. StartTestParameters testParams = JsonConvert.DeserializeObject <StartTestParameters>(parameters.ToString()); // Pass the parameters to the test coroutine. StartCoroutine(TestCoroutine(testParams)); }
IEnumerator TestCoroutine(StartTestParameters parameters) { // This test simply waits three seconds. It expects a resolver, but does not need one. yield return(new WaitForSeconds(parameters.i_testTime)); if (parameters.resolver != null) { ResolveMessage(parameters.resolver); } }