Pertemuan 12 Pengujian White Box Testing dan Black box Testing Rev0 0

Materi Kuliah
16 Dec 202313:08

Summary

TLDRThis lecture on software testing focuses on two key methods: Black Box Testing and White Box Testing. Black Box Testing evaluates software functionality by examining outputs based on given inputs without considering the internal mechanisms. It identifies errors like missing functionality, interface issues, or performance failures. In contrast, White Box Testing examines the internal workings of the software, using techniques like Basis Path Testing to assess algorithm complexity and ensure logical correctness. The session explores the importance of both methods in identifying software flaws and ensuring quality assurance through detailed testing strategies.

Takeaways

  • 😀 Black Box Testing focuses on testing the output of a system based on different inputs, without considering the internal workings of the system.
  • 😀 White Box Testing involves testing the internal mechanisms of a system, focusing on its code, algorithms, and data flow.
  • 😀 Black Box Testing detects errors such as missing or incorrect functions, interface issues, data access problems, and performance issues.
  • 😀 Example of Black Box Testing: In an ATM system, the tester ensures that the ATM accepts the correct password and processes transactions correctly based on various inputs.
  • 😀 White Box Testing helps ensure the correctness of internal logic, algorithms, and the program's control structures.
  • 😀 Basis Path Testing in White Box Testing maps an algorithm into a flow graph and tests independent paths to check the program's logical decisions.
  • 😀 Control Structure Testing in White Box Testing focuses on validating decision paths, loops, and branches in the code.
  • 😀 Cyclomatic Complexity is a key metric in White Box Testing, which measures the complexity of a program's control flow using a formula: VG = E - N + 2P.
  • 😀 The concept of 'independent paths' in White Box Testing ensures that each path is executed at least once, helping to identify errors in logical flow.
  • 😀 The flow graph notation used in White Box Testing includes nodes for processes and decision points, with edges indicating the flow of execution in the program.
  • 😀 White Box Testing requires testers to have an understanding of the internal workings of the software, unlike Black Box Testing, which does not require knowledge of the code.

Q & A

  • What is Black Box Testing?

    -Black Box Testing is a type of software testing where the internal workings of the system are ignored. It focuses solely on evaluating the system’s outputs based on selected inputs. This method helps to identify functional issues, missing features, and data access errors.

  • How does Black Box Testing differ from White Box Testing?

    -The primary difference is that Black Box Testing focuses on testing the software from an external perspective, based solely on inputs and outputs, without considering the internal structure. White Box Testing, in contrast, examines the internal workings of the software, verifying whether the system’s internal processes and logic are correct.

  • What are some common errors identified through Black Box Testing?

    -Black Box Testing can identify errors such as incorrect or missing functions, interface errors, data structure issues, initialization mistakes, program termination errors, and performance problems.

  • Can you provide an example of Black Box Testing in practice?

    -An example of Black Box Testing in practice is testing an ATM system. The user inputs a six-digit password, which must adhere to certain format rules (e.g., no prefixes like '0' or '1'). The test focuses on verifying if the system correctly processes inputs and returns the expected output, such as allowing access to bank services.

  • What is White Box Testing?

    -White Box Testing involves testing the internal mechanics of the software. It focuses on ensuring that the internal operations, such as code structure, logic, and flow, work correctly. This type of testing is done by examining the code and running test cases based on its structure.

  • What is Basis Path Testing in White Box Testing?

    -Basis Path Testing is a technique used in White Box Testing to test a program's flow by creating test cases based on its complexity. It involves mapping out the program’s flow using flowcharts and algorithms and ensuring that all possible paths, particularly independent paths, are tested.

  • What is Cyclomatic Complexity and how is it used in White Box Testing?

    -Cyclomatic Complexity is a metric used to measure the complexity of a program. It helps to determine the number of independent paths that should be tested. The complexity is calculated using a formula that considers the number of regions in a flowchart, nodes, and edges in the program’s control flow.

  • How is a flowchart used in Basis Path Testing?

    -In Basis Path Testing, a flowchart is used to map out the logic and flow of a program. Each node represents a process or decision point, and the flow of control is depicted by arrows. The flowchart is used to identify all possible paths through the program, ensuring that each path is tested.

  • What are independent paths in the context of White Box Testing?

    -Independent paths refer to distinct execution paths in the program that include at least one unique set of conditions or processes. These paths must be tested to ensure that the software handles all potential scenarios correctly.

  • What is the role of control structures in White Box Testing?

    -Control structures, such as loops and conditionals, are crucial in White Box Testing because they define how the program behaves under different conditions. Testing these structures ensures that the program behaves as expected, even in edge cases or when certain conditions are met.

Outlines

plate

Cette section est réservée aux utilisateurs payants. Améliorez votre compte pour accéder à cette section.

Améliorer maintenant

Mindmap

plate

Cette section est réservée aux utilisateurs payants. Améliorez votre compte pour accéder à cette section.

Améliorer maintenant

Keywords

plate

Cette section est réservée aux utilisateurs payants. Améliorez votre compte pour accéder à cette section.

Améliorer maintenant

Highlights

plate

Cette section est réservée aux utilisateurs payants. Améliorez votre compte pour accéder à cette section.

Améliorer maintenant

Transcripts

plate

Cette section est réservée aux utilisateurs payants. Améliorez votre compte pour accéder à cette section.

Améliorer maintenant
Rate This
★
★
★
★
★

5.0 / 5 (0 votes)

Étiquettes Connexes
Software TestingBlack BoxWhite BoxQA TechniquesTest MethodologiesTesting ApproachesError DetectionCyclomatic ComplexityPath TestingSoftware DevelopmentQuality Assurance
Besoin d'un résumé en anglais ?