mirror of
https://github.com/catchorg/Catch2.git
synced 2024-11-22 13:26:10 +01:00
Fix for JUnit reporter when using dynamically generated sections (#963)
* BySectionInfo should also take into account the section name in addition to the source code line
This commit is contained in:
parent
cde987a92e
commit
4f72202c04
@ -125,10 +125,11 @@ namespace Catch {
|
||||
};
|
||||
|
||||
struct BySectionInfo {
|
||||
BySectionInfo(SectionInfo const& other) : m_other(other) {}
|
||||
BySectionInfo(BySectionInfo const& other) : m_other(other.m_other) {}
|
||||
BySectionInfo( SectionInfo const& other ) : m_other( other ) {}
|
||||
BySectionInfo( BySectionInfo const& other ) : m_other( other.m_other ) {}
|
||||
bool operator() (std::shared_ptr<SectionNode> const& node) const {
|
||||
return node->stats.sectionInfo.lineInfo == m_other.lineInfo;
|
||||
return ((node->stats.sectionInfo.name == m_other.name) &&
|
||||
(node->stats.sectionInfo.lineInfo == m_other.lineInfo));
|
||||
}
|
||||
void operator=(BySectionInfo const&) = delete;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user