BeginnerCoder

Lesson 16 — Capstone: review an AI to-do app

Everything at once

An assistant wrote a small to-do list module. It looks fine. It has three bugs. Your job is the full review workflow from this course:

  1. Read the code and the comments — what should each function do?
  2. Write tests for the cases the assistant probably forgot (here: blank titles and extra spaces).
  3. Run the tests and read the failures and crashes.
  4. Fix the bugs — one at a time, re-running the tests after each fix.
  5. Done means all tests pass, not "it looks right".

Each test below is a small function that sets up fresh data and returns (got, want). The runner calls every test, catches crashes, and counts the passes. Users number tasks from 1, but Python lists start at 0 — keep that in mind.

Why it matters: this is the real job of coding with AI. The assistant writes the first draft in seconds; you make it correct — and you are the one responsible when it ships.

Want it another way?
Task

Write test_blank_title and test_strip_title (see the TODO) and add them to TESTS. Then find and fix the 3 bugs until all 7 tests pass.

Run your code — when the output matches the task, you will see a green check. Then mark the lesson complete.

Test your knowledge

A quick 3-question quiz on this lesson — instant feedback.

Enjoying this lesson? Share it.

Keep going with Coding with AI: ChatGPT & Claude

Ready for more? Optional paid resources that pick up where this lesson leaves off.

Some links on this page are affiliate links: we may earn a commission at no extra cost to you. As an Amazon Associate I earn from qualifying purchases.