WIP
This commit is contained in:
parent
ea55d3e6fd
commit
a745b47cf1
|
|
@ -0,0 +1,37 @@
|
|||
---
|
||||
AlignAfterOpenBracket: Align
|
||||
AllowAllArgumentsOnNextLine: 'false'
|
||||
AllowAllConstructorInitializersOnNextLine: 'false'
|
||||
AllowAllParametersOfDeclarationOnNextLine: 'false'
|
||||
AllowShortBlocksOnASingleLine: 'false'
|
||||
AllowShortCaseLabelsOnASingleLine: 'false'
|
||||
AllowShortFunctionsOnASingleLine: InlineOnly
|
||||
AllowShortIfStatementsOnASingleLine: Never
|
||||
AllowShortLambdasOnASingleLine: None
|
||||
AllowShortLoopsOnASingleLine: 'false'
|
||||
AlwaysBreakTemplateDeclarations: 'Yes'
|
||||
BinPackArguments: 'false'
|
||||
BinPackParameters: 'false'
|
||||
BreakBeforeBraces: Allman
|
||||
BreakConstructorInitializers: BeforeComma
|
||||
ColumnLimit: '120'
|
||||
Cpp11BracedListStyle: 'true'
|
||||
FixNamespaceComments: 'true'
|
||||
IncludeBlocks: Merge
|
||||
IndentCaseLabels: 'true'
|
||||
IndentWidth: '4'
|
||||
Language: Cpp
|
||||
MaxEmptyLinesToKeep: '2'
|
||||
NamespaceIndentation: Inner
|
||||
PointerAlignment: Left
|
||||
SortUsingDeclarations: 'true'
|
||||
SpaceAfterTemplateKeyword: 'false'
|
||||
SpacesInAngles: 'false'
|
||||
SpacesInCStyleCastParentheses: 'false'
|
||||
SpacesInContainerLiterals: 'false'
|
||||
SpacesInSquareBrackets: 'false'
|
||||
Standard: Cpp11
|
||||
TabWidth: '4'
|
||||
UseTab: Never
|
||||
|
||||
...
|
||||
|
|
@ -11,4 +11,4 @@ namespace awesome_log
|
|||
~console_writer() override;
|
||||
void log(std::string_view msg) override;
|
||||
};
|
||||
}
|
||||
} // namespace awesome_log
|
||||
|
|
|
|||
|
|
@ -9,4 +9,4 @@ namespace awesome_log
|
|||
|
||||
writer_interface& get_writer();
|
||||
void set_writer(const std::shared_ptr<writer_interface>& writer);
|
||||
}
|
||||
} // namespace awesome_log
|
||||
|
|
@ -11,4 +11,4 @@ namespace awesome_log
|
|||
~null_writer() override;
|
||||
void log(std::string_view msg) override;
|
||||
};
|
||||
}
|
||||
} // namespace awesome_log
|
||||
|
|
|
|||
|
|
@ -24,4 +24,4 @@ namespace awesome_log
|
|||
std::string m_msg;
|
||||
int m_uncaught_exceptions;
|
||||
};
|
||||
}
|
||||
} // namespace awesome_log
|
||||
|
|
@ -12,4 +12,4 @@ namespace awesome_log
|
|||
|
||||
virtual void log(std::string_view msg) = 0;
|
||||
};
|
||||
}
|
||||
} // namespace awesome_log
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
#include <awesome_log/scoped_log.hpp>
|
||||
#include <awesome_log/log.hpp>
|
||||
#include <awesome_log/scoped_log.hpp>
|
||||
#include <awesome_log/writer_interface.hpp>
|
||||
#include <sstream>
|
||||
#include <exception>
|
||||
#include <sstream>
|
||||
|
||||
using namespace awesome_log;
|
||||
|
||||
|
|
|
|||
|
|
@ -1,10 +1,8 @@
|
|||
#include <gmock/gmock.h>
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
#include "mock_writer.hpp"
|
||||
#include <awesome_log/log.hpp>
|
||||
#include <awesome_log/scoped_log.hpp>
|
||||
|
||||
#include <gmock/gmock.h>
|
||||
#include <gtest/gtest.h>
|
||||
#include <memory>
|
||||
|
||||
class test_scoped_log : public ::testing::Test
|
||||
|
|
@ -16,10 +14,7 @@ public:
|
|||
awesome_log::set_writer(m_writer);
|
||||
}
|
||||
|
||||
void TearDown() override
|
||||
{
|
||||
awesome_log::set_writer(std::shared_ptr<awesome_log::writer_interface>());
|
||||
}
|
||||
void TearDown() override { awesome_log::set_writer(std::shared_ptr<awesome_log::writer_interface>()); }
|
||||
|
||||
protected:
|
||||
std::shared_ptr<mock_writer> m_writer;
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
#include <sstream>
|
||||
#include <iostream>
|
||||
#include <boost/archive/text_oarchive.hpp>
|
||||
#include <boost/archive/text_iarchive.hpp>
|
||||
#include <boost/archive/text_oarchive.hpp>
|
||||
#include <iostream>
|
||||
#include <sstream>
|
||||
|
||||
struct position
|
||||
{
|
||||
|
|
@ -15,11 +15,7 @@ struct position
|
|||
ar & y;
|
||||
}
|
||||
|
||||
bool operator==(const position& rhs) const
|
||||
{
|
||||
return x == rhs.x
|
||||
&& y == rhs.y;
|
||||
}
|
||||
bool operator==(const position& rhs) const { return x == rhs.x && y == rhs.y; }
|
||||
};
|
||||
|
||||
|
||||
|
|
@ -44,5 +40,4 @@ int main(int argc, char* argv[])
|
|||
{
|
||||
std::cout << "positions are the same" << std::endl;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -1,7 +1,6 @@
|
|||
#include <awesome_log/console_writer.hpp>
|
||||
#include <awesome_log/log.hpp>
|
||||
#include <awesome_log/scoped_log.hpp>
|
||||
#include <awesome_log/console_writer.hpp>
|
||||
|
||||
#include <iostream>
|
||||
#include <memory>
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue