Development World

Working harder is not the answer…

Part 1: Testing Fundamentals

   Testing definition
   Testing objective
   Types of testing
   Level of testing 

1- Introduction  

Quality of today’s software….The average software product released on the market is not error free….!
We need to specify the desired behavior first before project start

2- Testing Definition 

What is Testing?

Testing is the process of finding the differences between the expected behavior specified by system model and the observed of the implemented system.
Testing is the process of executing program with the intent of finding errors (Glen Myers)

3- Testing Objective   

What are we looking for?

  • Failure, error, fault , defect , bug , inconsistency.
  • System shouldn’t do –XXX-but it do it.
  • System should do -XXX-but it didn’t do it.
  • System is hard to use , complex , slow…. .

My Goal as a tester To find if the product “Not operation as intended

How do we deal with Errors and Faults?

  • Error prevention (before the system is released):
    • Use good programming methodology to reduce complexity
    • Use version control to prevent inconsistent system
    • Apply verification to prevent algorithmic bugs
  • Error detection(while system is running):
    •  Testing: Create failures in a planned way
    • Debugging: Start with an unplanned failures
    • Monitoring: Deliver information about state. Find performance bug
  • Error recovery(recover from failure once the system is released):
    • Data base systems (atomic transactions)
    • Modular redundancy
    • Recovery blocks

Reasons for bugs

  • System specification
  • System design
  • Coding
  • Other reasons
    • Product specification
    • Lack of resources
    • Lack of user involvement
    • Unrealistic expectation

 Cost of Repair


5-  Types Of Testing  



5.1 Black box testing 



5.1.1 Static Black Box Testing
Testing the specification

5.1.2 Dynamic Black Box Testing
Behavioral Testing: Testing a running program without any knowledge of how the software behaves

Test to pass
Test-to-Pass approach is where test cases are developed to clarify if the software produced fundamentally works in ordinary circumstances.

Test to fail
Test-to-Fail approach is where test cases are run to break the software

Equivalence Partitioning
This is a process of methodically reducing the huge set of possible test cases into a much smaller, but still equally effective, set.
Equivalence partitioning provides a systematic means for selecting the values that matter and ignoring the ones that don’t

Data Testing
Data testing is performing tests to check the information a user inputs and the results that are received.

  • Boundary Conditions: Test data by inputting the boundary values
  • Invalid data: Provide invalid data to the software to check if the software still works. Example of a Test-to-fail condition
  • State Transitions: This is testing a program’s logic flow through its various states

The process of re-running test cases to ensure that changes have not propagated unintended side effects

5.2 White box testing  


5.2.1 Static White Box Testing

Code review and analysis

  • Formal Reviews: Detailed rigorous inspection of code to identify problems and decide to follow rules
  • Peer Reviews: An informal meeting between the programmer and other programmers, getting together to discuss the code.
  • Walkthroughs: A formal presentation given by the programmer to a group of other programmers & testers, explaining code, its purpose and reason. Key points covered would be to summarize the inputs and how bugs would be addressed.

The code would be reviewed by a number of other programmers from a different perspective thus help to identify different bugs

Coding Standards
Guidelines are adopted for coding standards contains recommendations, for the preferred way of doing things.

Generic Code review checklist

  • Data Reference Errors: To identify bugs caused by a variable, constant, array, string or record.
  • Data Declaration Errors: To identify improper declaration, usage of variables and constants.
  • Computation Errors:  To identify calculations that don’t result in the expected result
  • Comparison Errors: To identify errors in usage of less than, equal, not equal, true, false comparators
  • Control Flow Errors: To identify errors in usage of loops
  • Input/Output Errors: To identify errors due to improper usage of input/output statements

5.2.2 Dynamic White Box Testing

Structural testing
This testing is using information you gain from seeing what the code does and how it works to determine what to test, what not to test, and how to approach the testing.

Unit Testing

  • Data Coverage: Divide the code into data and its states
  • Data flow: Track a piece of data completely through the software
  • Code coverage
    •  Program and Line Coverage
    •  Branch Coverage
    •  Condition Coverage

6- Levels Of Testing

Unit Testing 

  • Decompose the system into Individual subsystem
  • Goal:Confirm that subsystems is correctly coded and carries out the intended functionality
  • Testing each subsystem separately using needed stuband driver

 Integration testing

  • Groups of subsystems (collection of classes) and eventually the entire system
  • Goal:Test the interface among the subsystem
  • Used technique:  
    • Big Bang approach
    • Bottom Up approach
    • Top Down approach
    • Mixed approach (Sandwich approach)

System Testing

  • The entire system
  • Goal: Determine if the system meets the requirements (functional and Non-functional)
  • Used technique
    • Functional testing
    • Performance testing (stress testing , Volume testing, Security testing , Timing testing ,Recovery testing, configuration testing, load testing)
    • Pilot testing (Monkey testing –ad hook testing )
    • Acceptance testing
    • Installation testing
    • Documentation testing


No comments yet.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: