mirror of
https://github.com/ThrowTheSwitch/Unity.git
synced 2026-01-30 03:34:27 +01:00
Add guard TEST on test module template
With a test file guarded we can include this file on IDE project (MPLAB X in my case) and compile without excluding test files. Excluding test files on MPLAB X disable autocompletion and function navigation.
This commit is contained in:
@@ -13,7 +13,9 @@ require 'fileutils'
|
|||||||
require 'pathname'
|
require 'pathname'
|
||||||
|
|
||||||
# TEMPLATE_TST
|
# TEMPLATE_TST
|
||||||
TEMPLATE_TST ||= '#include "unity.h"
|
TEMPLATE_TST ||= '#ifdef TEST
|
||||||
|
|
||||||
|
#include "unity.h"
|
||||||
|
|
||||||
%2$s#include "%1$s.h"
|
%2$s#include "%1$s.h"
|
||||||
|
|
||||||
@@ -29,6 +31,8 @@ void test_%4$s_NeedToImplement(void)
|
|||||||
{
|
{
|
||||||
TEST_IGNORE_MESSAGE("Need to Implement %1$s");
|
TEST_IGNORE_MESSAGE("Need to Implement %1$s");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif // TEST
|
||||||
'.freeze
|
'.freeze
|
||||||
|
|
||||||
# TEMPLATE_SRC
|
# TEMPLATE_SRC
|
||||||
|
|||||||
Reference in New Issue
Block a user