SlideShare ist ein Scribd-Unternehmen logo
1 von 27
Testing Fundamentals
 Topics
–
–
–
–

covered

What is black-box and white-box testing
How static and dynamic testing differ
What high-level techniques can be used for
reviewing a product specification
What specific problems should look for when
reviewing a product specification in detail
Product Specification




The product specification is a written document using
words and pictures to describe the intended product.
Produce spec might read something like this for
Windows Calculator:
–

–

The Edit menu will have two selections: Copy and Paste. These can be chosen by one of
three methods: pointing and clicking to the menu items with the mouse, using accesskeys (Alt+E and then C for Copy and P for Paste), or using the standard Windows
shortcut keys of Ctrl+C for Copy and Ctrl+V for Paste.
The Copy function will copy the current entry displayed in the number text box into the
Windows Clipboard. The Paste function will paste the value stored in the Windows
Clipboard into the number text box.
Black-Box Testing





Black Box Testing is testing without knowledge of the
internal workings of the item being tested. For
example, when black box testing is applied to software
engineering, the tester would only know the "legal"
inputs and what the expected outputs should be, but
not how the program actually arrives at those outputs.
Black-box testing is sometimes referred to as
functional testing or behavioral testing.
The test planning for black-box can begin as soon as
the specifications are written.
Advantages of Black-Box Testing







more effective on larger units of code than glass box
testing
tester needs no knowledge of implementation,
including specific programming languages
tester and programmer are independent of each other
tests are done from a user's point of view
will help to expose any ambiguities or inconsistencies
in the specifications
test cases can be designed as soon as the
specifications are complete
Disadvantages of Black Box
Testing







only a small number of possible inputs can actually be tested, to
test every possible input stream would take nearly forever
without clear and concise specifications, test cases are hard to
design
there may be unnecessary repetition of test inputs if the tester is
not informed of test cases the programmer has already tried
may leave many program paths untested
cannot be directed toward specific segments of code which may
be very complex (and therefore more error prone)
most testing related research has been directed toward glass box
testing
Tests under Black-Box Testing




Equivalence partitioning: Equivalence partitioning is designed to
minimize the number of test cases by dividing tests in such a way
that the system is expected to act the same way for all tests of
each equivalence partition. Test inputs would be selected from
each partition.
Boundary value Analysis is a form of black box testing in which
input values at the boundaries of the input domain are tested. It
has been widely recognized that input values at the extreme ends
of, and just outside of, input domains tend to cause errors in
system functionality.
Tests under Black-Box Testing
(Cont..)
 Smoke

Test: A smoke test is a cursory
examination of all of the basic components of a
software system to ensure that they work.
Typically, smoke testing is conducted
immediately after a software build is made.
 The term comes from electrical engineering,
where in order to test electronic equipment,
power is applied and the tester ensures that
the product does not spark or smoke.
White-Box Testing








White-box testing is testing that takes into account the internal
mechanism of a system or component (IEEE, 1990).
White-box testing is also known as structural testing, clear box
testing, and glass box testing (Beizer, 1995).
In order to implement white box testing, the tester has to deal with
the code and hence is needed to possess knowledge of coding
and logic i.e. internal working of the code.
White box test also needs the tester to look into the code and find
out which unit/statement/chunk of the code is malfunctioning.
Advantages of White-Box Testing
 As

the knowledge of internal coding structure is
prerequisite, it becomes very easy to find out
which type of input/data can help in testing the
application effectively.
 The other advantage of white box testing is
that it helps in optimizing the code
 It helps in removing the extra lines of code,
which can bring in hidden defects.
Disadvantages of White-Box
Testing
 As

knowledge of code and internal structure is
a prerequisite, a skilled tester is needed to
carry out this type of testing, which increases
the cost.
 And it is nearly impossible to look into every bit
of code to find out hidden errors, which may
create problems, resulting in failure of the
application.
Types of testing under White/Glass
Box Testing Strategy






Unit Testing: The developer carries out unit testing in
order to check if the particular module or unit of code is
working fine.
Static and dynamic Analysis: Static analysis involves
going through the code in order to find out any possible
defect in the code. Dynamic analysis involves
executing the code and analyzing the output.
Statement Coverage: In this type of testing the code is
executed in such a manner that every statement of the
application is executed at least once. It helps in
assuring that all the statements execute without any
side effect.
Types of testing under White/Glass
Box Testing Strategy (cont..)






