public void GivenIHaveTheStartTheThirdThread() { Variability varia = new Variability(); Thread thread2 = new Thread(new ParameterizedThreadStart(varia.ThirdThread)); thread2.Start("second"); thread2.Join(); varia.ThirdThread("main"); Thread.Sleep(10000); thread2.Abort(); }
public void GivenINameTheThread() { Thread.CurrentThread.Name = "main"; Variability varia = new Variability(); Thread thread2 = new Thread(new ParameterizedThreadStart(varia.ThirdThread)); thread2.Name = "seconds"; thread2.Start("second"); thread2.Join(); varia.ThirdThread("main"); Thread.Sleep(10000); thread2.Abort(); }