# \#doctest

**URL:** https://erlangforums.com/tag/doctest/762.md

[Latest](https://erlangforums.com/latest.md) · [Categories](https://erlangforums.com/categories.md) · [Tags](https://erlangforums.com/tags.md)

---

## [Doctest - a library to test Erlang doc attributes](https://erlangforums.com/t/doctest-a-library-to-test-erlang-doc-attributes/3614)

<div class="topic-metadata">

**Author:** [@williamthome](https://erlangforums.com/u/williamthome)\
**Replies:** 30\
**Last updated:** [April 3, 2025, 9:49pm UTC](https://erlangforums.com/t/doctest-a-library-to-test-erlang-doc-attributes/3614 "2025-04-03T21:49:20Z")

</div>

OTP 27 has implemented the -doc attribute, but what if its examples could be tested? That’s the purpose of the doctest lib. The motivation for it is this PR, which fixes some examples of the orddict module. Example Ta…