Branch Coverage: Branch coverage testing helps in
validating of all the branches in the code and making
sure that no branching leads to abnormal behavior of
the application.
Security Testing: Security Testing is carried out in
order to find out how well the system can protect itself
from unauthorized access, hacking – cracking, any
code damage etc.
Mutation Testing: A kind of testing in which, the
application is tested for the code that was modified
after fixing a particular bug/defect.
Performing a High-Level Review









Defining the Software Product is a difficult process.
The process is an inexact science and is prone to
having problems.
Examine the specification for large fundamental
problems.
It will give better understanding of what the software
should do.
Better understanding of the whys and hows behind
the specifications.
Pretend to be the Customer
A

tester is to pretend to be the customer when
received a specification for review.
 Do some research about who the customer will
be.
 Know about the end user.
 Find out who will be using the software and talk
to them.
Pretend to be the Customer (cont..)
 It

is important to understand the customer’s
expectations.
 Remember that the definition of quality
means “meeting the customer’s needs”.
 Tester must understand those needs to test.
 Tester is not necessary to be a domain expert
 Gaining some familiarity with the field the
software applies to would be a great help.
Pretend to be the Customer (cont..)
 During

the review if you don’t understand it,
don’t assume that it’s correct and go on.
 Eventually you will have to use specification to
design your test cases
 Finding bugs along the way is better.
 Don’t forget about software security.
 Security must be specified in details.
Research Existing Standards and
Guidelines
 Difference

between standards and guidelines
is a matter of degree.
 A standard is much more firm than a guideline.
 Standards should be strictly adhered to.
 Guidelines are optional but should be followed.
 As a tester your job is not to define what
guidelines and standards should be applied.
This lies with Project Manager.
Several examples of standards and
guidelines
 Corporate
–

If the software is tailored for a specific company, it
should adopt the common terms and conventions
used by the employees of that company.

 Industry
–

Terminology and Conventions:

Requirements:

Medical, pharmaceutical, industrial, and financial
industries have very strict standards that their
software must follow.
Several examples of standards and
guidelines






Government Standards:
– The government, especially the military, has strict
standards.
Graphical User Interface (GUI):
– There are published standards and guidelines of
Microsoft and Apple Macintosh Operating Systems
– How the software should look and fee to a user.
Security: Software and its interfaces and protocols
may need to meet certain security standards or levels.
Review and Test Similar Software




Some things to look for when reviewing competitive
products include:
Scale:
–
–
–



Fewer or greater features
Less or more code
Will that size difference matter in your testing?

Complexity:
–
–

More or less complex
Will this impact your testing?
Review and Test Similar Software
 Testability:
–

Will you have the resources, time, and expertise to
test software such as this?

 Quality/Reliability:
–
–

Is this software representative of the overall quality
planned for your software?
Will your software be more or less reliable?

 Security:
–

How does the competitor’s software security?
Review and Test Similar Software
 There
–
–
–

is no substitute for hands-on experience.

Use the similar software
Bang on it.
Demonstrate it.

 Gain

a lot of experience and it will help during
the review of specification.
Review and Test Similar Software
 Don’t

forget about reading online and printed
software reviews and articles about the
competitive software.
 This can be especially helpful for security
issues
 They will be well know in the press.
Low-Level Specification Test Techniques:
Specification Attributes Checklist







Complete. Is anything missing or forgotten? Is it
thorough? Does it include everything necessary to
make it stand alone?
Accurate. Is the proposed solution correct? Does it
properly define the goal? Are there any errors?
Precise, Unambiguous, and Clear. Is the description
exact and not vague? Is there a single interpretation?
Is it easy to read and understand?
Consistent. Is the description of the feature written so
that it doesn't conflict with itself or other items in the
specification?
Specification Attributes Checklist








Relevant. Is the statement necessary to specify the feature? Is it
extra information that should be left out? Is the feature traceable
to an original customer need?
Feasible. Can the feature be implemented with the available
personnel, tools, and resources within the specified budget and
schedule?
Code-free. Does the specification stick with defining the product
and not the underlying software design, architecture, and code?
Testable. Can the feature be tested? Is enough information
provided that a tester could create tests to verify its operation?
Specification Terminology Checklist






