SlideShare a Scribd company logo
CodeLive with Salesforce Developers
August 28, 2019
Positive and Negative Testing
with Kevin Poorman & Melissa Mueller
Melissa Mueller
@AstroLovesCodey
Developer Evangelist, Salesforce.com
Thinks in code. Often NPE’s
CodeLive with Melissa Mueller & Kevin Poorman
Kevin Poorman @codefriar
Stays cool as a Software
Engineer at Mitsubishi Electric
Trane HVAC USA
Introductions
FLS Sing-a-long
Explanation of the problem
Coding our solution
Recap
Talking about what we’re gonna talk about. #meta
Today’s Agenda
This presentation may contain forward-looking statements that involve risks, uncertainties, and assumptions. If any such uncertainties materialize or if any of the
assumptions proves incorrect, the results of salesforce.com, inc. could differ materially from the results expressed or implied by the forward-looking statements we
make. All statements other than statements of historical fact could be deemed forward-looking, including any projections of product or service availability, subscriber
growth, earnings, revenues, or other financial items and any statements regarding strategies or plans of management for future operations, statements of belief,
any statements concerning new, planned, or upgraded services or technology developments and customer contracts or use of our services.
The risks and uncertainties referred to above include – but are not limited to – risks associated with developing and delivering new functionality for our service, new
products and services, our new business model, our past operating losses, possible fluctuations in our operating results and rate of growth, interruptions or delays
in our Web hosting, breach of our security measures, the outcome of any litigation, risks associated with completed and any possible mergers and acquisitions, the
immature market in which we operate, our relatively limited operating history, our ability to expand, retain, and motivate our employees and manage our growth,
new releases of our service and successful customer deployment, our limited history reselling non-salesforce.com products, and utilization and selling to larger
enterprise customers. Further information on potential factors that could affect the financial results of salesforce.com, inc. is included in our annual report on Form
10-K for the most recent fiscal year and in our quarterly report on Form 10-Q for the most recent fiscal quarter. These documents and others containing important
disclosures are available on the SEC Filings section of the Investor Information section of our Website.
Any unreleased services or features referenced in this or other presentations, press releases or public statements are not currently available and may not be
delivered on time or at all. Customers who purchase our services should make the purchase decisions based upon features that are currently available.
Salesforce.com, inc. assumes no obligation and does not intend to update these forward-looking statements.
Statement under the Private Securities Litigation Reform Act of 1995
Forward-Looking Statement
Let’s be Positive about Negative Testing!
Positive and Negative Unit Testing for
fun and profit.
Positive Tests
Are you sure? Positive.
Negative Tests
Are you sure? … Yes.
Goals:
High Test coverage
Confidence that our code works as expected
Confidence that our code fails when, and how we expect
Our solution.
Let’s write some tests
https://github.com/sfcodelive/positiveAndNegativeTesting
We’re working with this project:
This way to the code
In case Kevin forgets, this is where we (finally) get away
from the slides and to the coding bits.
Today we
Identify properly scoped ‘units’ for unit testing
Write useful positive unit tests
Write useful negative unit tests
TESTED ALL THE THINGS
Key Takeaways
Unit testing helps you craft better software
A unit isn’t necessarily an entire method.
Positive unit tests build confidence that your code works as expected with a known set of inputs.
Negative unit tests build confidence that your code fails how, and when it should.
Remember this!
Complete the testing
Trailmix:
https://sforce.co/positive-negative-
testing
trailhead.salesforce.com
Check out the code at:
https://github.com/sfcodelive/positiveAndNegativeTesting
codeLive: Positive and negative testing

More Related Content

What's hot

Intro to Apex Testing - Dreamforce 2016
Intro to Apex Testing - Dreamforce 2016Intro to Apex Testing - Dreamforce 2016
Intro to Apex Testing - Dreamforce 2016
Laura Meerkatz
 
Content Strategy Workshop: TC Camp 2016
Content Strategy Workshop: TC Camp 2016Content Strategy Workshop: TC Camp 2016
Content Strategy Workshop: TC Camp 2016
Gavin Austin
 
