Software Testing

Choose a study mode

Play Quiz
Study Flashcards
Spaced Repetition
Chat to Lesson

Podcast

Play an AI-generated podcast conversation about this lesson
Download our mobile app to listen on the go
Get App

Questions and Answers

Which type of software documentation is primarily aimed at end-users, providing instructions on how to use the software?

  • User Documentation (correct)
  • Technical Documentation
  • Developer Documentation
  • Marketing Documentation

In software testing, what is the primary goal of ensuring a software product is 'Defect free'?

  • Matching the actual software against expected requirements (correct)
  • Meeting the expected deadlines
  • Minimizing the cost of development
  • Exceeding user expectations in functionality

What is a key objective of software testing that focuses on fulfilling the needs of the end user?

  • To ensure the code is optimized for performance
  • To find and correct defects
  • To check whether the user's needs are satisfied (correct)
  • To minimize development time

Which of the following is a key objective of software testing?

<p>To ensure requirement matching with customer needed. (C)</p> Signup and view all the answers

Which factor most commonly contributes to the introduction of bugs in software?

<p>Miscommunication or No Communication (B)</p> Signup and view all the answers

What misconception about software testing is addressed by emphasizing that testing never ends?

<p>Testing activities start only after the coding is complete. (B)</p> Signup and view all the answers

In the context of software testing, what accurately defines a 'Bug'?

<p>The deviation of the actual result from the expected result (B)</p> Signup and view all the answers

Which statement accurately describes the relationship between 'Error', 'Fault', and 'Failure' in software?

<p>An error leads to a fault in the software, which can then cause a failure in operation. (D)</p> Signup and view all the answers

In a scenario where a function intended to square an integer n (i.e., calculate $n * n$) incorrectly returns n * 2, how would this be classified?

<p>Fault/Bug (C)</p> Signup and view all the answers

What is typically included or defined within a testing specification?

<p>Test Cases (C)</p> Signup and view all the answers

Which type of software testing focuses on evaluating individual units or components of the software?

<p>Unit Testing (C)</p> Signup and view all the answers

Following unit testing, which testing phase focuses on verifying the interaction between software components?

<p>Integration Testing (D)</p> Signup and view all the answers

What does 'UAT' stand for under types of SW Testing in SW Engineering?

<p>User Acceptance Testing (C)</p> Signup and view all the answers

Which type of testing is primarily concerned with evaluating aspects such as performance, usability, and scalability?

<p>Non-Functional Testing (A)</p> Signup and view all the answers

After a software update is deployed, which type of testing ensures that existing functionalities still work as expected?

<p>Regression Testing (D)</p> Signup and view all the answers

In which testing methodology is knowledge of the internal program design and code essential?

<p>White box testing (D)</p> Signup and view all the answers

What is a fundamental characteristic of black box testing?

<p>No knowledge of internal program design required. (D)</p> Signup and view all the answers

What is the primary focus of tests written using the black box testing methodology?

<p>Requirements and functionality (A)</p> Signup and view all the answers

Which black box testing technique is used to validate when a VALUE is between 1 and 100, the system prints 'Pass'?

<p>Equivalence Partitioning (EP) (A)</p> Signup and view all the answers

In the context of black box testing, which technique involves testing values directly on, just above, and just below boundaries?

<p>Boundary value analysis(BVA) (C)</p> Signup and view all the answers

Which testing technique uses tables to represent inputs versus rules, cases, or test conditions?

<p>Decision Table Testing (B)</p> Signup and view all the answers

Which testing technique is used for system behaviors that are triggered by changes to the input conditions?

<p>State Transition Testing (C)</p> Signup and view all the answers

What is the primary goal of White Box testing in software engineering?

<p>To verify all the decision branches, loops, and statements in the code. (B)</p> Signup and view all the answers

What type of coverage ensures that every line of code is executed at least once during testing?

<p>Statement Coverage (A)</p> Signup and view all the answers

What is the objective of branch coverage in white box testing?

<p>To evaluate the 'FALSE' conditions. (A)</p> Signup and view all the answers

Which type of coverage in white box testing requires the most comprehensive testing effort?

<p>Path Coverage (B)</p> Signup and view all the answers

What is the aim of a 'Test to pass (Happy scenario)' during the development of test cases?

