Software Testing
Software Testing
Objectives
After completion of this chapter you will be able to: Explain what is Software Testing Understand the Software Testing objectives Understand the test plan Define white box & Black box testing Explain different test levels Explain the concepts of test cases suites, scripts& scenarios Define and explain the testing cycle Types of Testing
CMC Limited
Introduction
Software Testing is the process used to help to identify the correctness, completeness, security, and quality of developed computer software. Testing is a process of technical investigation, performed on behalf of stakeholders, that is intended to reveal qualityrelated information about the product. Testing can never completely correct all the time.So it will be continued. Software testing should be distinguished from the discipline of Software Quality Assurance (SQA), which encompasses all business process areas, not just testing.
CMC Limited
Introduction contd..
In SQA, software process specialists and auditors take a broader view on software and its development. They examine and change the software engineering process itself to reduce the amount of faults that end up in the code or deliver faster.
CMC Limited
Introduction contd..
Testing objectives
Testing is a process of executing a program with the intent of finding an error. A good test case is one that has a high probability of finding an as yet undiscovered error. A successful test is one that uncovers an as yet undiscovered error. Testing demonstrates that the software appears to be working as stated in the specifications. It cannot show the absence of defect , it can only show that software defects are present.
CMC Limited
Introduction contd..
CMC Limited
Introduction contd..
CMC Limited
Introduction contd..
CMC Limited
Introduction contd..
CMC Limited
Test Plan
The test strategy identifies multiple test levels, which are going to be performed for the project.
Activities at each level must be planned well in advance and it has to be formally documented. Based on the individual plans only, the individual test levels are carried out.
CMC Limited
Background Introduction Assumptions Test Items Features to be tested Features not to be tested Approach Item pass/fail criteria Suspension/Resumption criteria Test deliverables
Testing tasks Environmental needs Responsibilities Staffing & Training Schedule Resources Risks Approvals
CMC Limited
CMC Limited
Test levels
There are four level :
CMC Limited
Unit testing is a procedure used to validate that individual units of source code are working properly. Unit is the smallest testable part of an application In procedural programming a unit may be an individual program, function, procedure, web page, menu etc, while in object-oriented programming, the smallest unit is always a Class; which may be a base/super class, abstract class or derived/child class.
CMC Limited
Integration testing exposes defects in the interfaces and interaction between integrated components (modules). Integration testing is the phase of software testing in which individual software modules are combined and tested as a group. It follows unit testing and precedes system testing.
CMC Limited
The test levels contd.. System testing tests an integrated system to verify/validate that it meets its requirements. System testing is testing conducted on a complete, integrated system to evaluate the system's compliance with its specified requirements. System testing falls within the scope of black box testing, and as such, should require no knowledge of the inner design of the code or logic.
CMC Limited
Acceptance testing can be conducted by the client. It allows the end-user or customer or client to decide whether or not to accept the product. In engineering and its various sub disciplines, acceptance testing is performed Acceptance testing can be divide in two parts : Alpha testing Beta testing
CMC Limited
Alpha testing Alpha testing is simulated or actual operational testing by potential users/customers or an independent test team at the developers' site.
Beta testing Beta testing comes after alpha testing. Versions of the software, known as beta versions, are released to a limited audience outside of the programming team. The software is released to groups of people so that further testing can ensure the product has few faults or bugs.
Sometimes, beta versions are made available to the open public to increase the feedback field to a maximal number of future users.
CMC Limited
CMC Limited
Test cases, suites, scripts and scenarios contd.. Test Script A test script is a short program written in a programming language used to test part of the functionality of a software system. Test Suite The most common term for a collection of test cases is a test suite. Scenario Scenario testing is a software testing activity. It uses scenario tests, or simply scenarios, which are based on a hypothetical story to help a person think through a complex problem or system.
CMC Limited
Testing cycle
Software testing is maintain through a chain of cycle The stages of cycle are as follows: Requirements Analysis: Design phase, Test Planning Test Development: Test Execution Test Reporting Retesting the Defects
CMC Limited
Types of Testing
Types BLACK BOX TESTING Meaning Testing without knowledge of the internal workings of the item being tested. Tests are usually functional.
COMPATIBILITY TESTING Testing to ensure compatibility of an application or Web site with different browsers, OSs, and hardware platforms.
CONFORMANCE TESTING Verifying implementation conformance to industry standards. Producing tests for the behavior of an implementation to be sure it provides the portability, interoperability, and/or compatibility a standard defines. Validating an application or Web site conforms to its specifications and correctly performs all its required functions. This entails a series of tests which perform a feature by feature validation of behavior, using a wide range of normal and erroneous input data.
Types of Testing
Types ACCEPTANCE TESTING Meaning Testing to verify a product meets customer specified requirements.
INTEGRATION TESTING
Testing in which modules are combined and tested as a group. Modules are typically code modules, individual applications, client and server applications on a network, etc. Integration Testing follows unit testing
Similar in scope to a functional test, a regression test allows a consistent, repeatable validation of each new release of a product or Web site. Such testing ensures reported product defects have been corrected for each new release and that no new quality problems were introduced in the maintenance process.
REGRESSION TESTING
PERFORMANCE TESTING
Types of Testing
Types SMOKE TESTING Meaning Originated in the hardware testing practice of turning on a new piece of hardware for the first time and considering it a success if it does not catch on fire.
STRESS TESTING
Testing conducted to evaluate a system or component at or beyond the limits of its specified requirements to determine the load under which it fails and how.
Testing conducted on a complete, integrated system to evaluate the system's compliance with its specified requirements. . System testing falls within the scope of black box testing, and as such, should require no knowledge of the inner design of the code or logic. Functional and reliability testing in an Engineering environment. Producing tests for the behavior of components of a product to ensure their correct behavior prior to system integration.
SYSTEM TESTING
UNIT TESTING
Types of Testing
Types WHITE BOX TESTING Meaning Testing based on an analysis of internal workings and structure of a piece of software. Includes techniques such as Branch Testing and Path Testing. Also known as Structural Testing and Glass Box Testing. Similar to system testing, involves testing of a complete application environment in a situation that mimics real-world use, such as interacting with a database, using network communications, or interacting with other hardware, applications, or systems if appropriate.
END-TO-END TESTING
SANITY TESTING
Testing to determine if a new software version is performing well enough to accept it for a major testing effort.
User-friendliness check. Application flow is tested, Can new user understand the application easily, Proper help documented whenever user stuck at any point.
USABILITY TESTING
Types of Testing
Types INSTALL/ UNINSTALL TESTING Meaning Tested for full, partial, or upgrade install/uninstall processes on different operating systems under different hardware, software environment.
COMPATIBILITY TESTING Testing how well software performs in a particular hardware/software/operating system/network environment and different combination s of above. COMPARISON TESTING Comparison of product strengths and weaknesses with previous versions or other similar products
SECURITY TESTING
Testing how well the system protects against unauthorized internal or external access. Checked if system, database is safe from external attacks.