Created
September 10, 2018 17:18
-
-
Save arifinfrds/bc3ebec5d2668032b914c820628756ed to your computer and use it in GitHub Desktop.
arifinfrds/iOS-XCUITestsDemo/XCUITestsDemo/LoginVC.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class LoginVC: UIViewController { | |
// MARK: - Outlets | |
@IBOutlet weak var usernameTextField: UITextField! | |
@IBOutlet weak var passwordTextField: UITextField! | |
// MARK: - View life cycle | |
override func viewDidLoad() { | |
super.viewDidLoad() | |
} | |
// MARK: - IBAction | |
@IBAction func didTapLoginButton() { | |
guard let username = usernameTextField.text, let password = passwordTextField.text else { | |
print("Input cannot be empty") | |
return | |
} | |
print("username: \(username)") | |
print("password: \(password)") | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment