Skip to content

Commit

Permalink
[lfc] Remove core.hpp
Browse files Browse the repository at this point in the history
  • Loading branch information
ArthurVal committed Jan 30, 2025
1 parent 020d42f commit 9392c2a
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 66 deletions.
16 changes: 13 additions & 3 deletions tests/test_linear_feedback_controller.cpp
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
#include <sstream>
#include <string_view>

#include "utils/core.hpp"
using tests::utils::DoNot;

#include "utils/mutation.hpp"
using tests::utils::TemporaryMutate;

Expand Down Expand Up @@ -34,6 +31,19 @@ namespace {
struct LinearFeedbackControllerTest
: public ::testing::TestWithParam<ControllerParameters> {};

/**
* @return A predicate functor calling the underlying predicate and
* returning it's negation
*
* @param[in] pred A simple predicate taking any arguments and returning a bool
*/
template <typename Pred>
constexpr auto DoNot(Pred&& pred) {
return [&](auto&&... arg) -> bool {
return not pred(std::forward<decltype(arg)>(arg)...);
};
}

constexpr auto Load(LinearFeedbackController& ctrl) {
return [&](const ControllerParameters& params) { return ctrl.load(params); };
}
Expand Down
63 changes: 0 additions & 63 deletions tests/utils/core.hpp

This file was deleted.

0 comments on commit 9392c2a

Please sign in to comment.