SlideShare uma empresa Scribd logo
1 de 24
Baixar para ler offline
 
 
 
rent Session 
 
Presented by: 
Gregor  Pope 
Lawrence  onal Labs 
 
 
Brought to you by: 
 
 
340 Corporate Way, Suite   Orange Park, FL 32073 
888‐2
T4 
Concur
4/8/2014   
10:30 AM 
 
 
 
 
“Billion Dollar Bugs: When and How to  
Test a Spreadsheet” 
 
 
y
Livermore Nati
 
 
 
 
 
 
300,
68‐8770 ∙ 904‐278‐0524 ∙ sqeinfo@sqe.com ∙ www.sqe.com 
Gregory Pope
Lawrence Livermore
National Labs
 
With more than forty years of experience developing software in the commercial and
government sectors, Greg Pope has held positions from programmer to CEO. Greg
currently works for the Lawrence Livermore National Laboratory as a software quality
engineering group leader and V&V project leader for advanced simulation and
computing and other energy related projects. Previously, he founded and ran a
software testing company and patented automated software testing tools. An ASQ
certified Software Quality Engineer, Greg has held management and technical
positions involved with mission critical testing of military systems and development of
software codes for electronic countermeasures, telemetry, and data acquisition
systems for flight and experimental testing of aircraft and jet engines.
 
