-
Notifications
You must be signed in to change notification settings - Fork 414
Added a tutorial for running and creating unit tests. #2554
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added a tutorial for running and creating unit tests. #2554
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very great PR, and very well written documentation. I have left some comments of the PR regarding a few things, but for the most part this looks very good.
00bae72
to
eca55b8
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
eca55b8
to
a5c8733
Compare
a5c8733
to
07547a3
Compare
@vaughnbetz Please review |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks very good, thanks! Just a couple of minor suggestions.
README.developers.md
Outdated
```shell | ||
#include "catch2/catch_test_macros.hpp" | ||
|
||
// To choose a tag, see examples from when you run ./test_vpr --list-tests in the test exectuable directory, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this be "to choose a test name" (not tag).
README.developers.md
Outdated
#include "catch2/catch_test_macros.hpp" | ||
|
||
// To choose a tag, see examples from when you run ./test_vpr --list-tests in the test exectuable directory, | ||
// as shown earlier. A good default tag name is the name of the test: in this case, [vpr]. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this mean the syntax below ([test_tag]) will be filled in with [vpr]? Or are you saying [vpr] would be a good tag name for a test of a feature within the vpr code base?
I think clarifying this text a bit would be good.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is meant to give a recommendation for the tag in square brackets. I've changed it now so that hopefully this is clear
07547a3
to
f13a5b0
Compare
Looks good -- thanks! |
Description
Modified the Developer Guide to give a basic tutorial for how to (1) run testers and (2) create unit tests, including a simple example. Also added
test_archfpga
to the list of tests that are run bymake test
.Motivation and Context
There was only a brief tutorial on how to run unit tests in the guide previously: one instruction to run
make && make test
. This is not very helpful for anyone wanting to create their own unit tests, or run individual tests that target part of the software.Types of changes
Checklist: