Test & Code

195: What would you change about pytest? - Anthony Sottile


Listen Later

Anthony Sottile and Brian discuss changes that would be cool for pytest, even unrealistic changes. These are changes we'd make to pytest if we didn't ahve to care about backwards compatibilty.

Anthony's list:

  1. The import system
  2. Multi-process support out of the box
  3. Async support
  4. Changes to the fixture system
  5. Extend the assert rewriting to make it modular
  6. Add matchers to assert mechanism
  7. Ban test class inheritance

Brian's list: 

  1. Extend assert rewriting for custom rewriting, like check
  2. pytester matchers available for all tests
  3. Throw out nose and unittest compatibility plugins
  4. Throw out setup_module, teardown_module and other xunit style functions
  5. Remove a bunch of the hook functions
  6. Documentation improvement of remaining hook functions which include examples of how to use it
  7. Start running tests before collection is done
  8. Split collection and running into two processes
  9. Have the fixtures be able to know the result of the test during teardown


Links:

  • anthonywritescode - YouTube
  • anthonywritescode - Twitch
  • pytest-asyncio · PyPI
  • async test patterns for pytest
  • future-fstrings · PyPI
  • re-assert · PyPI
  • numpy.testing
  • Sourcegraph



...more
View all episodesView all episodes
Download on the App Store

Test & CodeBy Brian Okken

  • 4.7
  • 4.7
  • 4.7
  • 4.7
  • 4.7

4.7

70 ratings


More shows like Test & Code

View all
Software Engineering Radio by se-radio@computer.org

Software Engineering Radio

273 Listeners

The Changelog: Software Development, Open Source by Changelog Media

The Changelog: Software Development, Open Source

289 Listeners

Thoughtworks Technology Podcast by Thoughtworks

Thoughtworks Technology Podcast

41 Listeners

Data Skeptic by Kyle Polich

Data Skeptic

475 Listeners

Talk Python To Me by Michael Kennedy

Talk Python To Me

588 Listeners

Software Engineering Daily by Software Engineering Daily

Software Engineering Daily

625 Listeners

Soft Skills Engineering by Jamison Dance and Dave Smith

Soft Skills Engineering

282 Listeners

Python Bytes by Michael Kennedy and Brian Okken

Python Bytes

216 Listeners

Data Engineering Podcast by Tobias Macey

Data Engineering Podcast

140 Listeners

Syntax - Tasty Web Development Treats by Wes Bos & Scott Tolinski - Full Stack JavaScript Web Developers

Syntax - Tasty Web Development Treats

983 Listeners

Practical AI by Practical AI LLC

Practical AI

206 Listeners

The Stack Overflow Podcast by The Stack Overflow Podcast

The Stack Overflow Podcast

64 Listeners

The Real Python Podcast by Real Python

The Real Python Podcast

139 Listeners

Oxide and Friends by Oxide Computer Company

Oxide and Friends

58 Listeners

The Pragmatic Engineer by Gergely Orosz

The Pragmatic Engineer

61 Listeners