Contract Tests - Parameterised Test Cases
June 28, 2023This is the final installment of a three-part series about contract tests. In the first blog post we’ve discussed the rationale behind contract tests. Next we’ve looked at how ...
Read more ...This is the final installment of a three-part series about contract tests. In the first blog post we’ve discussed the rationale behind contract tests. Next we’ve looked at how ...
Read more ...In the previous blog post, we’ve discussed the rationale behind contract tests. They are used for exercising those parts of an application that communicate with other parts of ...
Read more ...One of my favorite awesome talks of all time is Integrated Tests Are a Scam by J.B. Rainsberger. I must admit that the title has a clickbait vibe to it. However, I very muc...
Read more ...Back in 2003, Brian Marick wrote an excellent article series about agile testing. There he described the concept of the Testing Quadrant. To my recollection this used to be a ...
Read more ...I’ve heard that you’ve been working on this new feature for the payroll system based on the newly voted government legislation? Yes, I am. How is it going? Seems like a major...
Read more ...In the previous blog post, we discussed how to use Approval Tests for verifying generated PDF documents. In this blog post I’m going to show how to extend the Approval Test li...
Read more ...A while back I was confronted with a part of a legacy system that generates PDF documents. This legacy system used a well known library for generating the requested PDF files. ...
Read more ...Most test frameworks out there have the capability to disable tests. This is usually done by adding some kind of annotation that instructs the test runner to ignore an individu...
Read more ...I’m very happy to announce that Writing Maintainable Unit Tests is also available as a paper book. Both the ebook and the paper book have been completely self-published. I must...
Read more ...Do you have 15 minutes to spare? Sure, what can I do for you? Well, you know I’ve been working on that new feature we were discussing at the whiteboard last week. I’ve finishe...
Read more ...I’m very happy to announce that I’ve finished writing my first book Writing Maintainable Unit Tests. What an amazing journey it has been. I would never have thought that I woul...
Read more ...Using inheritance for test classes is not a desirable thing as it introduces a number of issues. An abstract base class quite often originates from the desire to share and reus...
Read more ...Once in a while I get asked the question whether one should write solitary tests for logging functionality. My answer to this question is the typical consultant answer: “It dep...
Read more ...Previously we discussed why solitary tests should be easy to read. Sometimes, the readability of solitary tests is affected by those developers who overcomplicate or overenginee...
Read more ...Occasionally someone asks me the question whether it’s necessary to test the code of solitary tests? Usually this question is ushered by folks who are opposed to the idea of au...
Read more ...So I noticed that you completed that feature that we’ve been pair programming yesterday? Yes, I was a little bored yesterday evening. So I decided to continue working on it Gr...
Read more ...Solitary tests never cross the process boundary in which they are executed. This means that a solitary test never executes code that talks to a database, communicates across the...
Read more ...I’m very happy to announce that the first draft of my book Writing Maintainable Unit Tests has been published on LeanPub. It’s the written counterpart of my video course, with ...
Read more ...One of the most commonly asked questions in developer communities regarding Test-Driven Development and unit testing is whether one should write unit tests for private methods,...
Read more ...Test-Driven Development is a discipline that exists for about two decades now. Unfortunately, to this very day, it is still not without controversy. Most professional developer...
Read more ...In the previous blog post, we’ve talked about avoiding excessive specification of test doubles. This is just one in a series of “good practices” for using test doubles in solit...
Read more ...Previously we’ve discussed the different kinds of test doubles. By using test doubles in our solitary tests, we also introduce more coupling between the test code and the imple...
Read more ...When stating the definition of a solitary test, we mentioned that they have two constraints: The code being exercised by these tests never cross the process boundary in whic...
Read more ...In the previous blog post, we’ve talked about indirect inputs and outputs when a unit test exercises a Subject Under Test. The examples shown previously demonstrate the use of ...
Read more ...Previously we discussed what state and behaviour verification is about. Depending on the nature of the production code that we’re designing, we might decide to apply one approa...
Read more ...When reasoning about types of automated tests, I find it quite useful to reason about two different categories, namely solitary and sociable tests. Also see the test pyramid fo...
Read more ...In a previous blog post, we discussed the test pyramid and why it is a useful model to reason about a healthy mix of solitary and sociable tests. I mentioned that at t...
Read more ...Previously, we touched on two different categories of automated tests, namely solitary and sociable tests. Also we discussed how and why the test pyramid is a useful model to ...
Read more ...Last week I published my very first video course titled Writing Maintainable Unit Tests. It surely has been a very learnful experience. Going through the process of creating th...
Read more ...I’m very proud to announce that my first video course has been published on Udemy. This course teaches software developers how to write maintainable and readable unit tests. It...
Read more ...In the previous blog post, we touched on two different categories of automated tests, namely solitary and sociable tests. We also mentioned that in order to build maintainable ...
Read more ...It’s more than fair to say that the terminology used in the world of automated tests can be a bit overwhelming. Software people have uncovered all sorts of tests in a wide vari...
Read more ...Test-Driven Development is a discipline that exists for almost two decades now. Unfortunately, to this very day, it is still not without controversy. Most professional developer...
Read more ...A while back I stumbled upon this talk titled Built-in Fake Objects. After I’ve watched the first 20 minutes or so, I was so worked up that I almost threw away my iPad just out ...
Read more ...People who know me personally know that I like to go for a long run on a regular basis. I sit and work at a desk all day. So as part of the work I do, labouring the codes, I go ...
Read more ...To me, developers that are not applying TDD practices during their day-to-day job always seem more in a hurry than developers that do apply red-green-refactor. In their hurry, t...
Read more ...I just want to quickly point out a tool that I’ve been playing with for a couple of days now, named AutoTest.NET. Its an open-source tool that originates from a popular tool in ...
Read more ...In my previous posts, I showed the syntax for context/specifications using Machine.Specifications (or MSpec for short) and how to use an auto mocking container in conjunction wi...
Read more ...In my previous post, I explained how to get started with Machine.Specifications (or MSpec for short) and showed you how the syntax for context/specifications looks like when usi...
Read more ...Its been a while since I evaluated and evolved my approach to BDD. The way I’ve been doing BDD up until now is described in this blog post which goes way back to 2008. Everyone ...
Read more ...I’ve been reading a lot of code lately. When I’m doing this, I find it very important to have some unit tests that makes it easier for me to comprehend the actual production cod...
Read more ...Earlier this year, I wrote this blog post about exploring Behavior-Driven Development as a better way of doing Test-Driven Development. In this post, I spoke about how to organi...
Read more ...A while ago, I wrote a blog post regarding Test Data Builders Refined. Earlier this week, I wrote a very simple base class that provides an implicit cast operator for the builde...
Read more ...I want to put out a short sequel to my previous post on Active Conventions with NDepend. Also make sure to read Patrick Smacchia's follow-up if your interested. As you may or ma...
Read more ...Last year, I blogged about Test Data Builders here and here. I still use them heavily in my unit tests for creating objects with test data. Heck, I also use this pattern for flu...
Read more ...There's a really interesting discussion going on at the ALT.NET user group about Behavior Driven Development. This post from Jimmy Bogard really hit home. It clearly describes B...
Read more ...You might think that I suffer from a severe case of acronymitis judging from the title of this post, but the only thing I suffer from right now is a terrible cold. Anyway, I'm c...
Read more ...When writing unit tests that involve interaction based testing, you most likely end up using one of the mocking frameworks out there. The mocking framework I'm using is Rhino Mo...
Read more ...A while ago, I blogged about using Test Data Builders as opposed to the Object Mother pattern. Here are some links to additional tips and tricks: Tricks with Test Data Builders...
Read more ...When writing unit tests, I frequently have an issue with creating objects that contain some test data. One approach is to call the constructor of the class at hand in every test...
Read more ...Mark Monster has written an excellent article on Dependency Injection in the newest .NET Magazine (it's no MSDN magazine, but hey, its free of charge). Nonetheless, there are tw...
Read more ...Are you doing Test-Driven Development or Bug Driven Development? From my experiences, test-driven development seems to slow you down at the beginning of a project. This isn't en...
Read more ...Another excellent post on TDD by Jeremy D. Miller. The following quote is something that needs to be up on the wall: DO learn how RhinoMocks works or DO NOT use it. Seriously...
Read more ...At work there's a discussion going on whether we will choose NUnit or Team System Unit Test for our unit tests. Currently we have about 1000+ unit tests written in NUnit and we ...
Read more ...The forthcoming release of NUnit 2.4 supports a constraint-based syntax for assertions. Don't worry, the old syntax (classic model) is still going to be available for a long tim...
Read more ...This post of Jeremy D. Miller hits it right on the head: In .NET development, and especially ASP.NET WebForms development, you often have to go out of your way to create testa...
Read more ...I recently came across the .NET Mock Objects project. This framework supplies mock implementations of the ADO.NET generic interfaces like IDataReader, IDbConnection, etc. (curre...
Read more ...June 28, 2023
April 12, 2023
February 1, 2023
June 15, 2022
February 2, 2022
The opinions expressed on this blog are my own personal opinions. These do NOT represent anyone else’s view on the world in any way whatsoever.
Thank you for visiting my website. I’m a professional software developer since Y2K. A blogger since Y2K+5. Author of Writing Maintainable Unit Tests. Provider of training and coaching in XP practices. Curator of the Awesome Talks list. Thinking and learning about all kinds of technologies since forever.
(+32) 496 38 00 82
info @ principal-it .be