Dev48
Language
  • About
  • Services
  • Industries
  • Technologies
  • Articles
  • Contacts
Book a call
    Home/Articles/Keep your ai coding agent on a short leash with tdd
Dev48
info@dev48.org+375 29 320-40-96WhatsApp@isky_by

© 2026 · All rights reserved.

Keep Your AI Coding Agent on a Short Leash with TDD

Source: The JetBrains Blog•November 30, 2026 at 09:12 AM

Keep Your AI Coding Agent on a Short Leash with TDD

While you were off getting a coffee, your agent wrote 300 lines of Python. Are you really going to read them all? If you answered, “not really,” then you’re in good company (including mine). Agents can now write code faster than any of us can (or want to) review it, and this…

The professional Python IDE for you and your agents. Ship web, data, and ML code you can trust.

Agentic AI JetBrains Air LiveStream PyCharm Python Testing

While you were off getting a coffee, your agent wrote 300 lines of Python. Are you really going to read them all?

If you answered, “not really,” then you’re in good company (including mine). Agents can now write code faster than any of us can (or want to) review it, and this leaves a lot of us with the uncomfortable feeling that the codebase is moving faster than our understanding of it. However, I don’t think the answer is to stop using agents. It’s working out how to know whether the code is right, before you even type in the first prompt.

Join Reuven Lerner and me on December 2 for a live session on how to do exactly that with test-driven development (TDD), PyCharm, and JetBrains Air.

  • Date: December 2, 2026
  • Time: 5:30 pm UTC (6:30 pm CET / 12:30 pm EST)

How can TDD help us tame agent-written code?

Our old friend TDD is not just good for code we write ourselves. It allows us to define what correct looks like upfront, then let the agents work backwards towards this goal. This narrows the scope of the problem the agent is solving, as well as giving us an automated check as to whether the code solves it.

Reuven will show us how to use TDD in a disciplined workflow, where near-100% test coverage makes sure that almost every line of agent-written code is exercised by a test. Moreover, he’ll show us how to incorporate tools like static type checking to quickly and deterministically catch mismatched types before the code runs.

What we’ll cover, and why you should join us

In this stream, we’ll:

  • Write a test first, using PyCharm’s pytest support.
  • Hand the task to an agent of your choice using JetBrains Air, then review its implementation and flag anything that doesn’t look right.
  • Use PyCharm’s inbuilt inspections, test runner and debugger to diagnose what went wrong, and fix it.

You’ll leave with a repeatable workflow for getting the speed of an agent without giving up confidence in your code. This is aimed at all Python developers and data scientists, whether you’re already coding with agents or still deciding whether you can trust them.

Bring your questions about testing, agents, and how to keep both in check. We’ll answer them live during the stream.

About the speakers

Reuven Lerner

Reuven Lerner is a full-time Python trainer, teaching at companies around the world and via his LernerPython online platform. He publishes both Better Developers (about Python) and Bamboo Weekly (Pandas puzzles based on current events). His most recent book is AI-Assisted Python for Nonprogrammers (O’Reilly). He previously wrote Python Workout and Pandas Workout (Manning).

Jodie Burchell

Dr. Jodie Burchell is Python Advocacy Team Lead at JetBrains and was previously a Lead Data Scientist at Verve Group Europe. She completed a PhD in clinical psychology and a postdoc in biostatistics before leaving academia for a data science career.

Discover more

← All articles

What this article says

More in Software Development

All →
Understanding hotel KPIs and performance metrics
Cloudbeds

Understanding hotel KPIs and performance metrics

Elevate your hotel website’s performance with direct channel benchmarking
Cloudbeds

Elevate your hotel website’s performance with direct channel benchmarking

What your hotel booking performance can tell you about demand patterns
Cloudbeds

What your hotel booking performance can tell you about demand patterns

How to become a life coach
Teachable

How to become a life coach

How to sell online courses on Pinterest
Teachable

How to sell online courses on Pinterest

How to market online courses and boost your sales in 2027 (41 ideas ahead)
Teachable

How to market online courses and boost your sales in 2027 (41 ideas ahead)

More from JetBrains

Kodee’s Kotlin Roundup: Build Your Next App With One Prompt, a New Coroutines Course, and Kotlin on LinkedIn
JetBrains

Kodee’s Kotlin Roundup: Build Your Next App With One Prompt, a New Coroutines Course, and Kotlin on LinkedIn

Sunsetting the R plugin
JetBrains

Sunsetting the R plugin

Getting Started With Air in RustRover
JetBrains

Getting Started With Air in RustRover

Getting Started With QNX® Projects in CLion
JetBrains

Getting Started With QNX® Projects in CLion

JetBrains Subscription Prices Will Increase on February 1, 2027
JetBrains

JetBrains Subscription Prices Will Increase on February 1, 2027

Introducing the Kotlin Security Newsletter
JetBrains

Introducing the Kotlin Security Newsletter