MCPcopy Create free account
hub / github.com/ObEngine/ObEngine / match

Method match

extlibs/catch/include/catch/catch.hpp:3585–3592  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3583 ApproxMatcher(std::vector<T> const& comparator) : m_comparator( comparator ) {}
3584
3585 bool match(std::vector<T> const &v) const override {
3586 if (m_comparator.size() != v.size())
3587 return false;
3588 for (std::size_t i = 0; i < v.size(); ++i)
3589 if (m_comparator[i] != approx(v[i]))
3590 return false;
3591 return true;
3592 }
3593 std::string describe() const override {
3594 return "is approx: " + ::Catch::Detail::stringify( m_comparator );
3595 }

Callers

nothing calls this directly

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected