Skip to content
Snippets Groups Projects
Unity_notes.md 902 B
Newer Older
Peter Thedens's avatar
Peter Thedens committed
# Unity Notes

Peter Thedens's avatar
Peter Thedens committed
- When using Unity, be sure to define `UNITY_INCLUDE_CONFIG_H`
Peter Thedens's avatar
Peter Thedens committed
to use the [`unity_config.h`](/Unity/src/unity_config.h).
Peter Thedens's avatar
Peter Thedens committed
  - For the quad directory, this is done at compile-time of the Unity library [here](/Unity/src/Makefile#L4)
and at compile-time of the test runner [here](/quad/library.mk#L58).
- Follow the examples in the [`Unity/examples`](/Unity/examples) for a guide, as well
Peter Thedens's avatar
Peter Thedens committed
as the documentation in [`Unity/docs`](/Unity/docs)
Peter Thedens's avatar
Peter Thedens committed
  - The [Unity Getting Started guide](/Unity/doc/UnityGettingStartedGuide.md) and the
[Unity Assertions Cheat Sheet Suitable for Printing and Possibly Framing]
(/Unity/doc/UnityAssertionsCheatSheetSuitableforPrintingandPossiblyFraming.pdf)
are nice references
  - Generally, the format is to start `main()` with `UNITY_BEGIN()`, followed by calls to
`RUN_TEST(test_function)` where `test_function` is a test to run, ended with
`return UNITY_END()`