Salesforce at Continuous Delivery Foundation Summit
Salesforce at Continuous Delivery Foundation SummitSalesforce at Continuous Delivery Foundation Summit
Salesforce at Continuous Delivery Foundation Summit
Mark Interrante
 
Doc is Dead! How Walkthroughs Changed Salesforce's Content Strategy
Doc is Dead! How Walkthroughs Changed Salesforce's Content StrategyDoc is Dead! How Walkthroughs Changed Salesforce's Content Strategy
Doc is Dead! How Walkthroughs Changed Salesforce's Content Strategy
Gavin Austin
 
Salesforce Known Issues: The Lifecycle of a Bug
Salesforce Known Issues: The Lifecycle of a BugSalesforce Known Issues: The Lifecycle of a Bug
Salesforce Known Issues: The Lifecycle of a Bug
Salesforce Developers
 
Lightning Platform Product Managers: Ask Us Anything!
Lightning Platform Product Managers: Ask Us Anything!Lightning Platform Product Managers: Ask Us Anything!
Lightning Platform Product Managers: Ask Us Anything!
Salesforce Developers
 
Easy No-Code Integrations with External Services and Visual Flow
Easy No-Code Integrations with External Services and Visual FlowEasy No-Code Integrations with External Services and Visual Flow
Easy No-Code Integrations with External Services and Visual Flow
Salesforce Developers
 
S1 Tour Paris Developpeurs
S1 Tour Paris DeveloppeursS1 Tour Paris Developpeurs
S1 Tour Paris Developpeurs
Peter Chittum
 
Integrate CMS Content Into Lightning Communities with CMS Connect
Integrate CMS Content Into Lightning Communities with CMS ConnectIntegrate CMS Content Into Lightning Communities with CMS Connect
Integrate CMS Content Into Lightning Communities with CMS Connect
Salesforce Developers
 
Force.com Friday: Intro to Force.com Slides
Force.com Friday: Intro to Force.com SlidesForce.com Friday: Intro to Force.com Slides
Force.com Friday: Intro to Force.com Slides
Salesforce Developers
 
Build Apple Watch Apps for the Enterprise
Build Apple Watch Apps for the EnterpriseBuild Apple Watch Apps for the Enterprise
Build Apple Watch Apps for the Enterprise
Salesforce Developers
 
#DF17Recap series: Make apps smarter with Einstein
#DF17Recap series: Make apps smarter with Einstein#DF17Recap series: Make apps smarter with Einstein
#DF17Recap series: Make apps smarter with Einstein
Salesforce Developers
 
Einstein Analytics for Developers
Einstein Analytics for DevelopersEinstein Analytics for Developers
Einstein Analytics for Developers
Salesforce Developers
 
Rollin' Out Lightnin' Ain't All That Frightenin' by Jon Barlow
Rollin' Out Lightnin' Ain't All That Frightenin' by Jon BarlowRollin' Out Lightnin' Ain't All That Frightenin' by Jon Barlow
Rollin' Out Lightnin' Ain't All That Frightenin' by Jon Barlow
Salesforce Admins
 
Write Powerful Communication to Get Your Stakeholder's Attention by Andrea Ho...
Write Powerful Communication to Get Your Stakeholder's Attention by Andrea Ho...Write Powerful Communication to Get Your Stakeholder's Attention by Andrea Ho...
Write Powerful Communication to Get Your Stakeholder's Attention by Andrea Ho...
Salesforce Admins
 
Agile2013 - How Writers Can Thrive in Agile Software Development
Agile2013 - How Writers Can Thrive in Agile Software DevelopmentAgile2013 - How Writers Can Thrive in Agile Software Development
Agile2013 - How Writers Can Thrive in Agile Software Development
Gavin Austin
 
#DF17Recap series: Integrate apps easier with the Salesforce platform
#DF17Recap series: Integrate apps easier with the Salesforce platform#DF17Recap series: Integrate apps easier with the Salesforce platform
#DF17Recap series: Integrate apps easier with the Salesforce platform
Salesforce Developers
 
The Salesforce Einstein Product Team: Ask Us Anything!
The Salesforce Einstein Product Team: Ask Us Anything!The Salesforce Einstein Product Team: Ask Us Anything!
The Salesforce Einstein Product Team: Ask Us Anything!
Salesforce Developers
 
