public void CompanyAddressMaxPlusOne() { //create an instance of the class we want to create clsCompany ACompany = new clsCompany(); //boolean variable to store the result of the validation Boolean OK = false; //create soem test data to pass out to the method string CompanyAddress = "aaaaaaa";//this should be ok string CompanyEmailAddress = "*****@*****.**"; string InvolvedClient = "Callum Varle"; string InvolvedProject = "TNovationProject"; string MobileNumber = "654568"; string PhoneNumber = "5457496"; //invoke the method OK = ACompany.Valid(CompanyAddress, CompanyEmailAddress, InvolvedClient, InvolvedProject, MobileNumber, PhoneNumber); //test to see that the result is correct Assert.IsTrue(OK); }
public void ValidMethodOK() { //create an instance of the class we want to to create clsCompany ACompany = new clsCompany(); //boolean variable to store the result of the validation Boolean OK = false; //create some test data to pass the method string CompanyAddress = "13 Banner Street"; string CompanyEmailAddress = "*****@*****.**"; string InvolvedClient = "Callum Varle"; string InvolvedProject = "TNovationProject"; string MobileNumber = "654568"; string PhoneNumber = "5457496"; //invoke the method OK = ACompany.Valid(CompanyAddress, CompanyEmailAddress, InvolvedClient, InvolvedProject, MobileNumber, PhoneNumber); //test to see if the result is correct Assert.IsFalse (OK); }
public void CompanyEmailAddressExtremeMin() { //create an instance of the class we wnat to create clsCompany ACompany = new clsCompany(); //boolean variable to store the result of the validation Boolean OK = false; //create some test data to pass to the method string CompanyAddress = "32a"; string CompanyEmailAddress = "*****@*****.**"; string InvolvedClient = "Thomas"; string InvolvedProject = "sdas"; string MobileNumber = "354351568"; string PhoneNumber = "5656561"; //create a variable to store the test company email address data //DateTime TestDate; // set the string to you email CompanyEmailAddress = "myemail"; //change the date to variable to a string variable //TestDate = TestDate.AddYears(-100); //convert the date variable to a string variable //CompanyEmailAddress = TestDate.ToString(); //invoke the method OK = ACompany.Valid(CompanyAddress, CompanyEmailAddress, InvolvedClient, InvolvedProject, MobileNumber, PhoneNumber); //test to see that the result is correct Assert.IsTrue(OK); }