DEV Community

Cover image for Functional Testing VS Non-functional Testing
Supriya
Supriya

Posted on • Edited on

Functional Testing VS Non-functional Testing

FUNCTIONAL TESTING:

Functional Testing is a type of software testing where the functional requirements and specifications of the application under test(AUT) is tested. In functional testing we provide input data and monitor the system's response to the input data and compare the output with expected output. We can perform functional testing Manually or in automated way.
The scope mostly includes User interface, database, APIs of the software application.
Example:
If we are testing a banking website, under functional testing the scope involves whether the website can perform tasks such as opening a new account for a customer, logging in functionality for an existing customer, adding and withdrawing money from the account etc.

Scope of functional testing:

  1. Basic Usability: We test if the user is able to navigate through the screens or not.
  2. Mainline functions: We test of the main functionalities and functions of the application
  3. User accessibility: The accessibility of the system is tested.
  4. Error Conditions: WE test of the application returns appropriate error messages are displayed or not in case of error conditions.

Image description

Types of functional testing:

  1. Unit testing: In Unit testing we test smaller units of modules of the application. Also referred as "Component testing".
  2. Its primarily performed by Developers using White box approach.
  3. The objective of unit testing is to deduct bugs in the earlier stage of development.
    Example:
    In a banking application, testing a unit of the application like Login page with different test cases like with valid username/password, invalid username and password etc.

  4. Integration testing: In Integration testing we integrate the individual units and test the collective functionality.

  5. It is performed by Testers on testing servers.

  6. The scope of integration testing is to expose errors during the interaction between the individual units.

Example: In a banking application, when a customer with a balance of 1000 $ withdraws 500$ and their balance should be updated to 500$. Here the different modules are Login, current balance, Withdraw, Transfer etc.

  1. System testing: In System testing the end to end application is tested.
  2. It is done on a production alike server by the testers.
    Example : Logging into a banking application, Checking the balance, making a transfer and then logging off.

  3. Acceptance testing:
    It is done by the customers to check if the product satisfies the Acceptance criteria.

  4. It helps is reducing the chances of issues occurring during the production.

  5. Regression testing: It is done to check the unchanged features of an application to make sure that changes like adding, deleting, modifying a feature doesn't impact the unchanged feature.
    Example: When a new feature like a button is added to display user's balance without logging in to the banking application, this functionality doesn't impact the existing logging feature.

  6. Retesting: In this case we only test the failed test case to make sure that the previously raised defect in previous build are fixed in the current build.

  7. Smoke testing: In smoke testing we test the crucial functionalities of an application are working fine or not like logging in functionality.
    It is done in the initial build versions.

  8. Sanity testing: In Sanity testing we test for bug fixes or code changes in later builds.

NON FUNCTIONAL TESTING:

Non functional testing is used to verify the behavior and non function attribute of the system. The non functional attributes include performance, usability, maintainability, stability, portability etc.

Scope of Non functional testing:

  1. More Usability: To increase usability, efficiency, maintainability, and portability of the software.
  2. Lower production risk: This type of testing is done to reduce the production related bugs with respect to non functional requirements of the software.
  3. Cost reduction: To help in the reduction of costs related to non-functional aspects of the product.
  4. Collect metrics: To collect and produce measurements and metrics for internal research and development and enhancing the knowledge in product behavior.

Types of Non functional Testing:

  1. Performance Testing: In this testing we check the performance and stability of the software under varying workloads. Performance testing scope includes testing the Speed, Scalability, Stability and Reliability(product is secure or not) of the software. Example : A banking application's response time is usually 60 seconds for the login page and this response time doesn't change when 10000 users try to access the login page at the same time.
  2. Load Testing: In load testing we test if the software can handle huge transactions or increase in load. Load testing is done mostly by end users. Example : When a huge transaction load is passed to a Banking application.
  3. Volume Testing: In volume testing we test the software by passing huge volume at a time and checking system's response time. Example: When huge volume of data is passed to the system to check the banking applications response time.

Top comments (0)