Dreamforce 2014 - Salesforce Python SDK for REST/SOAP APIs
Dreamforce 2014 - Salesforce Python SDK for REST/SOAP APIsDreamforce 2014 - Salesforce Python SDK for REST/SOAP APIs
Dreamforce 2014 - Salesforce Python SDK for REST/SOAP APIs
Hormoz Tarevern
 
Summer '18 Developer Highlights
Summer '18 Developer HighlightsSummer '18 Developer Highlights
Summer '18 Developer Highlights
Salesforce Developers
 

What's hot (20)

Intro to Apex Testing - Dreamforce 2016
Intro to Apex Testing - Dreamforce 2016Intro to Apex Testing - Dreamforce 2016
Intro to Apex Testing - Dreamforce 2016
 
Content Strategy Workshop: TC Camp 2016
Content Strategy Workshop: TC Camp 2016Content Strategy Workshop: TC Camp 2016
Content Strategy Workshop: TC Camp 2016
 
Salesforce at Continuous Delivery Foundation Summit
Salesforce at Continuous Delivery Foundation SummitSalesforce at Continuous Delivery Foundation Summit
Salesforce at Continuous Delivery Foundation Summit
 
Doc is Dead! How Walkthroughs Changed Salesforce's Content Strategy
Doc is Dead! How Walkthroughs Changed Salesforce's Content StrategyDoc is Dead! How Walkthroughs Changed Salesforce's Content Strategy
Doc is Dead! How Walkthroughs Changed Salesforce's Content Strategy
 
Salesforce Known Issues: The Lifecycle of a Bug
Salesforce Known Issues: The Lifecycle of a BugSalesforce Known Issues: The Lifecycle of a Bug
Salesforce Known Issues: The Lifecycle of a Bug
 
Lightning Platform Product Managers: Ask Us Anything!
Lightning Platform Product Managers: Ask Us Anything!Lightning Platform Product Managers: Ask Us Anything!
Lightning Platform Product Managers: Ask Us Anything!
 
Easy No-Code Integrations with External Services and Visual Flow
Easy No-Code Integrations with External Services and Visual FlowEasy No-Code Integrations with External Services and Visual Flow
Easy No-Code Integrations with External Services and Visual Flow
 
S1 Tour Paris Developpeurs
S1 Tour Paris DeveloppeursS1 Tour Paris Developpeurs
S1 Tour Paris Developpeurs
 
Integrate CMS Content Into Lightning Communities with CMS Connect
Integrate CMS Content Into Lightning Communities with CMS ConnectIntegrate CMS Content Into Lightning Communities with CMS Connect
Integrate CMS Content Into Lightning Communities with CMS Connect
 
Force.com Friday: Intro to Force.com Slides
Force.com Friday: Intro to Force.com SlidesForce.com Friday: Intro to Force.com Slides
Force.com Friday: Intro to Force.com Slides
 
Build Apple Watch Apps for the Enterprise
Build Apple Watch Apps for the EnterpriseBuild Apple Watch Apps for the Enterprise
Build Apple Watch Apps for the Enterprise
 
#DF17Recap series: Make apps smarter with Einstein
#DF17Recap series: Make apps smarter with Einstein#DF17Recap series: Make apps smarter with Einstein
#DF17Recap series: Make apps smarter with Einstein
 
Einstein Analytics for Developers
Einstein Analytics for DevelopersEinstein Analytics for Developers
Einstein Analytics for Developers
 
Rollin' Out Lightnin' Ain't All That Frightenin' by Jon Barlow
Rollin' Out Lightnin' Ain't All That Frightenin' by Jon BarlowRollin' Out Lightnin' Ain't All That Frightenin' by Jon Barlow
Rollin' Out Lightnin' Ain't All That Frightenin' by Jon Barlow
 
Write Powerful Communication to Get Your Stakeholder's Attention by Andrea Ho...
Write Powerful Communication to Get Your Stakeholder's Attention by Andrea Ho...Write Powerful Communication to Get Your Stakeholder's Attention by Andrea Ho...
Write Powerful Communication to Get Your Stakeholder's Attention by Andrea Ho...
 
