public void TestJobConstructorSetsAllFields() { Assert.IsTrue(a.Name == "Product Tester"); Assert.AreEqual("Quality Control", a.JobType.ToString()); Assert.AreEqual(cc.ToString(), a.JobCoreCompetency.ToString()); Assert.AreEqual(a.EmployerLocation, desert); Assert.IsTrue(a.EmployerName.Value == "ACME"); }
public void TestJobConstructorSetsAllFields() { Employer ACME = new Employer("ACME"); Location Desert = new Location("Desert"); PositionType QualityControl = new PositionType("Quality Control"); CoreCompetency Persistence = new CoreCompetency("Persistence"); Job job1 = new Job("Product Tester", ACME, Desert, QualityControl, Persistence); Assert.AreEqual("Product Tester", job1.Name); Assert.AreEqual(Desert.ToString(), job1.EmployerLocation.ToString()); Assert.AreEqual(QualityControl.ToString(), job1.JobType.ToString()); Assert.AreEqual(Persistence.ToString(), job1.JobCoreCompetency.ToString()); }
public void TestJobConstructorSetsAllFields() { Job testJob1 = new Job("Product tester", new Employer("ACME") , new Location("Desert"), new PositionType("Quality control") , new CoreCompetency("Persistence")); string actualName = testJob1.Name; string expectedName = "Product tester"; Employer actualEmployer = testJob1.EmployerName; Employer expectedEmployer = new Employer("ACME"); Location actualLocation = testJob1.EmployerLocation; Location expectedLocation = new Location("Desert"); PositionType actualPositionType = testJob1.JobType; PositionType expectedPositionType = new PositionType("Quality control"); CoreCompetency actualCoreCompetency = testJob1.JobCoreCompetency; CoreCompetency expectedCoreCompetency = new CoreCompetency("Persistence"); Assert.AreEqual(expectedName, actualName); Assert.AreEqual(expectedEmployer.ToString(), actualEmployer.ToString()); Assert.AreEqual(expectedLocation.ToString(), actualLocation.ToString()); Assert.AreEqual(expectedPositionType.ToString(), actualPositionType.ToString()); Assert.AreEqual(expectedCoreCompetency.ToString(), actualCoreCompetency.ToString()); }