2/18/2014
1
STARCanada
Gregory Pope, CSQE
April 8 2014April 8, 2014
Toronto, Ontario, Canada
LLNL-PRES-648155
This work was performed under the auspices of the U.S. Department
of Energy by Lawrence Livermore National Laboratory under contract
DE-AC52-07NA27344. Lawrence Livermore National Security, LLC
Fidelity Minus Sign Mistake 1/1995 ……………………………………………$2.6 Billion
TransAlta “Clerical Error” 6/2003 $24 MillionTransAlta Clerical Error 6/2003 ……………………………………………….$24 Million
Fannie Mae “Honest” Mistake 10/2003 ……………………………………….$1.3 Billion
University of Toledo Projected Revenue 5/2004 ……………………………..$2.4 Million
Red Envelope 3/2005 …………………………………………………Shares plunge 28%
Think and Do 3/2005 ……number of bachelor degrees 11% instead of 20% in Virginia
K d k R t t 11/2005 $11 Milli
Lawrence Livermore National Laboratory LLNL-PRES-648155
2
Kodak Restates 11/2005 severance pay error ……………………................$11 Million
Westpac Profit 11/2005….............................Trading halted for early release of profits
Eight of the Worst Spreadsheet Blunders, Thomas Wailgum, August 17, 2007
http://www.cio.com/article/131500/Eight_of_the_Worst_Spreadsheet_Blunders?page=1&taxonomyId=3000
2/18/2014
2
Copy from master spreadsheet to one for
accountantaccountant
Accountant omitted a minus sign from a $1.3B
capital loss, so it was counted as a capital gain.
The net error was the dividend estimate was
$2.6B too high
Lawrence Livermore National Laboratory LLNL-PRES-648155
3
$2.6B too high
Lesson Learned – Differentiate gain and losses,
have independent check
Canadian company bought more power than
needed from US company at a higher priceneeded from US company at a higher price.
Cut and paste error not caught on spreadsheet
during sort and ranking of bids.
Lesson learned: Have another employee double
check documentation
Lawrence Livermore National Laboratory LLNL-PRES-648155
4
check documentation
2/18/2014
3
Mistakes made in implementation of new
accounting standardaccounting standard.
Lesson learned: Have a financial peer review
the documentation.
Lawrence Livermore National Laboratory LLNL-PRES-648155
5
Typo in formula overstated the funds available
for usefor use.
Lesson learned: Extra scrutiny and review. User
training.
Lawrence Livermore National Laboratory LLNL-PRES-648155
6
2/18/2014
4
Overestimation of gross margins led to forth
quarter over projection of profitsquarter over projection of profits.
Number misrecorded in cell.
Lesson learned: More quality control
Lawrence Livermore National Laboratory LLNL-PRES-648155
7
Researchers at Virginia Tech cut and paste error
causing the number of population over 25 withcausing the number of population over 25 with
bachelors degrees in a region to be lower than
actual.
Lesson learned: Have another employee check
the work
Lawrence Livermore National Laboratory LLNL-PRES-648155
8
2/18/2014
5
Over stated severance pay due. Error was on
one employee’s severance pay there were tooone employee s severance pay, there were too
many zeros.
Lesson learned: Lack of data quality control
Lawrence Livermore National Laboratory LLNL-PRES-648155
9
Released the results of next quarter profits early
by putting them into an existing spreadsheet andby putting them into an existing spreadsheet and
then hiding them by making the cell fill black.
Lesson learned: Additional training.
Lawrence Livermore National Laboratory LLNL-PRES-648155
10
2/18/2014
6
More Independent checks70% More Independent checks
More Training
Differentiate Gain and Loss
70%
20%
10%
Lawrence Livermore National Laboratory LLNL-PRES-648155
11
Differentiate Gain and Loss10%
Based on: Eight of the Worst Spreadsheet Blunders, Thomas Wailgum, August 17, 2007
http://www.cio.com/article/131500/Eight_of_the_Worst_Spreadsheet_Blunders?page=1&taxonomyId=3000
Microsoft Office: 450 Million Desktopsp
Financial Models
Scientific Models
Lawrence Livermore National Laboratory LLNL-PRES-648155
12
Software Test Tools
2/18/2014
7
44% of “finished”
spreadsheets still had errors
60
70
80
90
[Brown and Gould 1987]
other such studies reported
errors in 38% to 77% of
spreadsheets at a similar
stage [Panko and Halverson
1996]
0
10
20
30
40
50
60
koand
on1996
ndGould
87
koand
on1996
Lawrence Livermore National Laboratory LLNL-PRES-648155
13
Pank
Halvers
Brownan
198
Pank
Halvers
Lawrence Livermore National Laboratory LLNL-PRES-648155
14
Raymond R. Panko, University of Hawai’i
2/18/2014
8
Application Domain Number
Projects
Error Range
(Errors/KESLOC)
Normative Error Rate
(Errors/KESLOC)
Notes
A tomation 55 2 to 8 5 Factor a tomationAutomation 55 2 to 8 5 Factory automation
Banking 30 3 to 10 6 Loan processing, ATM
Command & Control 45 0.5 to 5 1 Command centers
Data Processing 35 2 to 14 8 DB-intensive systems
Environment/Tools 75 5 to 12 8 CASE, compilers, etc.
Military -All 125 0.2 to 3 < 1.0 See subcategories
§ Airborne 40 0.2 to 1.3 0.5 Embedded sensors
§ Ground 52 0.5 to 4 0.8 Combat center
§ Missile 15 0.3 to 1.5 0.5 GNC system
§ Space 18 0.2 to 0.8 0.4 Attitude control system
Scientific 35 0.9 to 5 2 Seismic processing
5
6
1
8
8
< 1.0
0.5
0.8
0.5
0.4
2
Lawrence Livermore National Laboratory LLNL-PRES-648155
15
Telecommunications 50 3 to 12 6 Digital switches
Test 35 3 to 15 7 Test equipment, devices
Trainers/Simulations 25 2 to 11 6 Virtual reality simulator
Web Business 65 4 to 18 11 Client/server sites
Other 25 2 to 15 7 All others
Donald Reifer, “Industry Software Cost, Quality, and Productivity Benchmarks”, DoD Software
Tech News, July 2004
6
7
6
11
7
4.613333
Spreadsheets – average audited
5 2% error rate5.2% error rate
Software – 4.6 per KSLOC or
.46% error rate
So spreadsheets 10 times more
likely to have errors than software.
Lawrence Livermore National Laboratory LLNL-PRES-648155
16
Spreadsheet Software
2/18/2014
9
The unwarranted confidence creators of
spreadsheets seem to have in the reliability ofspreadsheets seem to have in the reliability of
those spreadsheets [Wilcox et al. 1997]
Testing by creators and independent testers is
not common.
Confidence
Lack of
Test
Lawrence Livermore National Laboratory LLNL-PRES-648155
17
Test
Lawrence Livermore National Laboratory LLNL-PRES-648155
18
Panko, Raymond R. (2005, July 7/8), “Sarbanes–Oxley: What about All the Spreadsheets?
Controlling for Errors and Fraud in Financial Reporting,” EuSpRIG 2005,
University of Greenwich, London, UK. European Spreadsheet Research Information Group. http://www.eusprig.org.
2/18/2014
10
Lawrence Livermore National Laboratory LLNL-PRES-648155
19
Panko, Raymond R. (2005, July 7/8), “Sarbanes–Oxley: What about All the Spreadsheets?
Controlling for Errors and Fraud in Financial Reporting,” EuSpRIG 2005,
University of Greenwich, London, UK. European Spreadsheet Research Information Group. http://www.eusprig.org.
US Federal law enacted in July 30, 2002
Named after Paul Sarbanes (D Md) andNamed after Paul Sarbanes (D-Md) and
Michael G. Oxley (R-Oh)
Largely adopted in Canada but less
prescriptive
Top management must now individually
Lawrence Livermore National Laboratory LLNL-PRES-648155
20
Top management must now individually
certify the accuracy of financial
information.
2/18/2014
11
Unit Test (White Box)
Integration (Grey Box)
Functional (Black Box)Functional (Black Box)
Performance
Stress
Endurance
Operational
Negative
Load
Regression
Algorithmic
Imperative
Programming
Lawrence Livermore National Laboratory LLNL-PRES-648155
21
g
Installation
Compatibility
Security
Usability
Exploratory
Ad Hoc
Smoke
Commit
Nightly
Continuous Integration
Pre-release
Imperative
Programming
Lawrence Livermore National Laboratory LLNL-PRES-648155
22
Independent
Alpha
Beta
2/18/2014
12
Spreadsheets
R (St ti ti l M d l )R (Statistical Modeler)
Aspen
LabView
MATLAB
Mathmatica
Compiled
Software
Application
User
Supplied
Code Used
by
Application
Lawrence Livermore National Laboratory LLNL-PRES-648155
23
at at ca
Python Steering
Defect Rate = .46% Defect Rate = 5.4%
Defect Rate = 5.86%
Evaluation Order
Most data references statically resolved
No loops (ignoring macros)
Incremental visual feedback
Automatic recalculation
Lawrence Livermore National Laboratory LLNL-PRES-648155
24
Automatic recalculation
User base not skilled in programming and
testing
2/18/2014
13
Oracle for calculations
Ch k th ( lid ti )• Check another source (validation)
• Can be calculated in parallel
Test has bugs
Test Coverage
Lawrence Livermore National Laboratory LLNL-PRES-648155
25
Spreadsheet requirements scarce
Adds Time
B24=MAX(B5:B12)
B25 =IF(B24<=B23, “Yes”, “No”)
Lawrence Livermore National Laboratory LLNL-PRES-648155
26
Ferret Out Spreadsheet Errors, Mark Simon 2004, Journal of Accountancy
2/18/2014
14
Lawrence Livermore National Laboratory LLNL-PRES-648155
27
Ferret Out Spreadsheet Errors, Mark Simon 2004, Journal of Accountancy
Too many
zeroszeros
Sign flip
Lawrence Livermore National Laboratory LLNL-PRES-648155
28
Ferret Out Spreadsheet Errors, Mark Simon 2004, Journal of Accountancy
2/18/2014
15
Manipulate inputs
Predict how other cells should change
Check that they change as expected
Example
• Pay Rate goes up
Lawrence Livermore National Laboratory LLNL-PRES-648155
29
• Total pay goes up
Tools/Options/
View/check Regular pay Overtime pay Payroll totals
View/check
formulas or
CTRL~
Not filled down
Constant
=B5*C5 =B5*1.5*D5 =E5+F5
=B6*40 =B6*1.5*D6 =E6+F6
=B7*40 38.8 =E7+F7
=B8*40 =B8*1.5*D8 =E8+F8
=B9*40 =B9*1.5*D9 =E9+F9
=B10*40 =B10*1.5*D10 =E10+F10
=B11*40 =B11*1.5*D11 =E11+F11
=B12*40 =B12*1.5*D12 =E12+F12
=SUM(E5:E12) =SUM(F5:F12) =SUM(G5:G12)
Lawrence Livermore National Laboratory LLNL-PRES-648155
30
Constant
Ferret Out Spreadsheet Errors, Mark Simon 2004, Journal of Accountancy
2/18/2014
16
Select cells
Data/Data
Validation
Put $5 in
cell B5
Lawrence Livermore National Laboratory LLNL-PRES-648155
31
Trace Precedents
Trace
Dependents
Lawrence Livermore National Laboratory LLNL-PRES-648155
32
Ferret Out Spreadsheet Errors,
Mark Simon 2004, Journal of
Accountancy
2/18/2014
17
Multiple
selection of
precedents
Inconsistent dot
patterns show
Lawrence Livermore National Laboratory LLNL-PRES-648155
33
patterns show
errors
Ferret Out Spreadsheet Errors, Mark Simon 2004, Journal of Accountancy
Formula references a blank cell in sparse area
Lawrence Livermore National Laboratory LLNL-PRES-648155
34
2/18/2014
18
Lawrence Livermore National Laboratory LLNL-PRES-648155
35
1 2
Lawrence Livermore National Laboratory LLNL-PRES-648155
36
3 4
2/18/2014
19
Start every function with the equal sign (=)
M t h ll d l thMatch all open and close parentheses
Use a colon to indicate a range
Enter all required arguments
Enter the correct type of arguments
Nest no more than 64 functions
Enclose other sheet names in single quotation marks
Place an exclamation point (!) after a worksheet name when you refer to it in
Lawrence Livermore National Laboratory LLNL-PRES-648155
37
Place an exclamation point (!) after a worksheet name when you refer to it in
a formula
Include the path to external workbooks
Enter numbers without formatting
Avoid dividing by zero
Cells containing formulas that result in an error
Inconsistent calculated column formula in tables
Cells containing years represented as 2 digits
Numbers formatted as text or preceded by an apostrophe
Formulas inconsistent with other formulas in the region
Formulas which omit cells in a region
Lawrence Livermore National Laboratory LLNL-PRES-648155
38
Formulas which omit cells in a region
Unlocked cells containing formulas (Review/Unprotect)
Formulas referring to empty cells
Data entered in a table is invalid
2/18/2014
20
________________________________________________
(Signature)
I have examined this spreadsheet and
vouch for its accuracy and completeness.
Lawrence Livermore National Laboratory LLNL-PRES-648155
39
Read and write cells
Manipulate objects
Boundary tests
Random tests
Tests stay with spreadsheet
Lawrence Livermore National Laboratory LLNL-PRES-648155
40
Tests stay with spreadsheet
Example
Example sheet available at
2/18/2014
21
Tests should cover each function
Boundary testsBoundary tests
— Minimum +- 1
— Maximum +-1
— Half Scale
— Valid Range
Stress
— Very large or small numbers
Lawrence Livermore National Laboratory LLNL-PRES-648155
41
y g
— Invalid values (negative, mixed type, etc.)
Negative (if possible)
Random
Error seed spreadsheet
— Add +1 or -1 to answerAdd +1 or 1 to answer
— Flip sign
— Change cell reference
Run Tests
Error should be detected
Lawrence Livermore National Laboratory LLNL-PRES-648155
42
Tests should fail
Seeding/Clearing automated to prevent errors
Indicator that error is in spreadsheet
2/18/2014
22
Independent of Spreadsheet
Windows native application
Combined with Ghost Mouse
SWAPY reads window objects
Include pywinauto to python
Lawrence Livermore National Laboratory LLNL-PRES-648155
43
Include pywinauto to python
Example
There is much known about how to prevent and
detect spreadsheet errorsdetect spreadsheet errors.
There is much known about how to test software
The two knowledge bases have yet to merge
We do not do a good job of testing spreadsheets
Lawrence Livermore National Laboratory LLNL-PRES-648155
44
Let us merge these areas starting today, eh?
Further Reading: Spreadsheet Check and Control 47 key practices to detect and prevent errors,
Patrick O’Beirne