Agile2013 - How Writers Can Thrive in Agile Software Development
Agile2013 - How Writers Can Thrive in Agile Software DevelopmentAgile2013 - How Writers Can Thrive in Agile Software Development
Agile2013 - How Writers Can Thrive in Agile Software Development
 
#DF17Recap series: Integrate apps easier with the Salesforce platform
#DF17Recap series: Integrate apps easier with the Salesforce platform#DF17Recap series: Integrate apps easier with the Salesforce platform
#DF17Recap series: Integrate apps easier with the Salesforce platform
 
The Salesforce Einstein Product Team: Ask Us Anything!
The Salesforce Einstein Product Team: Ask Us Anything!The Salesforce Einstein Product Team: Ask Us Anything!
The Salesforce Einstein Product Team: Ask Us Anything!
 
Dreamforce 2014 - Salesforce Python SDK for REST/SOAP APIs
Dreamforce 2014 - Salesforce Python SDK for REST/SOAP APIsDreamforce 2014 - Salesforce Python SDK for REST/SOAP APIs
Dreamforce 2014 - Salesforce Python SDK for REST/SOAP APIs
 
Summer '18 Developer Highlights
Summer '18 Developer HighlightsSummer '18 Developer Highlights
Summer '18 Developer Highlights
 

Similar to codeLive: Positive and negative testing

CodeLive with Adam Daw - Building a mobile friendly geolocation aware candy t...
CodeLive with Adam Daw - Building a mobile friendly geolocation aware candy t...CodeLive with Adam Daw - Building a mobile friendly geolocation aware candy t...
CodeLive with Adam Daw - Building a mobile friendly geolocation aware candy t...
JackGuo20
 
Mini-Workshop: Responsive Web Design with Visualforce and Bootstrap
Mini-Workshop: Responsive Web Design with Visualforce and BootstrapMini-Workshop: Responsive Web Design with Visualforce and Bootstrap
Mini-Workshop: Responsive Web Design with Visualforce and Bootstrap
Keir Bowden
 
iOS Unit Testing Like a Boss
iOS Unit Testing Like a BossiOS Unit Testing Like a Boss
iOS Unit Testing Like a Boss
Salesforce Developers
 
Salesforce Deployment: From Production Hacker to Agile Guru
Salesforce Deployment: From Production Hacker to Agile GuruSalesforce Deployment: From Production Hacker to Agile Guru
Salesforce Deployment: From Production Hacker to Agile Guru
Salesforce Developers
 
Force.com Friday - Intro to Force.com
Force.com Friday -  Intro to Force.comForce.com Friday -  Intro to Force.com
Force.com Friday - Intro to Force.com
Shivanath Devinarayanan
 
Force.com Friday - An Intro to Force.com
Force.com Friday - An Intro to Force.comForce.com Friday - An Intro to Force.com
Force.com Friday - An Intro to Force.com
Dazeworks
 
Improve Home Healthcare Outcomes with Force.com & the Internet of Things
Improve Home Healthcare Outcomes with Force.com & the Internet of ThingsImprove Home Healthcare Outcomes with Force.com & the Internet of Things
Improve Home Healthcare Outcomes with Force.com & the Internet of Things
Salesforce Developers
 
How to Optimize Your AppExchange Listing
How to Optimize Your AppExchange ListingHow to Optimize Your AppExchange Listing
How to Optimize Your AppExchange Listing
Eric Wu
 
Getting Starting with Salesforce for Nonprofits
Getting Starting with Salesforce for NonprofitsGetting Starting with Salesforce for Nonprofits
Getting Starting with Salesforce for Nonprofits
Nik Panter
 
Build Better Communities with Lightning
Build Better Communities with LightningBuild Better Communities with Lightning
Build Better Communities with Lightning
Salesforce Developers
 
Detroit ELEVATE Track 1
Detroit ELEVATE Track 1Detroit ELEVATE Track 1
Detroit ELEVATE Track 1
Joshua Birk
 
Salesforce Innovates Faster with Agile - You Can Too
Salesforce Innovates Faster with Agile - You Can TooSalesforce Innovates Faster with Agile - You Can Too
Salesforce Innovates Faster with Agile - You Can Too
Dreamforce
 
