Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

YouTube

Faking It - The Art of Testing Using Verified Fakes

EuroPython Conference via YouTube

Overview

Save Big on Coursera Plus. 7,000+ courses at $160 off. Limited Time Only!
Explore the concept of verified fakes in software testing through this EuroPython conference talk. Delve into the advantages of using verified fake implementations for simplified testing while maintaining confidence in code behavior. Examine a case study demonstrating how to write and verify fake implementations of public APIs. Learn how to create reusable tests that validate both fake and real implementations. Discover real-world examples of verified fakes in open-source projects, including Flocker's block device backend and Eliot's memory logger. Understand the limitations of unverified mocking and the potential benefits of incorporating verified fakes in libraries like Boto and Docker-py. Gain insights into writing effective tests for public APIs and implementation details.

Syllabus

Intro
Introduction • Problems (5) • Solution (15) . Questions (5)
Problem 2: Inaccurate mocks
Nova Docker (for example)
Can we do better?
A "verified" fake A class that
So let's make a start
Where is the docker-py API defined?
A public testtools module
A Tests Mixin
And now we can start fleshing out the interface
Starting with a test for empty list of containers.
Test, write code, refactor, repeat
Complications
Test public APIs not implementation details
Further Reading
Mimic
Eliot
Summary

Taught by

EuroPython Conference

Reviews

Start your review of Faking It - The Art of Testing Using Verified Fakes

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.