Mais conteúdo relacionado

Destaque

Destaque (7)

Security Testing for Testing Professionals
Security Testing for Testing ProfessionalsSecurity Testing for Testing Professionals
Security Testing for Testing Professionals
 
Testing the Data Warehouse―Big Data, Big Problems
Testing the Data Warehouse―Big Data, Big ProblemsTesting the Data Warehouse―Big Data, Big Problems
Testing the Data Warehouse―Big Data, Big Problems
 
Essential Test Management and Planning
Essential Test Management and PlanningEssential Test Management and Planning
Essential Test Management and Planning
 
Rapid Software Testing: Strategy
Rapid Software Testing: StrategyRapid Software Testing: Strategy
Rapid Software Testing: Strategy
 
Managing Application Performance: A Simplified Universal Approach
Managing Application Performance: A Simplified Universal ApproachManaging Application Performance: A Simplified Universal Approach
Managing Application Performance: A Simplified Universal Approach
 
Ambiguity Reviews: Building Quality Requirements
Ambiguity Reviews: Building Quality RequirementsAmbiguity Reviews: Building Quality Requirements
Ambiguity Reviews: Building Quality Requirements
 
Meet Big Agile: Testing on Large-Scale Projects
Meet Big Agile: Testing on Large-Scale ProjectsMeet Big Agile: Testing on Large-Scale Projects
Meet Big Agile: Testing on Large-Scale Projects
 

