Chapter 9

Testing Your Code

IN THIS CHAPTER

Bullet Making a test plan

Bullet Automating your tests

Bullet Balancing AI and human testing

Bullet Generating tests

Bullet Practicing test-driven development with AI

Of all the programming tasks that AI can help with, testing is perhaps the safest. That's because running a test doesn't affect your code or the software design— it merely checks whether the software operates how it was designed.

Writing tests with AI assistance, however, is not always reliable. As you learn in this chapter, the quality of the tests and testing advice that you get from AI depends on your prompts to the AI model and how well you know which tasks are better handled by people.

Test automation is the process of using software separate from the software being tested to control the running of tests. Prior to the 1980s, most software testing was done by testers, people who would use the software to confirm that it worked. In the late 1980s, testers used tools to record their interactions with the ...

Get Coding with AI For Dummies now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.