Always, Every, All, None, Never. If you see words
such as these that denote something as certain or
absolute, make sure that it is, indeed, certain. Put on
your tester's hat and think of cases that violate them.
Certainly, Therefore, Clearly, Obviously, Evidently.
These words tend to persuade you into accepting
something as a given. Don't fall into the trap.
Some, Sometimes, Often, Usually, Ordinarily,
Customarily, Most, Mostly. These words are too
vague. It's impossible to test a feature that operates
"sometimes."
Specification Terminology Checklist








Etc., And So Forth, And So On, Such As. Lists that finish with
words such as these aren't testable. Lists need to be absolute or
explained so that there's no confusion as to how the series is
generated and what appears next in the list.
Good, Fast, Cheap, Efficient, Small, Stable. These are
unquantifiable terms. They aren't testable. If they appear in a
specification, they must be further defined to explain exactly what
they mean.
Handled, Processed, Rejected, Skipped, Eliminated. These
terms can hide large amounts of functionality that need to be
specified.
If…Then…(but missing Else). Look for statements that have
"If…Then" clauses but don't have a matching "Else." Ask yourself
what will happen if the "if" doesn't happen.

Weitere ähnliche Inhalte

Was ist angesagt?

Was ist angesagt? (19)

Stm unit1
Stm unit1Stm unit1
Stm unit1
 
Testing
TestingTesting
Testing
 
Software Testing without Requirements: Survival Guide
Software Testing without Requirements: Survival GuideSoftware Testing without Requirements: Survival Guide
Software Testing without Requirements: Survival Guide
 
Software Testing
Software Testing Software Testing
Software Testing
 
Why test software
Why test softwareWhy test software
Why test software
 
Tlc
TlcTlc
Tlc
 
Software quality and testing (func. & non func.)
Software quality and testing (func. & non   func.)Software quality and testing (func. & non   func.)
Software quality and testing (func. & non func.)
 
Software testing
Software testingSoftware testing
Software testing
 
Types of software testing
Types of software testingTypes of software testing
Types of software testing
 
Checklist for website testing
Checklist for website testingChecklist for website testing
Checklist for website testing
 
Testing and types of Testing
Testing and types of TestingTesting and types of Testing
Testing and types of Testing
 
Learn Bug Reporting Techniques
Learn Bug Reporting TechniquesLearn Bug Reporting Techniques
Learn Bug Reporting Techniques
 
Test case design
Test case designTest case design
Test case design
 
Software coding and testing
Software coding and testingSoftware coding and testing
Software coding and testing
 
A Survey Of Agile Development Methodologies
A Survey Of Agile Development MethodologiesA Survey Of Agile Development Methodologies
A Survey Of Agile Development Methodologies
 
Defects in software testing
Defects in software testingDefects in software testing
Defects in software testing
 
Introduction to Software Testing
Introduction to Software TestingIntroduction to Software Testing
Introduction to Software Testing
 
Unit testing
Unit testing Unit testing
Unit testing
 
Test cases for effective testing - part 1
Test cases for effective testing - part 1Test cases for effective testing - part 1
Test cases for effective testing - part 1
 

Andere mochten auch (7)

Test-Driven Development (TDD)
Test-Driven Development (TDD)Test-Driven Development (TDD)
Test-Driven Development (TDD)
 
TDD - Agile
TDD - Agile TDD - Agile
TDD - Agile
 
An Introduction to Performance Testing
An Introduction to Performance TestingAn Introduction to Performance Testing
An Introduction to Performance Testing
 