Semelhante a Billion Dollar Bugs: When and How to Test a Spreadsheet

Analytical Instrument Qualification and System Validation
Analytical Instrument Qualification and System ValidationAnalytical Instrument Qualification and System Validation
Analytical Instrument Qualification and System Validation
ComplianceOnline
 
Project_CharterProject TitleGO HOME!!Black BeltProject ChampionEx.docx
Project_CharterProject TitleGO HOME!!Black BeltProject ChampionEx.docxProject_CharterProject TitleGO HOME!!Black BeltProject ChampionEx.docx
Project_CharterProject TitleGO HOME!!Black BeltProject ChampionEx.docx
woodruffeloisa
 
Rafael Rivera Morales_Resume
Rafael Rivera Morales_ResumeRafael Rivera Morales_Resume
Rafael Rivera Morales_Resume
Rafael Rivera
 
Senior Chemist 4.0
Senior Chemist 4.0Senior Chemist 4.0
Senior Chemist 4.0
Evan Coss
 
JosephAult web CV 19MAY2015
JosephAult web CV 19MAY2015JosephAult web CV 19MAY2015
JosephAult web CV 19MAY2015
Joseph Ault
 
Kelsey L. Dolk Resume Revised
Kelsey L. Dolk Resume RevisedKelsey L. Dolk Resume Revised
Kelsey L. Dolk Resume Revised
Kelsey Dolk
 
Dr I.R. Pope c.v. 2016
Dr I.R. Pope c.v. 2016Dr I.R. Pope c.v. 2016
Dr I.R. Pope c.v. 2016
Ian Pope
 

Semelhante a Billion Dollar Bugs: When and How to Test a Spreadsheet (20)

Analytical Instrument Qualification and System Validation
Analytical Instrument Qualification and System ValidationAnalytical Instrument Qualification and System Validation
Analytical Instrument Qualification and System Validation
 
How-Logilab-ELN-helps-organizations-to-follow-GxP-Regulations
How-Logilab-ELN-helps-organizations-to-follow-GxP-RegulationsHow-Logilab-ELN-helps-organizations-to-follow-GxP-Regulations
How-Logilab-ELN-helps-organizations-to-follow-GxP-Regulations
 
N P D E S Report
N P D E S ReportN P D E S Report
N P D E S Report
 
The use of R statistical package in controlled infrastructure. The case of Cl...
The use of R statistical package in controlled infrastructure. The case of Cl...The use of R statistical package in controlled infrastructure. The case of Cl...
The use of R statistical package in controlled infrastructure. The case of Cl...
 
Case Study: University of California Shares Tips and Tricks for Leveraging CA...
Case Study: University of California Shares Tips and Tricks for Leveraging CA...Case Study: University of California Shares Tips and Tricks for Leveraging CA...
Case Study: University of California Shares Tips and Tricks for Leveraging CA...
 
How to Actually DO High-volume Automated Testing
How to Actually DO High-volume Automated TestingHow to Actually DO High-volume Automated Testing
How to Actually DO High-volume Automated Testing
 
A Machine Learning approach to predict Software Defects
A Machine Learning approach to predict Software DefectsA Machine Learning approach to predict Software Defects
A Machine Learning approach to predict Software Defects
 
USUGM 2014 - Jinling Sui (Flately Discovery): Building the Bioinformatic Pla...
USUGM 2014 -  Jinling Sui (Flately Discovery): Building the Bioinformatic Pla...USUGM 2014 -  Jinling Sui (Flately Discovery): Building the Bioinformatic Pla...
USUGM 2014 - Jinling Sui (Flately Discovery): Building the Bioinformatic Pla...
 
Stop the fraudster! Pennsylvania Treasury, Industry Expert Chris Doxey and Fu...
Stop the fraudster! Pennsylvania Treasury, Industry Expert Chris Doxey and Fu...Stop the fraudster! Pennsylvania Treasury, Industry Expert Chris Doxey and Fu...
Stop the fraudster! Pennsylvania Treasury, Industry Expert Chris Doxey and Fu...
 
Program - American Chemical Manufacturing Summit 2013, Pittsburgh
Program - American Chemical Manufacturing Summit 2013, PittsburghProgram - American Chemical Manufacturing Summit 2013, Pittsburgh
Program - American Chemical Manufacturing Summit 2013, Pittsburgh
 
