/Crafting-Test-Driven-Software-with-Python

Crafting Test-Driven Software with Python by Packt Publishing

Primary LanguagePythonMIT LicenseMIT

Crafting Test-Driven Software with Python

Book Name

This is the code repository for Crafting Test-Driven Software with Python, published by Packt.

Write test suites that scale with your applications needs and complexity, using Python and PyTest

What is this book about?

Test-driven development (TDD) is a set of best practices that helps developers to build more scalable software, and is used to increase the robustness of software by using automatic tests. This book shows you how to apply TDD practices efficiently in Python projects.

This book covers the following exciting features:

  • Find out how tests can make your life easier as a developer and discover related best practices
  • Explore and learn PyTest, the most widespread testing framework for Python
  • Get to grips with the most common PyTest plugins, including coverage, flaky, xdist, and picked
  • Write functional tests for WSGI web applications with WebTest
  • Run end-to-end tests for web applications using the Robot framework

If you feel this book is for you, get your copy today!

https://www.packtpub.com/

Instructions and Navigations

All of the code is organized into folders. For example, Chapter01.

The code will look like the following:

import unittest

class MyTestCase(unittest.TestCase):
    def test_one(self):
        pass

Following is what you need for this book: This book is for Python developers looking to get started with test-driven development and developers who want to learn about the testing tools available in Python. Developers who want to create web applications with Django and Python and plan to implement TDD methodology with PyTest will find this book useful. Basic knowledge of Python programming is required.

With the following software and hardware list you can run all code files present in the book (Chapter 1-12).

Software and Hardware List

Chapter Software required OS required
1-12 Python 3.9,3.8 or 3.7 Windows, Mac OS X, and Linux (Any)
5-10 PyTest 6.0.2+ Windows, Mac OS X, and Linux (Any)
1-12 pip 18+ Windows, Mac OS X, and Linux (Any)
1-12 Google Chrome or Firefox Windows, Mac OS X, and Linux (Any)

Related products

Get to Know the Author

Alessandro Molina is a Python developer since 2001, who has always been interested in Python as a Web Development Platform. He worked as CTO and team leader of Python teams for the past 10 years and is currently core developer of the TurboGears2 web framework and maintainer of Beaker Caching/Session framework. He also authored the Modern Python Standard Library Cookbook. created the DEPOT file storage framework and the DukPy JavaScript interpreter for Python and collaborated with various Python projects related to web development, such as FormEncode, ToscaWidgets, and the Ming MongoDB ORM.

Other books by the author