Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
Actor Framework
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
cpp-libs
Actor Framework
Commits
8f33b03e
Commit
8f33b03e
authored
Jun 03, 2021
by
Dominik Charousset
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'topic/neverlord/dead-code'
parents
186e2a16
d7a79799
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
9 additions
and
39 deletions
+9
-39
CHANGELOG.md
CHANGELOG.md
+5
-0
libcaf_core/test/config_value.cpp
libcaf_core/test/config_value.cpp
+2
-2
libcaf_test/caf/test/unit_test.hpp
libcaf_test/caf/test/unit_test.hpp
+0
-37
libcaf_test/caf/test/unit_test_impl.hpp
libcaf_test/caf/test/unit_test_impl.hpp
+2
-0
No files found.
CHANGELOG.md
View file @
8f33b03e
...
...
@@ -13,6 +13,11 @@ is based on [Keep a Changelog](https://keepachangelog.com).
via config file or CLI to
`0s`
and then printing the config parameter, e.g.,
via
`--dump-config`
.
### Removed
-
Dropped three obsolete (and broken) macros in the
`unit_test.hpp`
header:
`CAF_CHECK_FAILED`
,
`CAF_CHECK_FAIL`
and
`CAF_CHECK_PASSED`
.
## [0.18.3] - 2021-05-21
### Added
...
...
libcaf_core/test/config_value.cpp
View file @
8f33b03e
...
...
@@ -877,7 +877,7 @@ CAF_TEST_FIXTURE_SCOPE_END()
auto res = make_config_value_list(__VA_ARGS__); \
CHECK_EQ(*converted, get<config_value::list>(res)); \
} else { \
CAF_
CHECK_FAILED(converted.error());
\
CAF_
ERROR(converted.error());
\
} \
})()
...
...
@@ -898,7 +898,7 @@ CAF_TEST(list baseline testing) {
auto res = config_value::dictionary{__VA_ARGS__}; \
CHECK_EQ(*converted, res); \
} else { \
CAF_
CHECK_FAILED(converted.error());
\
CAF_
ERROR(converted.error());
\
} \
})()
...
...
libcaf_test/caf/test/unit_test.hpp
View file @
8f33b03e
...
...
@@ -514,28 +514,6 @@ using caf_test_case_auto_fixture = caf::test::dummy_fixture;
::caf::test::engine::last_check_line(__LINE__); \
} while (false)
#define CAF_CHECK_PASSED(msg) \
do { \
auto out = ::caf::test::logger::instance().massive(); \
out << term::green << "** " << term::blue << __FILE__ << term::yellow \
<< ":" << term::blue << __LINE__ \
<< ::caf::test::detail::fill(__LINE__) << term::reset << msg << '\n'; \
::caf::test::engine::current_test()->pass(); \
::caf::test::engine::last_check_file(__FILE__); \
::caf::test::engine::last_check_line(__LINE__); \
} while (false)
#define CAF_CHECK_FAILED(msg) \
do { \
auto out = ::caf::test::logger::instance().massive(); \
out << term::red << "!! " << term::blue << __FILE__ << term::yellow << ":" \
<< term::blue << __LINE__ << ::caf::test::detail::fill(__LINE__) \
<< term::reset << msg << '\n'; \
::caf::test::engine::current_test()->fail(false); \
::caf::test::engine::last_check_file(__FILE__); \
::caf::test::engine::last_check_line(__LINE__); \
} while (false)
#define CAF_CHECK(...) \
[](bool expr_result) { \
return ::caf::test::detail::check_un(expr_result, __FILE__, __LINE__, \
...
...
@@ -550,20 +528,9 @@ using caf_test_case_auto_fixture = caf::test::dummy_fixture;
__FILE__, __LINE__, \
CAF_FUNC_EXPR(func, x_expr, y_expr), false, \
comparator(x_val, y_val), x_val, y_val); \
::caf::test::engine::last_check_file(__FILE__); \
::caf::test::engine::last_check_line(__LINE__); \
return caf_check_res; \
}(x_expr, y_expr)
#define CAF_CHECK_FAIL(...) \
do { \
static_cast<void>(::caf::test::detail::check( \
::caf::test::engine::current_test(), __FILE__, __LINE__, #__VA_ARGS__, \
true, static_cast<bool>(__VA_ARGS__))); \
::caf::test::engine::last_check_file(__FILE__); \
::caf::test::engine::last_check_line(__LINE__); \
} while (false)
#define CAF_FAIL(msg) \
do { \
CAF_TEST_PRINT_ERROR(msg); \
...
...
@@ -579,8 +546,6 @@ using caf_test_case_auto_fixture = caf::test::dummy_fixture;
static_cast<bool>(__VA_ARGS__)); \
if (!CAF_UNIQUE(__result)) \
::caf::test::detail::requirement_failed(#__VA_ARGS__); \
::caf::test::engine::last_check_file(__FILE__); \
::caf::test::engine::last_check_line(__LINE__); \
} while (false)
#define CAF_REQUIRE_FUNC(func, x_expr, y_expr) \
...
...
@@ -595,8 +560,6 @@ using caf_test_case_auto_fixture = caf::test::dummy_fixture;
if (!CAF_UNIQUE(__result)) \
::caf::test::detail::requirement_failed( \
CAF_FUNC_EXPR(func, x_expr, y_expr)); \
::caf::test::engine::last_check_file(__FILE__); \
::caf::test::engine::last_check_line(__LINE__); \
} while (false)
#define CAF_TEST_IMPL(name, disabled_by_default) \
...
...
libcaf_test/caf/test/unit_test_impl.hpp
View file @
8f33b03e
...
...
@@ -150,6 +150,8 @@ bool check(test* parent, const char* file, size_t line, const char* expr,
<<
term
::
blue
<<
line
<<
fill
(
line
)
<<
term
::
reset
<<
expr
<<
'\n'
;
parent
->
fail
(
should_fail
);
}
engine
::
last_check_file
(
file
);
engine
::
last_check_line
(
line
);
return
result
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment