---
title: "Comment by Reza Lavarian on \"7 non-obvious benefits of automated testing\" | Hashnode"
description: "Automated tests play the role of code samples. I&#39;d like to emphasize this sentence, code samples are super helpful. It even affects the whole design of a fe"
url: "https://hashnode.com/posts/non-obvious-benefits-automated-testing/5f96f5ed9ffb2210b6964907/comment/603d46583478900323500ec0"
---

[Discussion](https://hashnode.com/posts/non-obvious-benefits-automated-testing/5f96f5ed9ffb2210b6964907)

Comment [7 non-obvious benefits of automated testing](https://hashnode.com/posts/non-obvious-benefits-automated-testing/5f96f5ed9ffb2210b6964907)

[Reza Lavarian](https://hashnode.com/@lavary)

[Mar 1, 2021](https://hashnode.com/posts/non-obvious-benefits-automated-testing/5f96f5ed9ffb2210b6964907/comment/603d46583478900323500ec0)

> Automated tests play the role of code samples.

I'd like to emphasize this sentence, code samples are super helpful.

It even affects the whole design of a feature. Especially, when developing the API, first, and then the implementation, like how we do in TDD.

Good writing style, by the way. Thanks!

[Mario Cervera](https://hashnode.com/@macerub)

[Mar 1, 2021](https://hashnode.com/posts/non-obvious-benefits-automated-testing/5f96f5ed9ffb2210b6964907/comment/603d46583478900323500ec0#reply-603d4c7dc3970d02fe0fe0a2)

Thanks Reza! 🙏

Yes, that's an important benefit. When we write tests, we are effectively using our APIs. If the design is bad, our tests will suffer (e.g. they will be less readable). This is one of the ways testing has a strong positive impact on design.