Code live with ryan headley code reviews done right
Code live with ryan headley   code reviews done rightCode live with ryan headley   code reviews done right
Code live with ryan headley code reviews done right
JackGuo20
 
Startups need Admins, too
Startups need Admins, tooStartups need Admins, too
Startups need Admins, too
Salesforce Admins
 
Getting Started with Salesforce for Non-Profits by Nik Panter
Getting Started with Salesforce for Non-Profits by Nik PanterGetting Started with Salesforce for Non-Profits by Nik Panter
Getting Started with Salesforce for Non-Profits by Nik Panter
Salesforce Admins
 
Gesture Controlled Interactions with Platform Events and IoT Explorer
Gesture Controlled Interactions with Platform Events and IoT ExplorerGesture Controlled Interactions with Platform Events and IoT Explorer
Gesture Controlled Interactions with Platform Events and IoT Explorer
Salesforce Developers
 
Socialize Enterprise Apps Using Apex, Visualforce and Chatter
Socialize Enterprise Apps Using Apex, Visualforce and ChatterSocialize Enterprise Apps Using Apex, Visualforce and Chatter
Socialize Enterprise Apps Using Apex, Visualforce and ChatterSalesforce Developers
 
Salesforce Partner Forum: The Internet of Things Opportunity
Salesforce Partner Forum: The Internet of Things OpportunitySalesforce Partner Forum: The Internet of Things Opportunity
Salesforce Partner Forum: The Internet of Things Opportunity
ReidCarlberg
 
Code live with Brian Kwong - Visualforce to Lwc
Code live with Brian Kwong - Visualforce to LwcCode live with Brian Kwong - Visualforce to Lwc
Code live with Brian Kwong - Visualforce to Lwc
JackGuo20
 

Similar to codeLive: Positive and negative testing (20)

CodeLive with Adam Daw - Building a mobile friendly geolocation aware candy t...
CodeLive with Adam Daw - Building a mobile friendly geolocation aware candy t...CodeLive with Adam Daw - Building a mobile friendly geolocation aware candy t...
CodeLive with Adam Daw - Building a mobile friendly geolocation aware candy t...
 
Mini-Workshop: Responsive Web Design with Visualforce and Bootstrap
Mini-Workshop: Responsive Web Design with Visualforce and BootstrapMini-Workshop: Responsive Web Design with Visualforce and Bootstrap
Mini-Workshop: Responsive Web Design with Visualforce and Bootstrap
 
iOS Unit Testing Like a Boss
iOS Unit Testing Like a BossiOS Unit Testing Like a Boss
iOS Unit Testing Like a Boss
 
Salesforce Deployment: From Production Hacker to Agile Guru
Salesforce Deployment: From Production Hacker to Agile GuruSalesforce Deployment: From Production Hacker to Agile Guru
Salesforce Deployment: From Production Hacker to Agile Guru
 
Force.com Friday - Intro to Force.com
Force.com Friday -  Intro to Force.comForce.com Friday -  Intro to Force.com
Force.com Friday - Intro to Force.com
 
Force.com Friday - An Intro to Force.com
Force.com Friday - An Intro to Force.comForce.com Friday - An Intro to Force.com
Force.com Friday - An Intro to Force.com
 
Improve Home Healthcare Outcomes with Force.com & the Internet of Things
Improve Home Healthcare Outcomes with Force.com & the Internet of ThingsImprove Home Healthcare Outcomes with Force.com & the Internet of Things
Improve Home Healthcare Outcomes with Force.com & the Internet of Things
 
How to Optimize Your AppExchange Listing
How to Optimize Your AppExchange ListingHow to Optimize Your AppExchange Listing
How to Optimize Your AppExchange Listing
 
Getting Starting with Salesforce for Nonprofits
Getting Starting with Salesforce for NonprofitsGetting Starting with Salesforce for Nonprofits
Getting Starting with Salesforce for Nonprofits
 
Build Better Communities with Lightning
Build Better Communities with LightningBuild Better Communities with Lightning
Build Better Communities with Lightning
 