<p>To ensures that the software minimally works (B)</p> Signup and view all the answers

What is the primary goal of 'Test to fail (Bad scenario)' test cases?

<p>Choose test cases to appear the weaknesses in software (B)</p> Signup and view all the answers

What is the main purpose of the Software Development Life Cycle (SDLC)?

<p>To design and develop high-quality software (A)</p> Signup and view all the answers

What does the Software Testing Life Cycle (STLC) consist of?

<p>Activities carried out by Testers methodologically to test your software product. (B)</p> Signup and view all the answers

How does the V model organize software development and testing activities?

<p>By integrating testing throughout the development phases. (A)</p> Signup and view all the answers

Which combination of A and B will satisfy both the IF conditions in the following code?

INPUT A & B
C = A + B
IF C>100
 PRINT “ITS DONE”
END IF
IF A>50
 PRINT "ITS PENDING"
END IF

<p>A=50, B=60 (C)</p> Signup and view all the answers

Which combination of A and B ensures that only “ITS DONE” is printed in the following code?

INPUT A & B
C = A + B
IF C>100
 PRINT “ITS DONE”
END IF
IF A>50
 PRINT "ITS PENDING"
END IF

<p>A=50, B=60 (D)</p> Signup and view all the answers

Which option for A and B will result in executing all lines of code?

INPUT A & B
C = A + B
IF C>100
 PRINT “ITS DONE”
END IF

<p>A=40 and B=70 (B)</p> Signup and view all the answers

In the snippet, which values for Testcase_01 will evaluate the "FALSE" condition?

INPUT A & B
C = A + B
IF C>100
 PRINT “ITS DONE”
Else
 print "Its Pending"

<p>A=33, B=45 (B)</p> Signup and view all the answers

How many test cases will be required to ensure maximum coverage in the snippet?

INPUT A & B
C = A + B
IF C>100
 PRINT “ITS DONE”
END IF
IF A>50
 PRINT "ITS PENDING"
END IF

<p>4 (C)</p> Signup and view all the answers

Flashcards

Software Testing

A method to check if the actual software product matches expected requirements and is defect-free.

Why is testing important?

To find and correct defects, satisfy user needs, avoid user-detected problems, and ensure quality products.

Objectives of Testing

Ensure requirements match customer needs, define and prevent defects, ensure quality, and generate high-quality test cases.

Why Software Has Bugs

Miscommunication, time pressure, programming mistakes, and changing requirements.

Signup and view all the flashcards

What is a Bug?

The deviation of the actual result from the expected result.

Signup and view all the flashcards

Software Error

A human action that produces an incorrect result leading to a fault.

Signup and view all the flashcards

Software Bug

The presence of error at the time of execution of the software.

Signup and view all the flashcards

Software Fault

State of software caused by an error.

Signup and view all the flashcards

Software Failure

Deviation of the software from its expected result. It is an event.

Signup and view all the flashcards

Unit Testing

Testing individual units or components of a software application in isolation.

Signup and view all the flashcards

Integration Testing

Testing performed to expose defects in the interfaces and interaction between integrated components or systems.

Signup and view all the flashcards

System Testing

Testing the complete and fully integrated software product.

Signup and view all the flashcards

Black Box Testing

Tests based on required functionality without looking at the internal code.

Signup and view all the flashcards

White Box Testing

Tests based on the internal structure and code of the application.

Signup and view all the flashcards

Equivalence Partitioning

Tests if input values within defined ranges are processed correctly.

Signup and view all the flashcards

Boundary Value Analysis

Tests values at the edges of valid input ranges.

Signup and view all the flashcards

Decision Table Testing

A tabular representation of inputs versus rules/cases/test conditions to test different input combinations.

Signup and view all the flashcards

State Transition Testing

Outputs are triggered by changes to the input conditions, executing valid and invalid state transitions.

Signup and view all the flashcards

White Box Testing Goal

Ensures all paths, branches, loops, and statements in the code are verified.

Signup and view all the flashcards

Statement Coverage

To check all the lines of the code

Signup and view all the flashcards

Branch Coverage

Which will evaluate the “FALSE” conditions.

Signup and view all the flashcards

Path Coverage

Used to test the complex code snippets

Signup and view all the flashcards

What is SDLC

