Flat Files (a.k.a. CSV files)

Posted on Fri 16 July 2021 in TDDA • Tagged with data

This week, a client I'm working for received a large volume of data, and as usual the data was sent as "flat" files—or CSV (comma-separated values1) files, as they are more often called. Everyone hates CSV files, because they are badly specified, contain little metadata and are generally …

Continue reading

Sharing Tests across Implementations by Externalizing Test Data

Posted on Sun 30 August 2020 in TDDA • Tagged with tests, reference tests, data

I've been dabbling in Swift—Apple's new-ish programming language—recently. One of the things I often do when learning a new language is either to take an existing project in a language I know (usually, Python) and translate it to the new one, or (better) to try a new project …

Continue reading

Reference Testing Exercise 2 (pytest flavour)

Posted on Thu 31 October 2019 in TDDA • Tagged with reference test, exercise, screencast, video, pytest

This exercise (video 2m 58s) shows a powerful way to run only a single test, or some subset of tests, by using the @tag decorator available in the TDDA library. This is useful for speeding up the test cycle and allowing you to focus on a single test, or a …

Continue reading

Reference Testing Exercise 2 (unittest flavour)

Posted on Wed 30 October 2019 in TDDA • Tagged with reference test, exercise, screencast, video, unittest

This exercise (video 3m 34s) shows a powerful way to run only a single test, or some subset of tests, by using the @tag decorator available in the TDDA library. This is useful for speeding up the test cycle and allowing you to focus on a single test, or a …

Continue reading

Reference Testing Exercise 1 (pytest flavour)

Posted on Tue 29 October 2019 in TDDA • Tagged with reference test, exercise, screencast, video, pytest

This exercise (video 8m 54s) shows how to migrate a test from using pytest directly to the exploiting the referencetest capabilities in the TDDA library. (If you do not currently use pytest for writing tests, you might prefer the unittest-flavoured version of this exercise, since unittest is in Python's standard …

Continue reading