Overview on TDD (Test Driven Development) & ATDD (Acceptance Test Driven Deve...
Overview on TDD (Test Driven Development) & ATDD (Acceptance Test Driven Deve...Overview on TDD (Test Driven Development) & ATDD (Acceptance Test Driven Deve...
Overview on TDD (Test Driven Development) & ATDD (Acceptance Test Driven Deve...
 
Introduction to performance testing
Introduction to performance testingIntroduction to performance testing
Introduction to performance testing
 
Performance and load testing
Performance and load testingPerformance and load testing
Performance and load testing
 
Test Driven Development (TDD)
Test Driven Development (TDD)Test Driven Development (TDD)
Test Driven Development (TDD)
 

Ähnlich wie Testing fundamentals

Testing Software Solutions
Testing Software SolutionsTesting Software Solutions
Testing Software Solutions
gavhays
 
Testing in Software Engineering.docx
Testing in Software Engineering.docxTesting in Software Engineering.docx
Testing in Software Engineering.docx
8759000398
 

Ähnlich wie Testing fundamentals (20)

WHITE BOX & BLACK BOX TESTING IN DATABASE
WHITE BOX & BLACK BOXTESTING IN DATABASEWHITE BOX & BLACK BOXTESTING IN DATABASE
WHITE BOX & BLACK BOX TESTING IN DATABASE
 
Software testing methods
Software testing methodsSoftware testing methods
Software testing methods
 
unittesting-190620114546 (1).pptx document
unittesting-190620114546 (1).pptx documentunittesting-190620114546 (1).pptx document
unittesting-190620114546 (1).pptx document
 
Coding and testing in Software Engineering
Coding and testing in Software EngineeringCoding and testing in Software Engineering
Coding and testing in Software Engineering
 
Software testing
Software testingSoftware testing
Software testing
 
Types of testing
Types of testingTypes of testing
Types of testing
 
Software testing
Software testingSoftware testing
Software testing
 
Software testing (2)
Software testing (2)Software testing (2)
Software testing (2)
 
Software testing strategies
Software testing strategiesSoftware testing strategies
Software testing strategies
 
White box & black box testing
White box & black box testingWhite box & black box testing
White box & black box testing
 
Software test life cycle
Software test life cycleSoftware test life cycle
Software test life cycle
 
Understanding Black Box Testing – Types, Techniques, and Examples.pdf
Understanding Black Box Testing – Types, Techniques, and Examples.pdfUnderstanding Black Box Testing – Types, Techniques, and Examples.pdf
Understanding Black Box Testing – Types, Techniques, and Examples.pdf
 
Learn Basic Of Software testing
Learn Basic Of Software testingLearn Basic Of Software testing
Learn Basic Of Software testing
 
Testing chapter updated (1)
Testing chapter updated (1)Testing chapter updated (1)
Testing chapter updated (1)
 
White-box testing.pptx
White-box testing.pptxWhite-box testing.pptx
White-box testing.pptx
 
Testing Software Solutions
Testing Software SolutionsTesting Software Solutions
Testing Software Solutions
 
Testing in Software Engineering.docx
Testing in Software Engineering.docxTesting in Software Engineering.docx
Testing in Software Engineering.docx
 
Testing concepts
Testing conceptsTesting concepts
Testing concepts
 
Object oriented sad 6
Object oriented sad 6Object oriented sad 6
Object oriented sad 6
 
Software testing basic
Software testing basicSoftware testing basic
Software testing basic
 

Mehr von Abdul Basit

Git Developer Cheatsheet
Git Developer CheatsheetGit Developer Cheatsheet
Git Developer Cheatsheet
Abdul Basit
 
Software testing lecture 10
Software testing lecture 10Software testing lecture 10
Software testing lecture 10
Abdul Basit
 
Software quality assurance lecture 1
Software quality assurance lecture 1Software quality assurance lecture 1
Software quality assurance lecture 1
Abdul Basit
 
Software measurement lecture 7
Software measurement lecture 7Software measurement lecture 7
Software measurement lecture 7
Abdul Basit
 
Planning for software quality assurance lecture 6
Planning for software quality assurance lecture 6Planning for software quality assurance lecture 6
Planning for software quality assurance lecture 6
Abdul Basit
 
Managing software quality in an organization lecture 3
Managing software quality in an organization lecture 3Managing software quality in an organization lecture 3
Managing software quality in an organization lecture 3
Abdul Basit
 
Function of software quality assurance lecture 2
Function of software quality assurance lecture 2Function of software quality assurance lecture 2
Function of software quality assurance lecture 2
Abdul Basit
 
Expectation from qms lecture 5
Expectation from qms lecture 5Expectation from qms lecture 5
Expectation from qms lecture 5
Abdul Basit
 
Capability maturity model cmm lecture 8
Capability maturity model cmm lecture 8Capability maturity model cmm lecture 8
Capability maturity model cmm lecture 8
Abdul Basit
 
Black box testing lecture 11
Black box testing lecture 11Black box testing lecture 11
Black box testing lecture 11
Abdul Basit
 
The role of the quality group in software development lecture 4
The role of the quality group in software development lecture 4The role of the quality group in software development lecture 4
The role of the quality group in software development lecture 4
Abdul Basit
 
Software requirements engineering
Software requirements engineeringSoftware requirements engineering
Software requirements engineering
Abdul Basit
 

Mehr von Abdul Basit (20)

Atlassian git cheatsheet
Atlassian git cheatsheetAtlassian git cheatsheet
Atlassian git cheatsheet
 
Github git-cheat-sheet
Github git-cheat-sheetGithub git-cheat-sheet
Github git-cheat-sheet
 
Testing the documentation
Testing the documentationTesting the documentation
Testing the documentation
 
Test planning
Test planningTest planning
Test planning
 
Test cases planning
Test cases planningTest cases planning
Test cases planning
 
Software Testing
Software TestingSoftware Testing
Software Testing
 
Black box testing
Black box testingBlack box testing
Black box testing
 
Software Automated testing and tools
Software Automated testing and toolsSoftware Automated testing and tools
Software Automated testing and tools
 
Git Developer Cheatsheet
Git Developer CheatsheetGit Developer Cheatsheet
Git Developer Cheatsheet
 
Software testing lecture 10
Software testing lecture 10Software testing lecture 10
Software testing lecture 10
 
Software quality assurance lecture 1
Software quality assurance lecture 1Software quality assurance lecture 1
Software quality assurance lecture 1
 
Software measurement lecture 7
Software measurement lecture 7Software measurement lecture 7
Software measurement lecture 7
 
Planning for software quality assurance lecture 6
Planning for software quality assurance lecture 6Planning for software quality assurance lecture 6
Planning for software quality assurance lecture 6
 
Managing software quality in an organization lecture 3
Managing software quality in an organization lecture 3Managing software quality in an organization lecture 3
Managing software quality in an organization lecture 3
 
Function of software quality assurance lecture 2
Function of software quality assurance lecture 2Function of software quality assurance lecture 2
Function of software quality assurance lecture 2
 
Expectation from qms lecture 5
Expectation from qms lecture 5Expectation from qms lecture 5
Expectation from qms lecture 5
 
Capability maturity model cmm lecture 8
Capability maturity model cmm lecture 8Capability maturity model cmm lecture 8
Capability maturity model cmm lecture 8
 
Black box testing lecture 11
Black box testing lecture 11Black box testing lecture 11
Black box testing lecture 11
 
The role of the quality group in software development lecture 4
The role of the quality group in software development lecture 4The role of the quality group in software development lecture 4
The role of the quality group in software development lecture 4
 
Software requirements engineering
Software requirements engineeringSoftware requirements engineering
Software requirements engineering
 

Kürzlich hochgeladen

Beyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactBeyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global Impact
PECB
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
QucHHunhnh
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
ciinovamais
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
QucHHunhnh
 

Kürzlich hochgeladen (20)

IGNOU MSCCFT and PGDCFT Exam Question Pattern: MCFT003 Counselling and Family...
IGNOU MSCCFT and PGDCFT Exam Question Pattern: MCFT003 Counselling and Family...IGNOU MSCCFT and PGDCFT Exam Question Pattern: MCFT003 Counselling and Family...
IGNOU MSCCFT and PGDCFT Exam Question Pattern: MCFT003 Counselling and Family...
 
Beyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactBeyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global Impact
 
Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3
 
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAPM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across Sectors
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 
Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1
 
Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy Consulting
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdf
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdf
 
9548086042 for call girls in Indira Nagar with room service
9548086042  for call girls in Indira Nagar  with room service9548086042  for call girls in Indira Nagar  with room service
9548086042 for call girls in Indira Nagar with room service
 
Sports & Fitness Value Added Course FY..
Sports & Fitness Value Added Course FY..Sports & Fitness Value Added Course FY..
Sports & Fitness Value Added Course FY..
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy Reform
 
Measures of Dispersion and Variability: Range, QD, AD and SD
Measures of Dispersion and Variability: Range, QD, AD and SDMeasures of Dispersion and Variability: Range, QD, AD and SD
Measures of Dispersion and Variability: Range, QD, AD and SD
 
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104
 

Testing fundamentals

  • 1. Testing Fundamentals  Topics – – – – covered What is black-box and white-box testing How static and dynamic testing differ What high-level techniques can be used for reviewing a product specification What specific problems should look for when reviewing a product specification in detail
  • 2. Product Specification   The product specification is a written document using words and pictures to describe the intended product. Produce spec might read something like this for Windows Calculator: – – The Edit menu will have two selections: Copy and Paste. These can be chosen by one of three methods: pointing and clicking to the menu items with the mouse, using accesskeys (Alt+E and then C for Copy and P for Paste), or using the standard Windows shortcut keys of Ctrl+C for Copy and Ctrl+V for Paste. The Copy function will copy the current entry displayed in the number text box into the Windows Clipboard. The Paste function will paste the value stored in the Windows Clipboard into the number text box.
  • 3. Black-Box Testing    Black Box Testing is testing without knowledge of the internal workings of the item being tested. For example, when black box testing is applied to software engineering, the tester would only know the "legal" inputs and what the expected outputs should be, but not how the program actually arrives at those outputs. Black-box testing is sometimes referred to as functional testing or behavioral testing. The test planning for black-box can begin as soon as the specifications are written.
  • 4. Advantages of Black-Box Testing       more effective on larger units of code than glass box testing tester needs no knowledge of implementation, including specific programming languages tester and programmer are independent of each other tests are done from a user's point of view will help to expose any ambiguities or inconsistencies in the specifications test cases can be designed as soon as the specifications are complete
  • 5. Disadvantages of Black Box Testing       only a small number of possible inputs can actually be tested, to test every possible input stream would take nearly forever without clear and concise specifications, test cases are hard to design there may be unnecessary repetition of test inputs if the tester is not informed of test cases the programmer has already tried may leave many program paths untested cannot be directed toward specific segments of code which may be very complex (and therefore more error prone) most testing related research has been directed toward glass box testing
  • 6. Tests under Black-Box Testing   Equivalence partitioning: Equivalence partitioning is designed to minimize the number of test cases by dividing tests in such a way that the system is expected to act the same way for all tests of each equivalence partition. Test inputs would be selected from each partition. Boundary value Analysis is a form of black box testing in which input values at the boundaries of the input domain are tested. It has been widely recognized that input values at the extreme ends of, and just outside of, input domains tend to cause errors in system functionality.
  • 7. Tests under Black-Box Testing (Cont..)  Smoke Test: A smoke test is a cursory examination of all of the basic components of a software system to ensure that they work. Typically, smoke testing is conducted immediately after a software build is made.  The term comes from electrical engineering, where in order to test electronic equipment, power is applied and the tester ensures that the product does not spark or smoke.
  • 8. White-Box Testing     White-box testing is testing that takes into account the internal mechanism of a system or component (IEEE, 1990). White-box testing is also known as structural testing, clear box testing, and glass box testing (Beizer, 1995). In order to implement white box testing, the tester has to deal with the code and hence is needed to possess knowledge of coding and logic i.e. internal working of the code. White box test also needs the tester to look into the code and find out which unit/statement/chunk of the code is malfunctioning.
  • 9. Advantages of White-Box Testing  As the knowledge of internal coding structure is prerequisite, it becomes very easy to find out which type of input/data can help in testing the application effectively.  The other advantage of white box testing is that it helps in optimizing the code  It helps in removing the extra lines of code, which can bring in hidden defects.
  • 10. Disadvantages of White-Box Testing  As knowledge of code and internal structure is a prerequisite, a skilled tester is needed to carry out this type of testing, which increases the cost.  And it is nearly impossible to look into every bit of code to find out hidden errors, which may create problems, resulting in failure of the application.
  • 11. Types of testing under White/Glass Box Testing Strategy    Unit Testing: The developer carries out unit testing in order to check if the particular module or unit of code is working fine. Static and dynamic Analysis: Static analysis involves going through the code in order to find out any possible defect in the code. Dynamic analysis involves executing the code and analyzing the output. Statement Coverage: In this type of testing the code is executed in such a manner that every statement of the application is executed at least once. It helps in assuring that all the statements execute without any side effect.
  • 12. Types of testing under White/Glass Box Testing Strategy (cont..)    Branch Coverage: Branch coverage testing helps in validating of all the branches in the code and making sure that no branching leads to abnormal behavior of the application. Security Testing: Security Testing is carried out in order to find out how well the system can protect itself from unauthorized access, hacking – cracking, any code damage etc. Mutation Testing: A kind of testing in which, the application is tested for the code that was modified after fixing a particular bug/defect.
  • 13. Performing a High-Level Review      Defining the Software Product is a difficult process. The process is an inexact science and is prone to having problems. Examine the specification for large fundamental problems. It will give better understanding of what the software should do. Better understanding of the whys and hows behind the specifications.
  • 14. Pretend to be the Customer A tester is to pretend to be the customer when received a specification for review.  Do some research about who the customer will be.  Know about the end user.  Find out who will be using the software and talk to them.
  • 15. Pretend to be the Customer (cont..)  It is important to understand the customer’s expectations.  Remember that the definition of quality means “meeting the customer’s needs”.  Tester must understand those needs to test.  Tester is not necessary to be a domain expert  Gaining some familiarity with the field the software applies to would be a great help.
  • 16. Pretend to be the Customer (cont..)  During the review if you don’t understand it, don’t assume that it’s correct and go on.  Eventually you will have to use specification to design your test cases  Finding bugs along the way is better.  Don’t forget about software security.  Security must be specified in details.
  • 17. Research Existing Standards and Guidelines  Difference between standards and guidelines is a matter of degree.  A standard is much more firm than a guideline.  Standards should be strictly adhered to.  Guidelines are optional but should be followed.  As a tester your job is not to define what guidelines and standards should be applied. This lies with Project Manager.
  • 18. Several examples of standards and guidelines  Corporate – If the software is tailored for a specific company, it should adopt the common terms and conventions used by the employees of that company.  Industry – Terminology and Conventions: Requirements: Medical, pharmaceutical, industrial, and financial industries have very strict standards that their software must follow.
  • 19. Several examples of standards and guidelines    Government Standards: – The government, especially the military, has strict standards. Graphical User Interface (GUI): – There are published standards and guidelines of Microsoft and Apple Macintosh Operating Systems – How the software should look and fee to a user. Security: Software and its interfaces and protocols may need to meet certain security standards or levels.
  • 20. Review and Test Similar Software   Some things to look for when reviewing competitive products include: Scale: – – –  Fewer or greater features Less or more code Will that size difference matter in your testing? Complexity: – – More or less complex Will this impact your testing?
  • 21. Review and Test Similar Software  Testability: – Will you have the resources, time, and expertise to test software such as this?  Quality/Reliability: – – Is this software representative of the overall quality planned for your software? Will your software be more or less reliable?  Security: – How does the competitor’s software security?
  • 22. Review and Test Similar Software  There – – – is no substitute for hands-on experience. Use the similar software Bang on it. Demonstrate it.  Gain a lot of experience and it will help during the review of specification.
  • 23. Review and Test Similar Software  Don’t forget about reading online and printed software reviews and articles about the competitive software.  This can be especially helpful for security issues  They will be well know in the press.
  • 24. Low-Level Specification Test Techniques: Specification Attributes Checklist     Complete. Is anything missing or forgotten? Is it thorough? Does it include everything necessary to make it stand alone? Accurate. Is the proposed solution correct? Does it properly define the goal? Are there any errors? Precise, Unambiguous, and Clear. Is the description exact and not vague? Is there a single interpretation? Is it easy to read and understand? Consistent. Is the description of the feature written so that it doesn't conflict with itself or other items in the specification?
  • 25. Specification Attributes Checklist     Relevant. Is the statement necessary to specify the feature? Is it extra information that should be left out? Is the feature traceable to an original customer need? Feasible. Can the feature be implemented with the available personnel, tools, and resources within the specified budget and schedule? Code-free. Does the specification stick with defining the product and not the underlying software design, architecture, and code? Testable. Can the feature be tested? Is enough information provided that a tester could create tests to verify its operation?
  • 26. Specification Terminology Checklist    Always, Every, All, None, Never. If you see words such as these that denote something as certain or absolute, make sure that it is, indeed, certain. Put on your tester's hat and think of cases that violate them. Certainly, Therefore, Clearly, Obviously, Evidently. These words tend to persuade you into accepting something as a given. Don't fall into the trap. Some, Sometimes, Often, Usually, Ordinarily, Customarily, Most, Mostly. These words are too vague. It's impossible to test a feature that operates "sometimes."
  • 27. Specification Terminology Checklist     Etc., And So Forth, And So On, Such As. Lists that finish with words such as these aren't testable. Lists need to be absolute or explained so that there's no confusion as to how the series is generated and what appears next in the list. Good, Fast, Cheap, Efficient, Small, Stable. These are unquantifiable terms. They aren't testable. If they appear in a specification, they must be further defined to explain exactly what they mean. Handled, Processed, Rejected, Skipped, Eliminated. These terms can hide large amounts of functionality that need to be specified. If…Then…(but missing Else). Look for statements that have "If…Then" clauses but don't have a matching "Else." Ask yourself what will happen if the "if" doesn't happen.