Skip to content

XP123

Exploring Extreme Programming

Menu

Primary menu

  • Home
  • Refactoring Workshop
  • Start Here
    • Comics
    • TDD: Test-Driven Development
    • Refactoring
    • User Stories
    • Dungeons & Patterns
  • Update
  • About
  • Contact

Tag Archives: tdd

TDD with Recursion

Posted on October 6, 2022 by Bill Wake

Recursion means you define something in terms of itself. Some data fits naturally with recursion, e.g., trees. We’ll look at how to use TDD with recursion. We’ll use a tree for our running example. A (binary) tree is either a leaf, Continue reading TDD with Recursion→

Posted in xp123.com | Tagged programmer, tdd, XPlorations

Typealias for TDD

Posted on September 6, 2022 by Bill Wake

There’s a tension when you introduce new objects: type checking can help, but it often gets in the way while you’re exploring. If your language supports it, typealias can smooth the transition from untyped to typed. Typealias In Swift, Kotlin, Continue reading Typealias for TDD→

Posted in xp123.com | Tagged programmer, tdd, XPlorations

Loop Unrolling: While ⇒ If-While

Posted on November 24, 2021 by Bill Wake

Loop unrolling is a performance optimization where you repeat the inside of a loop to reduce the looping overhead. It’s also a way to get rid of loops, and we’ll look at an example from a test. While ⇒ If-While Continue reading Loop Unrolling: While ⇒ If-While→

Posted in xp123.com | Tagged refactoring, tdd, XPlorations

Lambda to Reduce Coupling

Posted on October 27, 2021 by Bill Wake

Coupling occurs when one part of a system depends on another part. That is, if one part changes, the other must be adjusted too. Lambda expressions can reduce coupling by needing to refer to fewer things. Dependencies on Objects Consider Continue reading Lambda to Reduce Coupling→

Posted in xp123.com | Tagged design, programmer, refactoring, tdd, XPlorations

Example Parameterized Tests: Java, Kotlin, and Swift

Posted on September 14, 2021 by Bill Wake

Last time (“Extracting” in References), we looked at why you’d use parameterized tests, to reduce duplication, improve clarity, and improve test quality. This time we’ll look at an example parameterized test in three languages: Java, Kotlin, and Swift. Java Example Continue reading Example Parameterized Tests: Java, Kotlin, and Swift→

Posted in xp123.com | Tagged design, tdd, XPlorations

Extracting Parameterized Unit Tests

Posted on September 8, 2021 by Bill Wake

Duplication across tests may not be as harmful as duplication in production code, but a parameterized unit test can reduce duplication and help us create better tests. Judging Tests – The Pause Spotting duplication in tests is like spotting it Continue reading Extracting Parameterized Unit Tests→

Posted in xp123.com | Tagged design, refactoring, tdd, XPlorations

Avoid Irrelevant Symmetry!

Posted on June 30, 2021 by Bill Wake

When we create test data in TDD, we do it to drive out new capabilities. But all test data is not of the same value. If your data has the wrong symmetry, it can mislead you about what’s working.  Object Continue reading Avoid Irrelevant Symmetry!→

Posted in xp123.com | Tagged programmer, tdd, XPlorations

Testing Objects and Relationships

Posted on June 23, 2021 by Bill Wake

When working with objects, there are different ways you can make them interact. We’ll take a quick look at a variety of connections, what’s needed to test them, and some alternatives you might consider.  The connections below are in generally Continue reading Testing Objects and Relationships→

Posted in xp123.com | Tagged tdd, XPlorations

Revise Tests While Refactoring? It Depends

Posted on June 9, 2021 by Bill Wake

Some refactorings (e.g., Extract Method or Extract Class) introduce new elements. Should you revise the tests to take these into account? The classic consultant’s answer applies: It depends. The obvious next question is “Depends on what?”, and we’ll explore some Continue reading Revise Tests While Refactoring? It Depends→

Posted in xp123.com | Tagged programmer, tdd, XPlorations

Authorization – TDD Patterns

Posted on May 19, 2021 by Bill Wake

Authorization is the process of deciding whether to allow a user can access or use some resource. (Don’t confuse it with authentication, the process of deciding whether a user is who they claim to be.) TDD and Authorization From a Continue reading Authorization – TDD Patterns→

Posted in xp123.com | Tagged programmer, tdd, XPlorations

Post navigation

← Older posts
Newer posts →

Primary Sidebar Widget Area

Stay Up-to-Date

If you'd like to hear when articles come out, sign up today!

|●  Become a Patron!

Recent Posts

  • AAA and the Object Lifecycle
  • “Test Interface, Not Implementation”
  • How to Reduce Coupling, Three Ways
  • Reordering Items, Four Ways
  • And-Or Trees
  • Run Tests Without an App — Step by Step with Xcode
  • Swift Testing – A New Unit Testing Framework
  • TDD with a Function Pipeline
  • Trees – Confidence in Design
  • Pipelines – Confidence in Design

Tags

agile analysis atdd author business charts classic coach computers conference cool customer design economics fiction games HCI history improv integration interesting intro Java job aids language lean learning metaphor music myth patterns planning programmer refactoring resources reviews scrum software spreadsheet stories tdd team tester training XPlorations

Archives

counter for wordpress
Copyright © 2026 XP123. All Rights Reserved.
Theme: Catch Box by Catch Themes
Scroll Up