Saturday, 17 December 2022

Psychology of Software Testing

 

What is the psychology of testing?

  1. As mentioned, in testing, the software under test (SUT) is executed with a set of test cases.
  2.  As discussed, devising a set of test cases that will guarantee that all errors will be detected is not feasible. Moreover, there are no formal or precise methods for selecting test cases.
  3.  Even though there are a number of heuristics and rules of thumb for deciding the test cases, selecting test cases is still a creative activity that relies on the ingenuity of the tester.
  4.  Because of this, the psychology of the person performing the testing becomes important.
  5.  A basic purpose of testing is to detect the errors that may be present in the program.
  6.  Hence, one should not start testing with the intent of showing that a program works; rather the intent should be to show that a program does not work; to reveal any defect that may exist.
  7.  Due to this, testing has also been defined as the process of executing a program with the intent of finding errors (Myers, 1979).
  8. This emphasis on proper intent of testing is not a trivial matter because test cases are designed by human beings, and human beings have a tendency to perform actions to achieve the goal they have in mind. 
  9. So, if the goal is to demonstrate that a program works, we may consciously or subconsciously select test cases that will try to demonstrate that goal and that will beat the basic purpose of testing. 
  10. On the other hand, if the intent is to show that the program does not work, we will challenge our intellect to find test cases toward that end, and we are likely to detect more errors. 

3 sections of the psychology of testing  

  1. The first level of testing is called unit testing. Unit testing is essentially for verification of N the code produced by individual programmers, and is typically done by the programmer of the module. 
  2. Generally, a module is offered by a programmer for integration and use by others only after it has been unit tested satisfactorily. 
  3. The next level of testing is often called integration testing. In this, many unit tested modules are combined into subsystems, which are then tested. 
  4. The goal here is to see if the modules can be integrated properly. Hence, the emphasis is on testing interfaces between modules.
  5.  This testing activity can be considered testing the design.
  6. The next levels are system testing and acceptance testing. Here the entire software system is tested. 
  7. The reference document for this process is the requirements document, and the goal is to see if the software meets its requirements.
  8.  This is often a large exercise, which for large projects may last many weeks or months. 

This is essentially a validation exercise, and in many situations it is the only validation activity.

Levels of test independence And The balance between self-testing and independent testing 

  1. These levels of testing are performed when a system is being built from the components that have been coded. 
  2. There is another level of testing known as regression testing, that is performed when some changes are made to an existing system. 
  3. We know that changes are fundamental to software; any software must undergo changes. However, when modifications are made to an existing system, testing also has to be done to make sure that the modification has not had any undesired side effect of making some of the earlier services faulty. 
  4. That is, besides ensuring the desired behavior of the new services, testing has to ensure that the desired behavior of the old services is maintained. 
  5. This is the task of regression testing.
  6. For regression testing, some test cases that have been executed on the old system are maintained, along with the output produced by the old system. 
  7. These test cases are executed again on the modified system and its output compared with the earlier output to make sure that the system is working as before on these test cases.
  8.  This frequently is a major task when modifications are to be made to existing systems.
  9. Complete regression testing of large systems can take a considerable amount of time, even if automation is used.
  10.  If a small change is made to the system, often practical considerations require that the entire test suite not be executed, but regression testing be done with only a subset of test cases.
  11.  This requires suitably selecting test cases from the suite which can test those parts of the system that could be affected by the change.
  12.  Test case selection for regression testing is an active research area and many different approaches have been proposed in the literature for this.

 Acceptance testing is often performed with realistic data of the client to demonstrate that the software is working satisfactorily. 

It may be done in the setting in which the software is to eventually function. 

Acceptance testing essentially tests if the system satisfactorily solves the problems for which it was commissioned. 

Testing is essentially a destructive process, tester has to treat the program as an adversary that must be beaten by the tester by showing the presence of errors. 

This is one of the reasons why many organizations employ where the independent testing in which testing is done by a team that was not involved in building

What are different types of software testing?

Software Testing can be broadly classified into two types:

1. Manual Testing: Manual testing includes testing software manually, i.e., without using any automation tool or any script. In this type, the tester takes over the role of an end-user and tests the software to identify any unexpected behavior or bug. There are different stages for manual testing such as unit testing, integration testing, system testing, and user acceptance testing.

Testers use test plans, test cases, or test scenarios to test software to ensure the completeness of testing. Manual testing also includes exploratory testing, as testers explore the software to identify errors in it.

2. Automation Testing: Automation testing, which is also known as Test Automation, is when the tester writes scripts and uses another software to test the product. This process involves the automation of a manual process. Automation Testing is used to re-run the test scenarios quickly and repeatedly, that were performed manually in manual testing.

Apart from regression testing, automation testing is also used to test the application from a load, performance, and stress point of view. It increases the test coverage, improves accuracy, and saves time and money when compared to manual testing. 

No comments:

Post a Comment

GitHub Most Imp Command For Every Developer Learn:

 Top Command for GitHub:  1) git clone 2) git init and git status   3) git add file name  or git add .  4) git commit -m message  5) git rem...