Module test

Source
Expand description

The expansion from a test function to the appropriate test struct for libtest Ideally, this code would be in libtest but for efficiency and error messages it lives here.

Enumsยง

ShouldPanic ๐Ÿ”’
TestType ๐Ÿ”’

Functionsยง

check_bench_signature ๐Ÿ”’
check_test_signature ๐Ÿ”’
expand_bench ๐Ÿ”’
expand_test ๐Ÿ”’
expand_test_case ๐Ÿ”’
#test_case is used by custom test authors to mark tests When building for test, it needs to make the item public and gensym the name Otherwise, weโ€™ll omit the item. This behavior means that any item annotated with #test_case is never addressable.
expand_test_or_bench ๐Ÿ”’
get_location_info ๐Ÿ”’
item_path ๐Ÿ”’
not_testable_error ๐Ÿ”’
should_ignore ๐Ÿ”’
should_ignore_message ๐Ÿ”’
should_panic ๐Ÿ”’
test_type ๐Ÿ”’
Attempts to determine the type of test. Since doctests are created without macro expanding, only possible variants here are UnitTest, IntegrationTest or Unknown.