mirror of
https://github.com/jmwtsn/qmk_firmware.git
synced 2026-06-03 19:53:31 -03:00
[CI] Format code according to conventions (#26138)
Format code according to conventions
This commit is contained in:
@@ -5,6 +5,7 @@ class RingBuffer {
|
||||
protected:
|
||||
T buf_[Size];
|
||||
uint8_t head_{0}, tail_{0};
|
||||
|
||||
public:
|
||||
inline uint8_t nextPosition(uint8_t position) {
|
||||
return (position + 1) % Size;
|
||||
@@ -46,7 +47,9 @@ class RingBuffer {
|
||||
return true;
|
||||
}
|
||||
|
||||
inline bool empty() const { return head_ == tail_; }
|
||||
inline bool empty() const {
|
||||
return head_ == tail_;
|
||||
}
|
||||
|
||||
inline uint8_t size() const {
|
||||
int diff = head_ - tail_;
|
||||
@@ -56,7 +59,7 @@ class RingBuffer {
|
||||
return Size + diff;
|
||||
}
|
||||
|
||||
inline T& front() {
|
||||
inline T &front() {
|
||||
return buf_[tail_];
|
||||
}
|
||||
|
||||
|
||||
@@ -28,12 +28,12 @@ class KeyboardReportMatcher : public testing::MatcherInterface<report_keyboard_t
|
||||
virtual bool MatchAndExplain(report_keyboard_t& report, testing::MatchResultListener* listener) const override;
|
||||
virtual void DescribeTo(::std::ostream* os) const override;
|
||||
virtual void DescribeNegationTo(::std::ostream* os) const override;
|
||||
private:
|
||||
|
||||
private:
|
||||
report_keyboard_t m_report;
|
||||
};
|
||||
|
||||
|
||||
template<typename... Ts>
|
||||
template <typename... Ts>
|
||||
inline testing::Matcher<report_keyboard_t&> KeyboardReport(Ts... keys) {
|
||||
return testing::MakeMatcher(new KeyboardReportMatcher(std::vector<uint8_t>({keys...})));
|
||||
}
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
|
||||
class TestLogger : public std::ostream {
|
||||
public:
|
||||
TestLogger() : std::ostream(&m_log){};
|
||||
TestLogger() : std::ostream(&m_log) {};
|
||||
TestLogger& info();
|
||||
TestLogger& trace();
|
||||
TestLogger& error();
|
||||
|
||||
Reference in New Issue
Block a user