Skip to content

Commit

Permalink
clang-tidy
Browse files Browse the repository at this point in the history
  • Loading branch information
maksimdrachov committed Dec 4, 2024
1 parent 29ffc4c commit 6bcb164
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion include/olga_scheduler/olga_scheduler.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ class Event : private cavl::Node<Event<TimePoint>>
virtual void execute(const Arg<TimePoint>& args, Tree& tree) = 0;

private:
TimePoint deadline_=TimePoint::min();
TimePoint deadline_ = TimePoint::min();
};

/// This information is returned by the spin() method to allow the caller to decide what to do next
Expand Down
10 changes: 5 additions & 5 deletions tests/test_olga_scheduler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -198,11 +198,11 @@ TEST(TestOlgaScheduler, EventLoopBasic)
EXPECT_THAT(SteadyClockMock::now().time_since_epoch(), 13'050ms);
EXPECT_TRUE(evt_b.getDeadline() > Loop::time_point::min());
evt_b.cancel();
EXPECT_THAT(evt_b.getDeadline(), Loop::time_point::min()); // Unregistered, cleared.
EXPECT_THAT(evl.getTree().size(), 1); // Freed already.
evt_b.cancel(); // Idempotency.
EXPECT_THAT(evt_b.getDeadline(), Loop::time_point::min()); // Ditto.
EXPECT_THAT(evl.getTree().size(), 1); // Ditto.
EXPECT_THAT(evt_b.getDeadline(), Loop::time_point::min()); // Unregistered, cleared.
EXPECT_THAT(evl.getTree().size(), 1); // Freed already.
evt_b.cancel(); // Idempotency.
EXPECT_THAT(evt_b.getDeadline(), Loop::time_point::min()); // Ditto.
EXPECT_THAT(evl.getTree().size(), 1); // Ditto.
out = evl.spin();
EXPECT_THAT(out.next_deadline.time_since_epoch(), 14'000ms); // B removed so the next one is A.
EXPECT_THAT(out.worst_lateness, 50ms);
Expand Down

0 comments on commit 6bcb164

Please sign in to comment.