ISTQB / ISEB Foundation Exam Practice 4 Dynamic test techniques

Slides:



Advertisements
Similar presentations
Verification and Validation
Advertisements

Damian Gordon.  Static Testing is the testing of a component or system at a specification or implementation level without execution of the software.
Software Engineering-II Sir zubair sajid. What’s the difference? Verification – Are you building the product right? – Software must conform to its specification.
Static Technique. Static Technique - Review  A way of testing software work products  Program code, requirement spec., design spec.  Test plan, test.
Testing Without Executing the Code Pavlina Koleva Junior QA Engineer WinCore Telerik QA Academy Telerik QA Academy.
1 Static Testing: defect prevention SIM objectives Able to list various type of structured group examinations (manual checking) Able to statically.
©Ian Sommerville 2000Software Engineering, 6th edition. Chapter 19Slide 1 Verification and Validation l Assuring that a software system meets a user's.
SE 555 Software Requirements & Specification Requirements Validation.
CSC 395 – Software Engineering Lecture 9: Testing -or- How I Stopped Worrying and Learned to Love the Bug.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 22 Slide 1 Verification and Validation.
Chapter 24 - Quality Management 1Chapter 24 Quality management.
 QUALITY ASSURANCE:  QA is defined as a procedure or set of procedures intended to ensure that a product or service under development (before work is.
Verification and Validation
Software System Integration
Design Reviews Peer Reviews. Agenda Peer Reviews Participants of Peer Review Preparation for a Peer Review Session The Peer Review Session Post-peer Review.
1CMSC 345, Version 4/04 Verification and Validation Reference: Software Engineering, Ian Sommerville, 6th edition, Chapter 19.
OHT 4.1 Galin, SQA from theory to implementation © Pearson Education Limited 2004 Software Quality assurance (SQA) SWE 333 Dr Khalid Alnafjan
Static testing Elena Rudovol February, 13, Sitecore. Compelling Web Experiences Page 2 What is static testing? Static Testing do.
CSCI 5801: Software Engineering
Software Testing Verification and validation planning Software inspections Software Inspection vs. Testing Automated static analysis Cleanroom software.
©Ian Sommerville 2000Software Engineering, 6th edition. Chapter 19Slide 1 Verification and Validation l Assuring that a software system meets a user's.
Verification and Validation Yonsei University 2 nd Semester, 2014 Sanghyun Park.
University of Palestine software engineering department Testing of Software Systems Fundamentals of testing instructor: Tasneem Darwish.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 22 Slide 1 Verification and Validation.
Test Organization and Management
CS 501: Software Engineering Fall 1999 Lecture 16 Verification and Validation.
Lecture 16 Formal Technical Reviews (FTRs) (also know as inspections) FOR0383 Software Quality Assurance 9/19/20151Dr Andy Brooks Don´t review in your.
Software Inspection A basic tool for defect removal A basic tool for defect removal Urgent need for QA and removal can be supported by inspection Urgent.
Phil Cronin Anne Hill Allen Schones CIS841 Summer on Campus 1998 IN-PROCESS INSPECTIONS FOR OBJECT ORIENTED DESIGNS.
Verification and Validation Chapter 22 of Ian Sommerville’s Software Engineering.
Software Testing Testing types Testing strategy Testing principles.
CS.436 Software Engineering By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 13 Verification and validation Slide 1 1 Chapter 13 Verification and Validation.
CS 350, slide set 5 M. Overstreet Old Dominion University Spring 2005.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 22 Slide 1 Software Verification, Validation and Testing.
Software Testing and Maintenance 1 Code Review  Introduction  How to Conduct Code Review  Practical Tips  Tool Support  Summary.
©Ian Sommerville 2000Software Engineering, 6th edition. Chapter 19Slide 1 Chapter 19 Verification and Validation.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 22 Slide 1 Bzupages.com Verification and Validation.
Chapter 12: Software Inspection Omar Meqdadi SE 3860 Lecture 12 Department of Computer Science and Software Engineering University of Wisconsin-Platteville.
The Software Development Process
Software Engineering, 8th edition Chapter 22 1 Courtesy: ©Ian Somerville 2006 April 27 th, 2009 Lecture # 19 Verification and Validation.
Unit III Static Testing. static testing Testing of a component or system at requirements or implementation level without execution of any software, e.g.,
1 These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 5/e and are provided with permission by.
Software Engineering1  Verification: The software should conform to its specification  Validation: The software should do what the user really requires.
© Michael Crosby and Charles Sacker, 2001 Systematic Software Reviews Software reviews are a “quality improvement process for written material”.
Advances In Software Inspection
CS223: Software Engineering Lecture 21: Unit Testing Metric.
References & User group Reference: Software Testing and Analysis Mauro Pezze Software Engineering Ian Sommerville Eight Edition (2007) User group:
Software Project Management Lecture # 12. Outline Quality Management ( chapter 26 - Pressman )  SQA  Who does it?  SQA Activities  Software reviews.
Verification vs. Validation Verification: "Are we building the product right?" The software should conform to its specification.The software should conform.
©Ian Sommerville 2006Software Engineering, 8th edition. Chapter 22 Slide 1 Verification and Validation.
SOFTWARE TESTING TRAINING TOOLS SUPPORT FOR SOFTWARE TESTING Chapter 6 immaculateres 1.
Verification and Validation
PREPARED BY G.VIJAYA KUMAR ASST.PROFESSOR
SOFTWARE TESTING Date: 29-Dec-2016 By: Ram Karthick.
CIS 375 Bruce R. Maxim UM-Dearborn
CSC 480 Software Engineering
Verification and Validation
Verification and Testing
Verification and Validation
Types of Testing Visit to more Learning Resources.
Verification and Validation
Verification and Validation
Software testing strategies 2
Fundamental Test Process
Introducing ISTQB Agile Foundation Extending the ISTQB Program’s Support Further Presented by Rex Black, CTAL Copyright © 2014 ASTQB 1.
Applied Software Project Management
Dr. Rob Hasker SE 3800 Note 9 Reviews.
NASA Secure Coding Rules
QA Reviews Lecture # 6.
Presentation transcript:

ISTQB / ISEB Foundation Exam Practice 4 Dynamic test techniques Software Testing ISTQB / ISEB Foundation Exam Practice Chapter 3 Static Testing 1 Principles 2 Lifecycle 3 Static testing 4 Dynamic test techniques 5 Management 6 Tools

Contents Reviews and the test process Types of review Static analysis

Static techniques do not execute code People techniques individual: desk-checking, data-stepping, proof-reading group: Reviews (informal & formal): for consensus Walkthrough: for education Inspection (most formal): to find faults Static techniques do not execute code

Benefits of reviews Development productivity improvement Reduced development timescales Reduced testing time and cost Lifetime cost reductions Reduced fault levels Improved customer relations etc.

Reviews are cost-effective 10 times reduction in faults reaching test, testing cost reduced by 50% to 80% Handbook of Walkthroughs, Inspections & Technical Reviews - Freedman & Weinberg reduce faults by a factor of 10 Structured Walkthroughs - Yourdon

25% reduction in schedules, remove 80% - 95% of faults at each stage, 28 times reduction in maintenance cost, many others Software Inspection - Gilb & Graham

What can be Inspected? Anything written down can be Inspected policy, strategy, business plans, marketing or advertising material, contracts system requirements, feasibility studies, acceptance test plans test plans, test designs, test cases, test results

system designs, logical & physical software code user manuals, procedures, training material

What can be reviewed? anything which could be Inspected i.e. anything written down plans, visions, “big picture”, strategic directions, ideas project progress work completed to schedule, etc. “Should we develop this” marketing options

What to review / Inspect? Tests Requirements Design Code Functions Integration T Unit Test Accept. Test System Test Tests Tests Tests

Costs of reviews Rough guide: 5%-15% of development effort half day a week is 10% Effort required for reviews planning (by leader / moderator) preparation / self-study checking meeting fixing / editing / follow-up recording & analysis of statistics / metrics process improvement (should!)

Reviews and the test process Types of review Static analysis Static testing 1 2 3 ISTQB / ISEB Foundation Exam Practice 4 5 6 Contents Reviews and the test process Types of review Static analysis

Types of review of documents Informal Review undocumented widely viewed as useful and cheap (but no one can prove it!) A helpful first step for chaotic organisations. Technical Review: (or peer review) includes peer and technical experts, no management participation. Normally documented, fault-finding. Can be rather subjective. 48

Decision-making Review: group discusses document and makes a decision about the content, e.g. how something should be done, go or no-go decision, or technical comments

Types of review of documents Walkthrough author guides the group through a document and his or her thought processes, so all understand the same thing, consensus on changes to make Inspection: formal individual and group checking, using sources and standards, according to generic and specific rules and checklists, using entry and exit criteria, Leader must be trained & certified, metrics required 48

Reviews in general 1 Objectives / goals validation & verification against specifications & standards achieve consensus (excluding Inspection) process improvement (ideal, included in Inspection)

Reviews in general 2 Activities planning overview / kick-off meeting (Inspection) preparation / individual checking review meeting (not always) follow-up (for some types) metrics recording & analysis (Inspections and sometimes reviews)

Reviews in general 3 Roles and responsibilities Leader / moderator - plans the review / Inspection, chooses participants, helps & encourages, conducts the meeting, performs follow-up, manages metrics Author of the document being reviewed / Inspected

Reviewers / Inspectors - specialised fault-finding roles for Inspection Managers - excluded from some types of review, need to plan project time for review / Inspection Others: e.g. Inspection/ review Co-ordinator

Reviews in general 4 Deliverables Changes (edits) in review product Change requests for source documents (predecessor documents to product being reviewed / Inspected) Process improvement suggestions to the review / Inspection process to the development process which produced the product just reviewed / Inspected Metrics (Inspection and some types of review)

Reviews in general 5 Pitfalls (they don’t always work!) lack of training in the technique (especially Inspection, the most formal) lack of or quality of documentation - what is being reviewed / Inspected

Lack of management support - “lip service” - want them done, but don’t allow time for them to happen in project schedules Failure to improve processes (gets disheartening just getting better at finding the same thing over again)

Inspection is different the document to be reviewed is given out in advance typically dozens of pages to review instructions are "please review this" not just product, sources chunk or sample training, roles

Inspection is different some people have time to look through it and make comments before the meeting (which is difficult to arrange) the meeting often lasts for hours entry criteria to meeting, may not be worth holding 2 max., often much shorter

Inspection is different "I don't like this" much discussion, some about technical approaches, some about trivia don't really know if it was worthwhile, but we keep doing it Rule violations, objective, not subjective no discussion, highly focused, anti-trivia only do it if value is proven (continually)

Inspection is more and better entry criteria training optimum checking rate prioritising the words standards process improvement exit criteria quantified estimates of remaining major faults per page effectiveness return on investment 10 - 20% unknown typical review early Inspection 30 - 40% 6 - 8 hrs / Insp hr mature Inspection 80 - 95% 8 - 30 hrs / Insp hr

The Inspection Process Change Request Process Improvement Software Development Stage Entry . Planning Kick off Next Software Development Stage Exit Ind Chk Meet Edit .

At first glance .. Here’s a document: review this (or Inspect it)

Reviews: time and size determine rate 2 hrs? Time 100 pages? Checking Rate Checking Rate Size 50 pages per hour

Review “Thoroughness”? major minor minor ordinary “review” - finds some faults, one major, fix them, consider the document now corrected and OK

Inspection: time and rate determine size 2 hrs? Time Optimum: 1 page* per hour Checking Rate Size Size 2 pages (at optimum rate) * 1 page = 300 important words

Inspection Thoroughness Inspection can find deep-seated faults: all of that type can be corrected but needs optimum checking rate

Inspection surprises Fundamental importance of Rules democratically agreed as applying define major issues / faults Slow checking rates Strict entry & exit criteria Fast logging rates Amount of responsibility given to author 56

Contents Reviews and the test process Types of review Static analysis

What can static analysis do What can static analysis do? Remember: static techniques do not execute the code A form of automated testing check for violations of standards check for things which may be a fault

Descended from compiler technology a compiler statically analyses code, and “knows” a lot about it, e.g. variable usage; finds syntax faults static analysis tools extend this knowledge can find unreachable code, undeclared variables, parameter type mis-matches, uncalled functions & procedures, array bound violations, etc.

Data flow analysis This is the study of program variables variable defined* where a value is stored into it variable used where the stored value is accessed variable is undefined before it is defined or when it goes out of scope x is defined, y and z are used x = y + z IF a > b THEN read(S) a and b are used, S is defined *defined should not be confused with declared

Data flow analysis faults read (x) n := 1 while x > y do begin read (y) write( n*y) x := x - n end Data flow anomaly: n is re-defined without being used Data flow fault: y is used before it has been defined (first time around the loop)

Control flow analysis Highlights: nodes not accessible from start node infinite loops multiple entry to loops whether code is well structured, i.e. reducible whether code conforms to a flowchart grammar any jumps to undefined labels any labels not jumped to cyclomatic complexity and other metrics

Unreachable code example Macro definitions (different for different platforms the code runs on) Buffsize: 1000 Mailboxmax: 1000 IF Buffsize < Mailboxmax THEN Error-Exit ENDIF

Static Analysis finds the THEN clause unreachable, so will flag a fault

Cyclomatic complexity cyclomatic complexity is a measure of the complexity of a flow graph (and therefore the code that the flow graph represents) the more complex the flow graph, the greater the measure it can most easily be calculated as: complexity = number of decisions + 1

Which flow graph is most complex? What is the cyclomatic complexity? 1 3 5 2

Example control flow graph init do Pseudo-code: Result = 0 Right = 0 DO WHILE more Questions IF Answer = Correct THEN Right = Right + 1 ENDIF END DO Result = (Right / Questions) IF Result > 60% THEN Print "pass" ELSE Print "fail” if r=r+1 end res if pass fail end

Other static metrics lines of code (LOC) operands & operators (Halstead’s metrics) fan-in & fan-out nesting levels function calls OO metrics: inheritance tree depth, number of methods, coupling & cohesion

Limitations and advantages cannot distinguish "fail-safe" code from programming faults or anomalies (often creates overload of spurious error messages) does not execute the code, so not related to operating conditions Advantages: can find faults difficult to "see" gives objective quality assessment of code

Summary: Key Points Reviews help to find faults in development and test documentation, and should be applied early Types of review: informal, walkthrough, technical / peer review, Inspection Static analysis can find faults and give information about code without executing it