iOS UI Testing vs Integration Testing

General Tech QA/Testing 2 years ago

0 2 0 0 0 tuteeHUB earn credit +10 pts

5 Star Rating 1 Rating

Posted on 16 Aug 2022, this text provides information on QA/Testing related to General Tech. Please note that while accuracy is prioritized, the data presented might not be entirely correct or up-to-date. This information is offered for general knowledge and informational purposes only, and should not be considered as a substitute for professional advice.

Take Quiz To Earn Credits!

Turn Your Knowledge into Earnings.

tuteehub_quiz

Answers (2)

Post Answer
profilepic.png
manpreet Tuteehub forum best answer Best Answer 2 years ago

 

So I've been trying to read about UI and Integration testing (specifically for iOS development). I always though these tests were different, but a lot of the integration tests example I see, appear to be what I would call UI testing.

So now I'm curious, what is the difference between UI and integration testing? Could you please give examples?

profilepic.png
manpreet 2 years ago

 

UI and Integration testing are fairly different concepts. UI Testing is testing the UI specifically, such as "When I press the login button, the credentials are validated and the page transitions to the home page". While an integration test is to evaluate how different components work together.

Testing is usually thought of as unit testing, but in reality most tests you write are most likely integration tests. While a unit test is supposed to test a "unit" of code such as a function, an integration test will test the use of a bunch of functions "integrated" together.

UI tests become necessary when you can't test certain aspects of your app using some input/output validation or need to test the flows of the app. You would write a unit test for credential validation: does username/password meet the requirements. An integration test to validate retrieving a full User object when logging in a user (assuming you mock the database/network layers), and a UI test to test the login form doing all these.

In the above example, you can see that a unit test may not be as necessary since the integration test will also touch on the individual functions. You should unit specific behavior, such as a user trying the known invalid parameters do in fact fail, i.e. SQL injection.


0 views   0 shares

No matter what stage you're at in your education or career, TuteeHub will help you reach the next level that you're aiming for. Simply,Choose a subject/topic and get started in self-paced practice sessions to improve your knowledge and scores.