SDLC is Software Development Life Cycle. It is the sequence of activities carried out by Developers to design and develop high-quality software.

Signup and view all the flashcards

What is STLC

STLC is Software Testing Life Cycle. It consists of a series of activities carried out by Testers methodologically to test your software product.

Signup and view all the flashcards

Study Notes

Documentation Types

  • User documentation is one type
  • Technical documentation is another type
  • Marketing documentation completes the list

Software Testing

  • Software Testing checks if the actual software product aligns with expected requirements
  • It ensures the software is free of defects

Why Testing Matters

  • Testing finds and fixes defects
  • It verifies users’ needs are met
  • Testing avoids users detecting problems, and delivers quality products

Objectives of Software Testing

  • Testing ensures requirements match customer needs
  • It defines and prevents defects
  • Testing ensures high quality and generates test cases

Why Software Has Bugs

  • Miscommunication or a lack of communication causes bugs
  • This can cause unclear points about an application should or shouldn't do
  • Time pressure contributes to bugs
  • Programming mistakes and changing requirements contribute to bugs

Common Misunderstandings About Software Testing

  • Testing is not just debugging
  • Assuming careful programmers negate the need for testing is wrong
  • Testing isn't limited to after coding
  • Testing is ongoing
  • Testing involves creativity and isn't solely manual

Bugs

  • A bug is any deviation of the actual result from the expected result

Types of Errors

  • Error: A human action producing an incorrect result that causes a fault
  • Bug: The presence of an error at the time software is executed
  • Fault: A state of software caused by an error
  • Failure: Deviation from the expected result, viewed as an event

Software Error Considerations

  • For any integer n, square (n) = n*n
  • Correct result of running square(2) is 4
  • Fault/Bug is returning x2 instead of xx
  • Failure happens when square(3) returns 6

Software Quality

  • Testers must ensure that 100% of the software works correctly and is error-free
  • There is always a possibility that testers will miss bugs
  • Testing is unable to cover 100% of possible software operations

Types of Software Testing in Engineering

  • Functional Testing: includes unit, integration, and UAT (user acceptance testing)
  • Non-Functional Testing: performance, usability, and scalability
  • Maintenance: regression and maintenance testing

Testing Methodologies

  • Black box testing doesn't need internal program design knowledge
  • Black box tests are based on requirements and functionality
  • White box testing requires knowledge of internal program design and code
  • White box tests are based on coverage of code statements, branches,paths, and conditions

Black Box Testing

  • Black box testing is for functional and non-functional testing
  • Black box requires no reference to the system's internal structure

Black Box Testing Techniques

  • Equivalence Partitioning (EP): If VALUE is between 1 and 100, print 'Pass'
  • Boundary value analysis (BVA): If VALUE is between 1 and 100 (inclusive), print 'Pass', test values just above and below the boundaries
  • Decision Table Testing: Used for different input combinations, tabular representation of inputs versus rules/cases/test conditions
  • State Transition Testing: Outputs are triggered by input condition changes, execute valid and invalid state transitions

White Box Testing

  • White box testing uses the internal structure of the component or system

White Box Testing Techniques

  • The goal of White Box testing in software engineering is to verify all decision branches, loops, and statements in the code
  • Statement Coverage: Only one test case is needed to check all code lines, i.e., TestCase_01 (A=40 and B=70)
  • Branch Coverage: Evaluates "FALSE" conditions, ensures maximum coverage, i.e., TestCase_01: A=33, B=45 and TestCase_02: A=25, B=30
  • Path Coverage: Tests complex code snippets involving loop statements or loop combinations with decision statements; maximum coverage requires 4 test cases

Test Case Objectives

  • Test to pass (Happy scenario): Assures software minimally works and apples simple, straightforward test cases
  • Test to fail (Bad scenario): Chooses test cases to show weaknesses in the software, designs test cases to break the software

SDLC and STLC

  • SDLC (Software Development Life Cycle): Sequence of activities by developers to design and develop high-quality software
  • STLC (Software Testing Life Cycle): Series of activities by testers to methodologically test software products

Studying That Suits You

Use AI to generate personalized quizzes and flashcards to suit your learning preferences.

Quiz Team

Related Documents

More Like This

Use Quizgecko on...
Browser
Browser