C20: Software Testing Flashcards
What is software testing?
A software dynamic validation technique that can detect errors but cannot prove the software is error free.
What are some of the limitations of static approaches to software engineering?
Static approaches don’t execute the program, so they can’t detect errors that require execution.
Walkthrough and peer review couldn’t handle complexity very well because of human limits.
Benefits of software testing
● Knowing the software is going to be tested developers are more cautious when developing software.
● Can significantly improve the quality of the software.
● Adds another layer of quality assurance in addition to inspection, walkthrough.
● If the bugs are tracked, for example in a bug database, the information can be used to produce bug statistics used for process improvement.
What is black box testing?
Test cases designed to test the functionality of the program.
What are the black box testing techniques?
Equivalence Partitioning: Divides the input and output domains into a number of disjoint subsets and selects one test case from each subset.
Boundary Value Analysis: Selects test cases at and near the boundary of the equivalence classes.
Cause and Effect Analysis: Analyzes the functionality to identify the causes and their effects and tabulates them.
What is white box testing?
Derives test cases from the structure or logic of the component.
What are the white box testing techniques?
Basic Path Testing: Generates basic paths of the flow of the component under tree.
Condition Testing: Focus on testing logical conditions in the program.
Data Flow Testing: Select test paths of a program according to the location of definitions and uses of variables.
Loop Testing: Loops generate many different paths,
What is Cyclomatic Complexity?
The number of basics paths of the component under tree is defined as the cyclomatic complexity of the component.
Flow Graph Test Coverage Criteria
Node coverage: Each node of the graph must be visited at least once by the test cases.
Edge coverage: Each edge must be visited at least once by the test cases.
Basic path coverage: Requires that every basis path must exercised at least once.
All path coverage: requires that every possible path is test at least once. However this is practically impossible.
Data Flow Test Coverage Criteria
All defines coverage: Each definition is tested at least once.
All uses coverage: Each definition to each use is tested at least once.
All defined-uses paths coverage: All def-use paths from each definition to each use is tested at least once.
What is test coverage?
The percentage of certain software items that are tested (or exercised) over the total number of items of the same kind. A quality goal to be accomplished as well as a measuremtn of the accomplished goal.
Generic Software Testing Process
- Create test model from specification and determine a test coverage.
- Generate test cases as well as test data.
- Analyzing test results. Such as debugging.
What are the steps of use-case based testing?
- Prioritize the use cases using the traceability matrix.
- Generate test scenarios from the expanded use cases
- Identify test cases
- Generate test data
- Generate test scripts
What are the different tests of non-functional requirements?
Performance and Stress Testing: Aimed at assessing the system’s workload, throughput, response time, efficiency and resource utilization.
Testing For Security: Aimed at detecting the security vulnerabilities that can be exploited to breach a system.
Testing User Interface: Detect defects in the look and fee of the UI or the actor system interaction behaviour.
What is the difference between performance and stress testing?
Performance Testing: Aimed at assessing a system’s resource performance under normal usage situations.
Stress Testing: Aimed at assessing a system’s ability to withstand and process an extremely heavy workload.
How do you test for security?
White-box testing approaches are applied to detect security vulnerabilities and generate test cases.
Black-box testing feeds the system being tested with malicious input to break it.
How do you test the user interface?
Usability test
What are the different types of testing in the life cycle?
System Testing: Perform tests to ensure that the system satisfies system requirements and constraints.
Acceptance Testing: Perform tests to ensure that the software satisfies software requirements and constraints.
Integration Testing: Perform tests to ensure that all software components interact correctly.
Implementation and Unit Tests
What are the different strategies to perform integration testing?
● Big Bang: All of the components of the software system are integrated and tested together.
● Top-down integration: The components of the software system are integrated and tested from the root of a component invocation tree and the process moves downwards.
● Bottom-up integration: The components of the software system are integrated and tested from the leaf components of a component invocation tree and the process moves up the hierarchy.
● Critical/high priority components first: The critical or high-priority components are integrated and tested first.
● Available components first: The components of the software system are integrated and tested whenever they are available.
What is regression testing?
Executes all the existing test cases or a selected subset to ensure that the software system or its componets pass the tests after changes to a component are made.
What are some testing frameworks?
RedwoodHQ: If you want multiple testers to work together and run their tests from one webaccessible location. Tests can be written in Java/Groovy, Python, and C# to test web
applications with Selenium, APIs, or databases using their web IDE, which also includes
built-in GIT integration.
Sahi: If you need to test web interfaces. Sahi works as a proxy server that allows you to use it
within a browser. From the Sahi dashboard, you can launch the browser you want to test.
The Sahi controller guides you through the recording and capturing of the interaction you
want to perform against your application.
Galen Framework: If your automation efforts are focused on user experience design (UX) or
layout testing. Galen has a special syntax and rules you can use to describe and verify your
application’s layout.
Gauge: Practitioners of TDD and BDD will appreciate Gauge’s focus on creating living and executable documentation.