public void Employee_Cindy_Hire() { Employee Cindy = new Taiwaneese("Cindy"); Cindy.Age = 20; Assert.AreEqual(Cindy.Hire(), true); }
public void Employee_Amy_Hire() { Employee Amy = new Taiwaneese("Amy"); Amy.Age = 30; Assert.AreEqual(Amy.Hire(), true); }
public void Employee_Cindy_Cannot_Hire() { Employee Cindy = new Taiwaneese("Cindy"); Cindy.Age = 19; Assert.AreEqual(Cindy.Hire(), false); }
public void Employee_Amy_Cannot_Hire() { Employee Amy = new Taiwaneese("Amy"); Amy.Age = 20; Assert.AreEqual(Amy.Hire(), false); }
static void Main(string[] args) { Employee Amy = new Taiwaneese("Amy"); Amy.Age = 20; Console.WriteLine("{0}來自 {2} 今年{1}歲", Amy.Name, Amy.Age, Amy.Nationailty); Console.WriteLine("我們可以雇用他嗎? {0}",Amy.Hire()); Console.WriteLine(" "); Employee Cindy = new Taiwaneese("Cindy"); Cindy.Age = 20; Console.WriteLine("{0}來自 {2} 今年{1}歲", Cindy.Name, Cindy.Age, Cindy.Nationailty); Console.WriteLine("我們可以雇用他嗎? {0}", Cindy.Hire()); Console.ReadLine(); }