Data Integrity
Data IntegrityData Integrity
Data Integrity
 
Project_CharterProject TitleGO HOME!!Black BeltProject ChampionEx.docx
Project_CharterProject TitleGO HOME!!Black BeltProject ChampionEx.docxProject_CharterProject TitleGO HOME!!Black BeltProject ChampionEx.docx
Project_CharterProject TitleGO HOME!!Black BeltProject ChampionEx.docx
 
Rafael Rivera Morales_Resume
Rafael Rivera Morales_ResumeRafael Rivera Morales_Resume
Rafael Rivera Morales_Resume
 
Senior Chemist 4.0
Senior Chemist 4.0Senior Chemist 4.0
Senior Chemist 4.0
 
Pete Young Resume
Pete Young ResumePete Young Resume
Pete Young Resume
 
Handling of Out of Specification Results
Handling of Out of Specification ResultsHandling of Out of Specification Results
Handling of Out of Specification Results
 
The Top 5 CTMS Enhancements You Can Make
The Top 5 CTMS Enhancements You Can MakeThe Top 5 CTMS Enhancements You Can Make
The Top 5 CTMS Enhancements You Can Make
 
JosephAult web CV 19MAY2015
JosephAult web CV 19MAY2015JosephAult web CV 19MAY2015
JosephAult web CV 19MAY2015
 
Kelsey L. Dolk Resume Revised
Kelsey L. Dolk Resume RevisedKelsey L. Dolk Resume Revised
Kelsey L. Dolk Resume Revised
 
Dr I.R. Pope c.v. 2016
Dr I.R. Pope c.v. 2016Dr I.R. Pope c.v. 2016
Dr I.R. Pope c.v. 2016
 

Mais de TechWell

Mais de TechWell (20)

Failing and Recovering
Failing and RecoveringFailing and Recovering
Failing and Recovering
 
Instill a DevOps Testing Culture in Your Team and Organization
Instill a DevOps Testing Culture in Your Team and Organization Instill a DevOps Testing Culture in Your Team and Organization
Instill a DevOps Testing Culture in Your Team and Organization
 
Test Design for Fully Automated Build Architecture
Test Design for Fully Automated Build ArchitectureTest Design for Fully Automated Build Architecture
Test Design for Fully Automated Build Architecture
 
System-Level Test Automation: Ensuring a Good Start
System-Level Test Automation: Ensuring a Good StartSystem-Level Test Automation: Ensuring a Good Start
System-Level Test Automation: Ensuring a Good Start
 
Build Your Mobile App Quality and Test Strategy
Build Your Mobile App Quality and Test StrategyBuild Your Mobile App Quality and Test Strategy
Build Your Mobile App Quality and Test Strategy
 
Testing Transformation: The Art and Science for Success
Testing Transformation: The Art and Science for SuccessTesting Transformation: The Art and Science for Success
Testing Transformation: The Art and Science for Success
 
Implement BDD with Cucumber and SpecFlow
Implement BDD with Cucumber and SpecFlowImplement BDD with Cucumber and SpecFlow
Implement BDD with Cucumber and SpecFlow
 
Develop WebDriver Automated Tests—and Keep Your Sanity
Develop WebDriver Automated Tests—and Keep Your SanityDevelop WebDriver Automated Tests—and Keep Your Sanity
Develop WebDriver Automated Tests—and Keep Your Sanity
 
Ma 15
Ma 15Ma 15
Ma 15
 
Eliminate Cloud Waste with a Holistic DevOps Strategy
Eliminate Cloud Waste with a Holistic DevOps StrategyEliminate Cloud Waste with a Holistic DevOps Strategy
Eliminate Cloud Waste with a Holistic DevOps Strategy
 
Transform Test Organizations for the New World of DevOps
Transform Test Organizations for the New World of DevOpsTransform Test Organizations for the New World of DevOps
Transform Test Organizations for the New World of DevOps
 
The Fourth Constraint in Project Delivery—Leadership
The Fourth Constraint in Project Delivery—LeadershipThe Fourth Constraint in Project Delivery—Leadership
The Fourth Constraint in Project Delivery—Leadership
 
Resolve the Contradiction of Specialists within Agile Teams
Resolve the Contradiction of Specialists within Agile TeamsResolve the Contradiction of Specialists within Agile Teams
Resolve the Contradiction of Specialists within Agile Teams
 
Pin the Tail on the Metric: A Field-Tested Agile Game
Pin the Tail on the Metric: A Field-Tested Agile GamePin the Tail on the Metric: A Field-Tested Agile Game
Pin the Tail on the Metric: A Field-Tested Agile Game
 
Agile Performance Holarchy (APH)—A Model for Scaling Agile Teams
Agile Performance Holarchy (APH)—A Model for Scaling Agile TeamsAgile Performance Holarchy (APH)—A Model for Scaling Agile Teams
Agile Performance Holarchy (APH)—A Model for Scaling Agile Teams
 
A Business-First Approach to DevOps Implementation
A Business-First Approach to DevOps ImplementationA Business-First Approach to DevOps Implementation
A Business-First Approach to DevOps Implementation
 
Databases in a Continuous Integration/Delivery Process
Databases in a Continuous Integration/Delivery ProcessDatabases in a Continuous Integration/Delivery Process
Databases in a Continuous Integration/Delivery Process
 