Detroit ELEVATE Track 1
Detroit ELEVATE Track 1Detroit ELEVATE Track 1
Detroit ELEVATE Track 1
 
Salesforce Innovates Faster with Agile - You Can Too
Salesforce Innovates Faster with Agile - You Can TooSalesforce Innovates Faster with Agile - You Can Too
Salesforce Innovates Faster with Agile - You Can Too
 
Code live with ryan headley code reviews done right
Code live with ryan headley   code reviews done rightCode live with ryan headley   code reviews done right
Code live with ryan headley code reviews done right
 
Startups need Admins, too
Startups need Admins, tooStartups need Admins, too
Startups need Admins, too
 
Getting Started with Salesforce for Non-Profits by Nik Panter
Getting Started with Salesforce for Non-Profits by Nik PanterGetting Started with Salesforce for Non-Profits by Nik Panter
Getting Started with Salesforce for Non-Profits by Nik Panter
 
Elevate workshop track1
Elevate workshop track1Elevate workshop track1
Elevate workshop track1
 
Gesture Controlled Interactions with Platform Events and IoT Explorer
Gesture Controlled Interactions with Platform Events and IoT ExplorerGesture Controlled Interactions with Platform Events and IoT Explorer
Gesture Controlled Interactions with Platform Events and IoT Explorer
 
Socialize Enterprise Apps Using Apex, Visualforce and Chatter
Socialize Enterprise Apps Using Apex, Visualforce and ChatterSocialize Enterprise Apps Using Apex, Visualforce and Chatter
Socialize Enterprise Apps Using Apex, Visualforce and Chatter
 
Salesforce Partner Forum: The Internet of Things Opportunity
Salesforce Partner Forum: The Internet of Things OpportunitySalesforce Partner Forum: The Internet of Things Opportunity
Salesforce Partner Forum: The Internet of Things Opportunity
 
Code live with Brian Kwong - Visualforce to Lwc
Code live with Brian Kwong - Visualforce to LwcCode live with Brian Kwong - Visualforce to Lwc
Code live with Brian Kwong - Visualforce to Lwc
 

More from Developer Force

Developing Trusted Networks with Salesforce Blockchain
Developing Trusted Networks with Salesforce BlockchainDeveloping Trusted Networks with Salesforce Blockchain
Developing Trusted Networks with Salesforce Blockchain
Developer Force
 
Preview: Local Development for Lightning Web Components
Preview: Local Development for Lightning Web ComponentsPreview: Local Development for Lightning Web Components
Preview: Local Development for Lightning Web Components
Developer Force
 
Integrate with MuleSoft Anypoint
Integrate with MuleSoft AnypointIntegrate with MuleSoft Anypoint
Integrate with MuleSoft Anypoint
Developer Force
 
Get Started with the Lightning Platform
Get Started with the Lightning PlatformGet Started with the Lightning Platform
Get Started with the Lightning Platform
Developer Force
 
Meet Astro & Friends with Domenique Sillett-Buxton
Meet Astro & Friends with Domenique Sillett-BuxtonMeet Astro & Friends with Domenique Sillett-Buxton
Meet Astro & Friends with Domenique Sillett-Buxton
Developer Force
 
Salesforce Lightning Supersession (TDX18)
Salesforce Lightning Supersession (TDX18)Salesforce Lightning Supersession (TDX18)
Salesforce Lightning Supersession (TDX18)
Developer Force
 
Salesforce Lightning Customization Roadmap (TDX18)
Salesforce Lightning Customization Roadmap (TDX18)Salesforce Lightning Customization Roadmap (TDX18)
Salesforce Lightning Customization Roadmap (TDX18)
Developer Force
 
Salesforce Lightning Component Framework Roadmap (TDX18)
Salesforce Lightning Component Framework Roadmap (TDX18)Salesforce Lightning Component Framework Roadmap (TDX18)
Salesforce Lightning Component Framework Roadmap (TDX18)
Developer Force
 

More from Developer Force (8)

Developing Trusted Networks with Salesforce Blockchain
Developing Trusted Networks with Salesforce BlockchainDeveloping Trusted Networks with Salesforce Blockchain
Developing Trusted Networks with Salesforce Blockchain
 
