lib: hide some code from coverage checking
Parts that are not easy / useful to unit-test
This commit is contained in:
@ -109,6 +109,7 @@ QueryMatch::has_flag(QueryMatch::Flags flag) const
|
|||||||
return any_of(flags & flag);
|
return any_of(flags & flag);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* LCOV_EXCL_START */
|
||||||
static inline std::ostream&
|
static inline std::ostream&
|
||||||
operator<<(std::ostream& os, QueryMatch::Flags mflags)
|
operator<<(std::ostream& os, QueryMatch::Flags mflags)
|
||||||
{
|
{
|
||||||
@ -140,8 +141,6 @@ operator<<(std::ostream& os, QueryMatch::Flags mflags)
|
|||||||
return os;
|
return os;
|
||||||
}
|
}
|
||||||
|
|
||||||
using QueryMatches = std::unordered_map<Xapian::docid, QueryMatch>;
|
|
||||||
|
|
||||||
inline std::ostream&
|
inline std::ostream&
|
||||||
operator<<(std::ostream& os, const QueryMatch& qmatch)
|
operator<<(std::ostream& os, const QueryMatch& qmatch)
|
||||||
{
|
{
|
||||||
@ -151,6 +150,10 @@ operator<<(std::ostream& os, const QueryMatch& qmatch)
|
|||||||
|
|
||||||
return os;
|
return os;
|
||||||
}
|
}
|
||||||
|
/* LCOV_EXCL_STOP*/
|
||||||
|
|
||||||
|
using QueryMatches = std::unordered_map<Xapian::docid, QueryMatch>;
|
||||||
|
|
||||||
|
|
||||||
///
|
///
|
||||||
/// This is a view over the Xapian::MSet, which can optionally filter unreadable
|
/// This is a view over the Xapian::MSet, which can optionally filter unreadable
|
||||||
|
|||||||
@ -107,6 +107,7 @@ struct Container {
|
|||||||
using Containers = Container::Containers;
|
using Containers = Container::Containers;
|
||||||
using ContainerVec = Container::ContainerVec;
|
using ContainerVec = Container::ContainerVec;
|
||||||
|
|
||||||
|
/* LCOV_EXCL_START */
|
||||||
static std::ostream&
|
static std::ostream&
|
||||||
operator<<(std::ostream& os, const Container& container)
|
operator<<(std::ostream& os, const Container& container)
|
||||||
{
|
{
|
||||||
@ -125,6 +126,7 @@ operator<<(std::ostream& os, const Container& container)
|
|||||||
|
|
||||||
return os;
|
return os;
|
||||||
}
|
}
|
||||||
|
/* LCOV_EXCL_STOP */
|
||||||
|
|
||||||
using IdTable = std::unordered_map<std::string, Container>;
|
using IdTable = std::unordered_map<std::string, Container>;
|
||||||
using DupTable = std::multimap<std::string, Container>;
|
using DupTable = std::multimap<std::string, Container>;
|
||||||
@ -534,6 +536,7 @@ sort_siblings(IdTable& id_table, bool descending)
|
|||||||
update_containers(root_vec, descending, id_table.size());
|
update_containers(root_vec, descending, id_table.size());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* LCOV_EXCL_START */
|
||||||
static std::ostream&
|
static std::ostream&
|
||||||
operator<<(std::ostream& os, const IdTable& id_table)
|
operator<<(std::ostream& os, const IdTable& id_table)
|
||||||
{
|
{
|
||||||
@ -559,6 +562,7 @@ operator<<(std::ostream& os, const IdTable& id_table)
|
|||||||
}
|
}
|
||||||
return os;
|
return os;
|
||||||
}
|
}
|
||||||
|
/* LCOV_EXCL_STOP */
|
||||||
|
|
||||||
template <typename Results>
|
template <typename Results>
|
||||||
static void
|
static void
|
||||||
|
|||||||
@ -50,6 +50,8 @@
|
|||||||
|
|
||||||
using namespace Mu;
|
using namespace Mu;
|
||||||
|
|
||||||
|
/* LCOV_EXCL_START */
|
||||||
|
|
||||||
/// output stream to _either_ a file or to a stringstream
|
/// output stream to _either_ a file or to a stringstream
|
||||||
struct OutputStream {
|
struct OutputStream {
|
||||||
/**
|
/**
|
||||||
@ -1160,3 +1162,5 @@ Server::invoke(const std::string& expr) noexcept
|
|||||||
{
|
{
|
||||||
return priv_->invoke(expr);
|
return priv_->invoke(expr);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* LCOV_EXCL_STOP */
|
||||||
|
|||||||
@ -27,6 +27,8 @@
|
|||||||
#include <utils/mu-utils.hh>
|
#include <utils/mu-utils.hh>
|
||||||
#include <mu-store.hh>
|
#include <mu-store.hh>
|
||||||
|
|
||||||
|
/* LCOV_EXCL_START */
|
||||||
|
|
||||||
namespace Mu {
|
namespace Mu {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -82,5 +84,6 @@ MU_ENABLE_BITOPS(Server::OutputFlags);
|
|||||||
|
|
||||||
} // namespace Mu
|
} // namespace Mu
|
||||||
|
|
||||||
|
/* LCOV_EXCL_STOP */
|
||||||
|
|
||||||
#endif /* MU_SERVER_HH__ */
|
#endif /* MU_SERVER_HH__ */
|
||||||
|
|||||||
Reference in New Issue
Block a user