Mobile Testing: What—and What Not—to Automate
Mobile Testing: What—and What Not—to AutomateMobile Testing: What—and What Not—to Automate
Mobile Testing: What—and What Not—to Automate
 
Cultural Intelligence: A Key Skill for Success
Cultural Intelligence: A Key Skill for SuccessCultural Intelligence: A Key Skill for Success
Cultural Intelligence: A Key Skill for Success
 
Turn the Lights On: A Power Utility Company's Agile Transformation
Turn the Lights On: A Power Utility Company's Agile TransformationTurn the Lights On: A Power Utility Company's Agile Transformation
Turn the Lights On: A Power Utility Company's Agile Transformation
 

Último

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 

Último (20)

Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 

Billion Dollar Bugs: When and How to Test a Spreadsheet

  • 1.       rent Session    Presented by:  Gregor  Pope  Lawrence  onal Labs      Brought to you by:      340 Corporate Way, Suite   Orange Park, FL 32073  888‐2 T4  Concur 4/8/2014    10:30 AM          “Billion Dollar Bugs: When and How to   Test a Spreadsheet”      y Livermore Nati             300, 68‐8770 ∙ 904‐278‐0524 ∙ sqeinfo@sqe.com ∙ www.sqe.com 
  • 2. Gregory Pope Lawrence Livermore National Labs   With more than forty years of experience developing software in the commercial and government sectors, Greg Pope has held positions from programmer to CEO. Greg currently works for the Lawrence Livermore National Laboratory as a software quality engineering group leader and V&V project leader for advanced simulation and computing and other energy related projects. Previously, he founded and ran a software testing company and patented automated software testing tools. An ASQ certified Software Quality Engineer, Greg has held management and technical positions involved with mission critical testing of military systems and development of software codes for electronic countermeasures, telemetry, and data acquisition systems for flight and experimental testing of aircraft and jet engines.  
  • 3. 2/18/2014 1 STARCanada Gregory Pope, CSQE April 8 2014April 8, 2014 Toronto, Ontario, Canada LLNL-PRES-648155 This work was performed under the auspices of the U.S. Department of Energy by Lawrence Livermore National Laboratory under contract DE-AC52-07NA27344. Lawrence Livermore National Security, LLC Fidelity Minus Sign Mistake 1/1995 ……………………………………………$2.6 Billion TransAlta “Clerical Error” 6/2003 $24 MillionTransAlta Clerical Error 6/2003 ……………………………………………….$24 Million Fannie Mae “Honest” Mistake 10/2003 ……………………………………….$1.3 Billion University of Toledo Projected Revenue 5/2004 ……………………………..$2.4 Million Red Envelope 3/2005 …………………………………………………Shares plunge 28% Think and Do 3/2005 ……number of bachelor degrees 11% instead of 20% in Virginia K d k R t t 11/2005 $11 Milli Lawrence Livermore National Laboratory LLNL-PRES-648155 2 Kodak Restates 11/2005 severance pay error ……………………................$11 Million Westpac Profit 11/2005….............................Trading halted for early release of profits Eight of the Worst Spreadsheet Blunders, Thomas Wailgum, August 17, 2007 http://www.cio.com/article/131500/Eight_of_the_Worst_Spreadsheet_Blunders?page=1&taxonomyId=3000
  • 4. 2/18/2014 2 Copy from master spreadsheet to one for accountantaccountant Accountant omitted a minus sign from a $1.3B capital loss, so it was counted as a capital gain. The net error was the dividend estimate was $2.6B too high Lawrence Livermore National Laboratory LLNL-PRES-648155 3 $2.6B too high Lesson Learned – Differentiate gain and losses, have independent check Canadian company bought more power than needed from US company at a higher priceneeded from US company at a higher price. Cut and paste error not caught on spreadsheet during sort and ranking of bids. Lesson learned: Have another employee double check documentation Lawrence Livermore National Laboratory LLNL-PRES-648155 4 check documentation
  • 5. 2/18/2014 3 Mistakes made in implementation of new accounting standardaccounting standard. Lesson learned: Have a financial peer review the documentation. Lawrence Livermore National Laboratory LLNL-PRES-648155 5 Typo in formula overstated the funds available for usefor use. Lesson learned: Extra scrutiny and review. User training. Lawrence Livermore National Laboratory LLNL-PRES-648155 6
  • 6. 2/18/2014 4 Overestimation of gross margins led to forth quarter over projection of profitsquarter over projection of profits. Number misrecorded in cell. Lesson learned: More quality control Lawrence Livermore National Laboratory LLNL-PRES-648155 7 Researchers at Virginia Tech cut and paste error causing the number of population over 25 withcausing the number of population over 25 with bachelors degrees in a region to be lower than actual. Lesson learned: Have another employee check the work Lawrence Livermore National Laboratory LLNL-PRES-648155 8
  • 7. 2/18/2014 5 Over stated severance pay due. Error was on one employee’s severance pay there were tooone employee s severance pay, there were too many zeros. Lesson learned: Lack of data quality control Lawrence Livermore National Laboratory LLNL-PRES-648155 9 Released the results of next quarter profits early by putting them into an existing spreadsheet andby putting them into an existing spreadsheet and then hiding them by making the cell fill black. Lesson learned: Additional training. Lawrence Livermore National Laboratory LLNL-PRES-648155 10
  • 8. 2/18/2014 6 More Independent checks70% More Independent checks More Training Differentiate Gain and Loss 70% 20% 10% Lawrence Livermore National Laboratory LLNL-PRES-648155 11 Differentiate Gain and Loss10% Based on: Eight of the Worst Spreadsheet Blunders, Thomas Wailgum, August 17, 2007 http://www.cio.com/article/131500/Eight_of_the_Worst_Spreadsheet_Blunders?page=1&taxonomyId=3000 Microsoft Office: 450 Million Desktopsp Financial Models Scientific Models Lawrence Livermore National Laboratory LLNL-PRES-648155 12 Software Test Tools
  • 9. 2/18/2014 7 44% of “finished” spreadsheets still had errors 60 70 80 90 [Brown and Gould 1987] other such studies reported errors in 38% to 77% of spreadsheets at a similar stage [Panko and Halverson 1996] 0 10 20 30 40 50 60 koand on1996 ndGould 87 koand on1996 Lawrence Livermore National Laboratory LLNL-PRES-648155 13 Pank Halvers Brownan 198 Pank Halvers Lawrence Livermore National Laboratory LLNL-PRES-648155 14 Raymond R. Panko, University of Hawai’i
  • 10. 2/18/2014 8 Application Domain Number Projects Error Range (Errors/KESLOC) Normative Error Rate (Errors/KESLOC) Notes A tomation 55 2 to 8 5 Factor a tomationAutomation 55 2 to 8 5 Factory automation Banking 30 3 to 10 6 Loan processing, ATM Command & Control 45 0.5 to 5 1 Command centers Data Processing 35 2 to 14 8 DB-intensive systems Environment/Tools 75 5 to 12 8 CASE, compilers, etc. Military -All 125 0.2 to 3 < 1.0 See subcategories § Airborne 40 0.2 to 1.3 0.5 Embedded sensors § Ground 52 0.5 to 4 0.8 Combat center § Missile 15 0.3 to 1.5 0.5 GNC system § Space 18 0.2 to 0.8 0.4 Attitude control system Scientific 35 0.9 to 5 2 Seismic processing 5 6 1 8 8 < 1.0 0.5 0.8 0.5 0.4 2 Lawrence Livermore National Laboratory LLNL-PRES-648155 15 Telecommunications 50 3 to 12 6 Digital switches Test 35 3 to 15 7 Test equipment, devices Trainers/Simulations 25 2 to 11 6 Virtual reality simulator Web Business 65 4 to 18 11 Client/server sites Other 25 2 to 15 7 All others Donald Reifer, “Industry Software Cost, Quality, and Productivity Benchmarks”, DoD Software Tech News, July 2004 6 7 6 11 7 4.613333 Spreadsheets – average audited 5 2% error rate5.2% error rate Software – 4.6 per KSLOC or .46% error rate So spreadsheets 10 times more likely to have errors than software. Lawrence Livermore National Laboratory LLNL-PRES-648155 16 Spreadsheet Software
  • 11. 2/18/2014 9 The unwarranted confidence creators of spreadsheets seem to have in the reliability ofspreadsheets seem to have in the reliability of those spreadsheets [Wilcox et al. 1997] Testing by creators and independent testers is not common. Confidence Lack of Test Lawrence Livermore National Laboratory LLNL-PRES-648155 17 Test Lawrence Livermore National Laboratory LLNL-PRES-648155 18 Panko, Raymond R. (2005, July 7/8), “Sarbanes–Oxley: What about All the Spreadsheets? Controlling for Errors and Fraud in Financial Reporting,” EuSpRIG 2005, University of Greenwich, London, UK. European Spreadsheet Research Information Group. http://www.eusprig.org.
  • 12. 2/18/2014 10 Lawrence Livermore National Laboratory LLNL-PRES-648155 19 Panko, Raymond R. (2005, July 7/8), “Sarbanes–Oxley: What about All the Spreadsheets? Controlling for Errors and Fraud in Financial Reporting,” EuSpRIG 2005, University of Greenwich, London, UK. European Spreadsheet Research Information Group. http://www.eusprig.org. US Federal law enacted in July 30, 2002 Named after Paul Sarbanes (D Md) andNamed after Paul Sarbanes (D-Md) and Michael G. Oxley (R-Oh) Largely adopted in Canada but less prescriptive Top management must now individually Lawrence Livermore National Laboratory LLNL-PRES-648155 20 Top management must now individually certify the accuracy of financial information.
  • 13. 2/18/2014 11 Unit Test (White Box) Integration (Grey Box) Functional (Black Box)Functional (Black Box) Performance Stress Endurance Operational Negative Load Regression Algorithmic Imperative Programming Lawrence Livermore National Laboratory LLNL-PRES-648155 21 g Installation Compatibility Security Usability Exploratory Ad Hoc Smoke Commit Nightly Continuous Integration Pre-release Imperative Programming Lawrence Livermore National Laboratory LLNL-PRES-648155 22 Independent Alpha Beta
  • 14. 2/18/2014 12 Spreadsheets R (St ti ti l M d l )R (Statistical Modeler) Aspen LabView MATLAB Mathmatica Compiled Software Application User Supplied Code Used by Application Lawrence Livermore National Laboratory LLNL-PRES-648155 23 at at ca Python Steering Defect Rate = .46% Defect Rate = 5.4% Defect Rate = 5.86% Evaluation Order Most data references statically resolved No loops (ignoring macros) Incremental visual feedback Automatic recalculation Lawrence Livermore National Laboratory LLNL-PRES-648155 24 Automatic recalculation User base not skilled in programming and testing
  • 15. 2/18/2014 13 Oracle for calculations Ch k th ( lid ti )• Check another source (validation) • Can be calculated in parallel Test has bugs Test Coverage Lawrence Livermore National Laboratory LLNL-PRES-648155 25 Spreadsheet requirements scarce Adds Time B24=MAX(B5:B12) B25 =IF(B24<=B23, “Yes”, “No”) Lawrence Livermore National Laboratory LLNL-PRES-648155 26 Ferret Out Spreadsheet Errors, Mark Simon 2004, Journal of Accountancy
  • 16. 2/18/2014 14 Lawrence Livermore National Laboratory LLNL-PRES-648155 27 Ferret Out Spreadsheet Errors, Mark Simon 2004, Journal of Accountancy Too many zeroszeros Sign flip Lawrence Livermore National Laboratory LLNL-PRES-648155 28 Ferret Out Spreadsheet Errors, Mark Simon 2004, Journal of Accountancy
  • 17. 2/18/2014 15 Manipulate inputs Predict how other cells should change Check that they change as expected Example • Pay Rate goes up Lawrence Livermore National Laboratory LLNL-PRES-648155 29 • Total pay goes up Tools/Options/ View/check Regular pay Overtime pay Payroll totals View/check formulas or CTRL~ Not filled down Constant =B5*C5 =B5*1.5*D5 =E5+F5 =B6*40 =B6*1.5*D6 =E6+F6 =B7*40 38.8 =E7+F7 =B8*40 =B8*1.5*D8 =E8+F8 =B9*40 =B9*1.5*D9 =E9+F9 =B10*40 =B10*1.5*D10 =E10+F10 =B11*40 =B11*1.5*D11 =E11+F11 =B12*40 =B12*1.5*D12 =E12+F12 =SUM(E5:E12) =SUM(F5:F12) =SUM(G5:G12) Lawrence Livermore National Laboratory LLNL-PRES-648155 30 Constant Ferret Out Spreadsheet Errors, Mark Simon 2004, Journal of Accountancy
  • 18. 2/18/2014 16 Select cells Data/Data Validation Put $5 in cell B5 Lawrence Livermore National Laboratory LLNL-PRES-648155 31 Trace Precedents Trace Dependents Lawrence Livermore National Laboratory LLNL-PRES-648155 32 Ferret Out Spreadsheet Errors, Mark Simon 2004, Journal of Accountancy
  • 19. 2/18/2014 17 Multiple selection of precedents Inconsistent dot patterns show Lawrence Livermore National Laboratory LLNL-PRES-648155 33 patterns show errors Ferret Out Spreadsheet Errors, Mark Simon 2004, Journal of Accountancy Formula references a blank cell in sparse area Lawrence Livermore National Laboratory LLNL-PRES-648155 34
  • 20. 2/18/2014 18 Lawrence Livermore National Laboratory LLNL-PRES-648155 35 1 2 Lawrence Livermore National Laboratory LLNL-PRES-648155 36 3 4
  • 21. 2/18/2014 19 Start every function with the equal sign (=) M t h ll d l thMatch all open and close parentheses Use a colon to indicate a range Enter all required arguments Enter the correct type of arguments Nest no more than 64 functions Enclose other sheet names in single quotation marks Place an exclamation point (!) after a worksheet name when you refer to it in Lawrence Livermore National Laboratory LLNL-PRES-648155 37 Place an exclamation point (!) after a worksheet name when you refer to it in a formula Include the path to external workbooks Enter numbers without formatting Avoid dividing by zero Cells containing formulas that result in an error Inconsistent calculated column formula in tables Cells containing years represented as 2 digits Numbers formatted as text or preceded by an apostrophe Formulas inconsistent with other formulas in the region Formulas which omit cells in a region Lawrence Livermore National Laboratory LLNL-PRES-648155 38 Formulas which omit cells in a region Unlocked cells containing formulas (Review/Unprotect) Formulas referring to empty cells Data entered in a table is invalid
  • 22. 2/18/2014 20 ________________________________________________ (Signature) I have examined this spreadsheet and vouch for its accuracy and completeness. Lawrence Livermore National Laboratory LLNL-PRES-648155 39 Read and write cells Manipulate objects Boundary tests Random tests Tests stay with spreadsheet Lawrence Livermore National Laboratory LLNL-PRES-648155 40 Tests stay with spreadsheet Example Example sheet available at
  • 23. 2/18/2014 21 Tests should cover each function Boundary testsBoundary tests — Minimum +- 1 — Maximum +-1 — Half Scale — Valid Range Stress — Very large or small numbers Lawrence Livermore National Laboratory LLNL-PRES-648155 41 y g — Invalid values (negative, mixed type, etc.) Negative (if possible) Random Error seed spreadsheet — Add +1 or -1 to answerAdd +1 or 1 to answer — Flip sign — Change cell reference Run Tests Error should be detected Lawrence Livermore National Laboratory LLNL-PRES-648155 42 Tests should fail Seeding/Clearing automated to prevent errors Indicator that error is in spreadsheet
  • 24. 2/18/2014 22 Independent of Spreadsheet Windows native application Combined with Ghost Mouse SWAPY reads window objects Include pywinauto to python Lawrence Livermore National Laboratory LLNL-PRES-648155 43 Include pywinauto to python Example There is much known about how to prevent and detect spreadsheet errorsdetect spreadsheet errors. There is much known about how to test software The two knowledge bases have yet to merge We do not do a good job of testing spreadsheets Lawrence Livermore National Laboratory LLNL-PRES-648155 44 Let us merge these areas starting today, eh? Further Reading: Spreadsheet Check and Control 47 key practices to detect and prevent errors, Patrick O’Beirne