Preview: Local Development for Lightning Web Components
Preview: Local Development for Lightning Web ComponentsPreview: Local Development for Lightning Web Components
Preview: Local Development for Lightning Web Components
 
Integrate with MuleSoft Anypoint
Integrate with MuleSoft AnypointIntegrate with MuleSoft Anypoint
Integrate with MuleSoft Anypoint
 
Get Started with the Lightning Platform
Get Started with the Lightning PlatformGet Started with the Lightning Platform
Get Started with the Lightning Platform
 
Meet Astro & Friends with Domenique Sillett-Buxton
Meet Astro & Friends with Domenique Sillett-BuxtonMeet Astro & Friends with Domenique Sillett-Buxton
Meet Astro & Friends with Domenique Sillett-Buxton
 
Salesforce Lightning Supersession (TDX18)
Salesforce Lightning Supersession (TDX18)Salesforce Lightning Supersession (TDX18)
Salesforce Lightning Supersession (TDX18)
 
Salesforce Lightning Customization Roadmap (TDX18)
Salesforce Lightning Customization Roadmap (TDX18)Salesforce Lightning Customization Roadmap (TDX18)
Salesforce Lightning Customization Roadmap (TDX18)
 
Salesforce Lightning Component Framework Roadmap (TDX18)
Salesforce Lightning Component Framework Roadmap (TDX18)Salesforce Lightning Component Framework Roadmap (TDX18)
Salesforce Lightning Component Framework Roadmap (TDX18)
 

Recently uploaded

GraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge GraphGraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge Graph
Guy Korland
 
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
Sri Ambati
 
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Albert Hoitingh
 
How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...
Product School
 
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Paige Cruz
 
FIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdfFIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance
 
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
UiPathCommunity
 
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptxSecstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
nkrafacyberclub
 
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Thierry Lestable
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
KatiaHIMEUR1
 
A tale of scale & speed: How the US Navy is enabling software delivery from l...
A tale of scale & speed: How the US Navy is enabling software delivery from l...A tale of scale & speed: How the US Navy is enabling software delivery from l...
A tale of scale & speed: How the US Navy is enabling software delivery from l...
sonjaschweigert1
 
Free Complete Python - A step towards Data Science
Free Complete Python - A step towards Data ScienceFree Complete Python - A step towards Data Science
Free Complete Python - A step towards Data Science
RinaMondal9
 
Key Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdfKey Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdf
Cheryl Hung
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
Prayukth K V
 
The Future of Platform Engineering
The Future of Platform EngineeringThe Future of Platform Engineering
The Future of Platform Engineering
Jemma Hussein Allen
 
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdfSAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
Peter Spielvogel
 
Assure Contact Center Experiences for Your Customers With ThousandEyes
Assure Contact Center Experiences for Your Customers With ThousandEyesAssure Contact Center Experiences for Your Customers With ThousandEyes
Assure Contact Center Experiences for Your Customers With ThousandEyes
ThousandEyes
 
PCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase TeamPCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase Team
ControlCase
 
Quantum Computing: Current Landscape and the Future Role of APIs
Quantum Computing: Current Landscape and the Future Role of APIsQuantum Computing: Current Landscape and the Future Role of APIs
Quantum Computing: Current Landscape and the Future Role of APIs
Vlad Stirbu
 
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdfFIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance
 

Recently uploaded (20)

GraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge GraphGraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge Graph
 
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
 
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
 
How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...
 
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
 
FIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdfFIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdf
 
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
 
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptxSecstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
 
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
 
A tale of scale & speed: How the US Navy is enabling software delivery from l...
A tale of scale & speed: How the US Navy is enabling software delivery from l...A tale of scale & speed: How the US Navy is enabling software delivery from l...
A tale of scale & speed: How the US Navy is enabling software delivery from l...
 
Free Complete Python - A step towards Data Science
Free Complete Python - A step towards Data ScienceFree Complete Python - A step towards Data Science
Free Complete Python - A step towards Data Science
 
Key Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdfKey Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdf
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
 
