Главная
Study mode:
on
1
Intro
2
Introduction • Problems (5) • Solution (15) . Questions (5)
3
Problem 2: Inaccurate mocks
4
Nova Docker (for example)
5
Can we do better?
6
A "verified" fake A class that
7
So let's make a start
8
Where is the docker-py API defined?
9
A public testtools module
10
A Tests Mixin
11
And now we can start fleshing out the interface
12
Starting with a test for empty list of containers.
13
Test, write code, refactor, repeat
14
Complications
15
Test public APIs not implementation details
16
Further Reading
17
Mimic
18
Eliot
19
Summary
Description:
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.

Faking It - The Art of Testing Using Verified Fakes

EuroPython Conference
Add to list
0:00 / 0:00