Reader small image

You're reading from  Python GUI Programming with Tkinter, 2nd edition - Second Edition

Product typeBook
Published inOct 2021
Reading LevelBeginner
PublisherPackt
ISBN-139781801815925
Edition2nd Edition
Languages
Tools
Right arrow
Author (1)
Alan D. Moore
Alan D. Moore
author image
Alan D. Moore

Alan D. Moore is a data analyst and software developer who has been solving problems with Python since 2006. He's developed both open source and private code using frameworks like Django, Flask, Qt, and of course Tkinter, and is known to contribute to various open-source Python and JavaScript projects. Alan maintains a YouTube channel, “Alan D Moore Codes”, where he posts Python, PyQt, and Tkinter tutorials. Alan lives in Franklin, Tennessee, where he works for the County Government, and with his wife Cara raises a crew of children who are just as geeky as their dad.
Read more about Alan D. Moore

Right arrow

Automated testing basics

Up until now, testing our application has been a process of launching it, running it through a few basic procedures, and verifying that it did what we expected it to do. This approach works acceptably on a very small script, but, as our application grows, it becomes an increasingly time-consuming and error-prone process to verify the application's behavior.

Using automated testing, we can consistently verify our application logic within seconds. There are several forms of automated testing, but the two most common are unit testing and integration testing. Unit tests work with discrete pieces of code in isolation, allowing us to quickly verify the behavior of specific sections. Integration tests verify the interactions of multiple units of code. We'll be writing both kinds of tests to verify the behavior of our application.

A simple unit test

At its most basic, a unit test is just a short program that runs a unit of code under different...

lock icon
The rest of the page is locked
Previous PageNext Page
You have been reading a chapter from
Python GUI Programming with Tkinter, 2nd edition - Second Edition
Published in: Oct 2021Publisher: PacktISBN-13: 9781801815925

Author (1)

author image
Alan D. Moore

Alan D. Moore is a data analyst and software developer who has been solving problems with Python since 2006. He's developed both open source and private code using frameworks like Django, Flask, Qt, and of course Tkinter, and is known to contribute to various open-source Python and JavaScript projects. Alan maintains a YouTube channel, “Alan D Moore Codes”, where he posts Python, PyQt, and Tkinter tutorials. Alan lives in Franklin, Tennessee, where he works for the County Government, and with his wife Cara raises a crew of children who are just as geeky as their dad.
Read more about Alan D. Moore