What Are The Different Types of Software Testing?

Reading Time: 6 minutes

Updated on:

Software testing is a major part of the software development process. As part of the testing phase, there are a lot of tests that are run against a change or a new piece of software, each with different names and purposes. Let’s take a look at each of the types of software testing and what they are used for.

Two Main Categories of Testing

If you’ve spoken to any testers, they may have mentioned there are two different categories of testing – black box and white box.

Black box testing means that tests are run without knowing or even ignoring the internal code structure of what you’re testing. You supply it an input, get an output, and check it against your expected results. For example, you have a function called doubleMyNumber, which had an input of one number and returned a number that was double the input number. You could run a black box test on this without knowing the internal structure of this function. Provide an input value of 2, and check that the output value is 4. Provide an input value of 30, check that the output value is 60.

White box testing means that tests are run when you know the internal code structure of what you’re testing, and run tests against it. This involves testing for certain exceptions or paths within the code, and even testing the limits of what the code can handle. For our doubleMyNumber function, we would have a look at the code. If the code is simply “outputNumber = inputNumber * 2″, our tests might be similar. But if there are if statements and checks for maximum ranges and negative numbers, we could provide those numbers to see what happens.

This is a simple example, but it helps to explain the difference and how it can be used for more complicated solutions.

Testing is an important part of any software project. Now that we’ve covered these two categories, let’s have a look at the different types of software testing. I’ll cover them in the general order that they are performed for a project.

Unit Testing

Performed by: Developer

Testing Category: White Box

Unit testing is the testing that is done on a particular code module or unit of code. It’s usually performed by the developer who writes the code, and is a type of white box testing. It’s a good way to improve the quality of the code before passing it on to the tester.

This is where the developer looks at the code, and writes tests to check each of the expected outcomes and flows, based on the logic within the module, using certain inputs. It’s done in isolation of the other modules, which means you can usually run the unit testing on a particular module or function without any of the other code being ready (depending on how your system works, of course). It can be done using automated testing or even manual testing.

Integration Testing

Performed by: Developer

Testing Category: White Box and Black Box

Integration testing is where the developer has several code modules, which are related to a specific function, are combined and testing to ensure the output is correct. Instead of testing a single code module in unit testing, this type of testing involves a few modules.

This could involve testing against a database connection, testing input from a user, or reading and writing to a file, for example. Inputs can be provided, and outputs are expected and checked. This kind of testing can be considered white box or black box, depending on how the tests are set up and what information is used.

Functional Testing

Performed By: Various

Testing Category: Black Box

Functional testing is where tests are run to check that the solution meets the requirements that it is being built on. The requirements are provided in a format such as user stories or business requirements, and someone checks each of these against the solution by writing and running tests.

It doesn’t need to be done by a developer or tester. I’ve seen cases where it’s the business analyst doing this test, and as a business analyst, sometimes it’s a good idea to get them to do it. They would have a look at the requirement, and check that the solution meets it.

This is a kind of black box testing, as the person setting up and running the tests doesn’t need to know how the code works.

System Testing

Performed By: Testers

Testing Category: Black Box

System testing is another type of software testing that involves more than one module. It’s where the entire solution has been written and the environments are ready, and tests are performed to ensure the entire solution works. Specific tests are written to test all kinds of functionality, which may be more detailed than the functional tests, as they test all areas and not just the requirements.

This is often a large part of the testing and is the first chance that the entire system is tested together. It’s a form of black box testing, as at this level, we don’t need to know what the code is like.

Regression Testing

Performed By: Testers

Testing Category: Black Box

Regression testing is similar to system testing. Regression testing is where you implement the solution to a particular environment, and test it against other integrated systems, to ensure that it doesn’t break anything. Other systems may not have changed for this solution, but testing still needs to be done to ensure this change (whether it’s a small change or a large solution) doesn’t cause any problems elsewhere.

Performance Testing

Performed By: Testers

Testing Category: Black Box

Performance testing is where the solution is tested for speed, responsiveness and effectiveness to ensure that it performs under the required load before it is implemented. For example, if your solution is expected to have 100 concurrent users, then performance testing will simulate the solution having 100 users on it at a time, and measure the results.

The performance and speed of a system needs to hold up and still work under these conditions. Requirements should have been specified earlier in the project about what the expectations for performance are, and these are tested in this phase.

Performance testing is often done using automated tools to simulate normal and exceptional behaviour, as it’s much easier to do it this way than to get 100 people all using the system at once.

Load Testing or Stress Testing

Performed By: Testers

Testing Category: Black Box

Load testing, or stress testing as it’s sometimes called, are both types of software testing. It’s a kind of testing that is similar to performance testing. The solution is tested for performance, but it is done in conditions that are not ideal and is run outside the expected load of the system, to see how it runs in this situation. These kinds of situations can happen sometimes if servers or networks go down or are impacted, so the team needs to see how the solution is impacted.

For example, if a solution was designed to handle 200 users at a time, stress testing could simulate 300, 500 or 1000 users to see what happens. It could also see what happens if a slower server or technology is used.

Security Testing

Performed By: Testers, or Security Team

Testing Category: Black Box

Security testing is where the solution is tested to see if it can withstand external attacks. This kind of testing is often covered by other tests, but can also be done separately by the testing team or another security team if it exists.

Tests are performed on input areas such as user logins, page browsing, and can also look at ways to get into the database or other areas that aren’t meant to be accessed. There may be a standard set of tests for this part, depending on your organisation.

The solution should be safe from all kinds of attacks, which can only really be done with this kind of testing.

Usability Testing

Performed By: Users

Testing Category: Black Box

Usability testing is where the end users of the system use and navigate the system. The aim is to make sure that these end users find the system usable, and can navigate the system easily. It’s also tested against any documentation that is prepared.

Depending on the project, there is often a stage earlier in the project where users are consulted on the design or user experience of the solution. This is where their feedback is gathered and incorporated into the solution. If this is done, there shouldn’t be any surprises, but it is a useful test anyway.

This kind of testing is black box testing, as it doesn’t require any knowledge of the code. It’s done by the users with the assistance of a test manager or even a business analyst.

User Acceptance Testing

Performed By: Users

Testing Category: Black Box

User acceptance testing, or acceptance testing, is where the solution is provided to the end users and they check it to ensure it meets their requirements. This is done in the form of functional requirements and non-functional requirements.

Functional requirements should have been tested with the functional testing earlier. Non-functional requirements are tested with performance testing and usability testing as well.

At this stage, the outcome of this test is acceptance by the user that the solution does what it needs to. It’s often done with the assistance of the business analysts or project manager, and is the final stage of testing.

Well, hopefully this article has helped you understand the different types of software testing. If you have any questions on software testing, share them in the section below.