The Future of Platform Engineering
The Future of Platform EngineeringThe Future of Platform Engineering
The Future of Platform Engineering
 
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdfSAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
 
Assure Contact Center Experiences for Your Customers With ThousandEyes
Assure Contact Center Experiences for Your Customers With ThousandEyesAssure Contact Center Experiences for Your Customers With ThousandEyes
Assure Contact Center Experiences for Your Customers With ThousandEyes
 
PCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase TeamPCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase Team
 
Quantum Computing: Current Landscape and the Future Role of APIs
Quantum Computing: Current Landscape and the Future Role of APIsQuantum Computing: Current Landscape and the Future Role of APIs
Quantum Computing: Current Landscape and the Future Role of APIs
 
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdfFIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
 

codeLive: Positive and negative testing

  • 1. CodeLive with Salesforce Developers August 28, 2019 Positive and Negative Testing with Kevin Poorman & Melissa Mueller
  • 2. Melissa Mueller @AstroLovesCodey Developer Evangelist, Salesforce.com Thinks in code. Often NPE’s CodeLive with Melissa Mueller & Kevin Poorman Kevin Poorman @codefriar Stays cool as a Software Engineer at Mitsubishi Electric Trane HVAC USA
  • 3. Introductions FLS Sing-a-long Explanation of the problem Coding our solution Recap Talking about what we’re gonna talk about. #meta Today’s Agenda
  • 4. This presentation may contain forward-looking statements that involve risks, uncertainties, and assumptions. If any such uncertainties materialize or if any of the assumptions proves incorrect, the results of salesforce.com, inc. could differ materially from the results expressed or implied by the forward-looking statements we make. All statements other than statements of historical fact could be deemed forward-looking, including any projections of product or service availability, subscriber growth, earnings, revenues, or other financial items and any statements regarding strategies or plans of management for future operations, statements of belief, any statements concerning new, planned, or upgraded services or technology developments and customer contracts or use of our services. The risks and uncertainties referred to above include – but are not limited to – risks associated with developing and delivering new functionality for our service, new products and services, our new business model, our past operating losses, possible fluctuations in our operating results and rate of growth, interruptions or delays in our Web hosting, breach of our security measures, the outcome of any litigation, risks associated with completed and any possible mergers and acquisitions, the immature market in which we operate, our relatively limited operating history, our ability to expand, retain, and motivate our employees and manage our growth, new releases of our service and successful customer deployment, our limited history reselling non-salesforce.com products, and utilization and selling to larger enterprise customers. Further information on potential factors that could affect the financial results of salesforce.com, inc. is included in our annual report on Form 10-K for the most recent fiscal year and in our quarterly report on Form 10-Q for the most recent fiscal quarter. These documents and others containing important disclosures are available on the SEC Filings section of the Investor Information section of our Website. Any unreleased services or features referenced in this or other presentations, press releases or public statements are not currently available and may not be delivered on time or at all. Customers who purchase our services should make the purchase decisions based upon features that are currently available. Salesforce.com, inc. assumes no obligation and does not intend to update these forward-looking statements. Statement under the Private Securities Litigation Reform Act of 1995 Forward-Looking Statement
  • 5. Let’s be Positive about Negative Testing! Positive and Negative Unit Testing for fun and profit.
  • 6. Positive Tests Are you sure? Positive.
  • 7. Negative Tests Are you sure? … Yes.
  • 8. Goals: High Test coverage Confidence that our code works as expected Confidence that our code fails when, and how we expect Our solution. Let’s write some tests
  • 10. This way to the code In case Kevin forgets, this is where we (finally) get away from the slides and to the coding bits.
  • 11. Today we Identify properly scoped ‘units’ for unit testing Write useful positive unit tests Write useful negative unit tests TESTED ALL THE THINGS
  • 12. Key Takeaways Unit testing helps you craft better software A unit isn’t necessarily an entire method. Positive unit tests build confidence that your code works as expected with a known set of inputs. Negative unit tests build confidence that your code fails how, and when it should. Remember this!
  • 13. Complete the testing Trailmix: https://sforce.co/positive-negative- testing trailhead.salesforce.com Check out the code at: https://github.com/sfcodelive/positiveAndNegativeTesting