
HOW TO WRITE A TEST CASE TO SET THE VALIDATION FOR LOGIN AND PASSWORD FIELD IN OBJECTIVE C, IOS.

@implementation LoginViewTests
- (void)testPasswordFieldIsNotEmpty {
LoginViewController *loginView = [[LoginViewController alloc] init];
//any other setup such as calling -viewDidLoad
STAssertTrue([loginView.passwordField.text length] > 0, @"The field should not be empty");
[loginView release]; //unless you're using ARC
}
@end

WHAT IS "STAssertTrue" ?
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.