Compare commits

...

7 Commits

Author SHA1 Message Date
Martchus ea0503ce62 Avoid warning about invoking function marked as nodiscard 2024-05-21 20:37:36 +02:00
Martchus 8efa6461fe Bump patch version 2024-05-21 20:37:36 +02:00
Martchus e3e7f731bf Apply change of `global.h` template 2024-04-02 11:12:34 +02:00
Martchus acdc1d80ba Allow compilation of tests when doing unity builds
Ensure all formatting overloads are always included before CppUnit's
headers
2024-02-04 20:58:45 +01:00
Martchus 3cb0812c62 Bump patch version 2024-02-04 20:42:27 +01:00
Martchus 17f6d4cfe5 Update `global.h` via updated template in c++utilities 2024-02-04 20:41:25 +01:00
Martchus fd5c19dd9f Update copyright date 2024-02-04 20:38:44 +01:00
8 changed files with 10 additions and 11 deletions

View File

@ -10,7 +10,7 @@ set(META_APP_URL "https://github.com/${META_APP_AUTHOR}/${META_PROJECT_NAME}")
set(META_APP_DESCRIPTION "C++ library to read/write passwords from/to encrypted files") set(META_APP_DESCRIPTION "C++ library to read/write passwords from/to encrypted files")
set(META_VERSION_MAJOR 5) set(META_VERSION_MAJOR 5)
set(META_VERSION_MINOR 0) set(META_VERSION_MINOR 0)
set(META_VERSION_PATCH 10) set(META_VERSION_PATCH 12)
set(META_ADD_DEFAULT_CPP_UNIT_TEST_APPLICATION ON) set(META_ADD_DEFAULT_CPP_UNIT_TEST_APPLICATION ON)
# add project files # add project files

View File

@ -9,6 +9,6 @@ The passwordfile library depends on c++utilities and is built in the same way.
It also depends on OpenSSL and zlib. It also depends on OpenSSL and zlib.
## Copyright notice and license ## Copyright notice and license
Copyright © 2015-2023 Marius Kittler Copyright © 2015-2024 Marius Kittler
All code is licensed under [GPL-2-or-later](LICENSE). All code is licensed under [GPL-2-or-later](LICENSE).

View File

@ -4,6 +4,7 @@
#ifndef PASSWORD_FILE_GLOBAL #ifndef PASSWORD_FILE_GLOBAL
#define PASSWORD_FILE_GLOBAL #define PASSWORD_FILE_GLOBAL
#include "passwordfile-definitions.h"
#include <c++utilities/application/global.h> #include <c++utilities/application/global.h>
#ifdef PASSWORD_FILE_STATIC #ifdef PASSWORD_FILE_STATIC

View File

@ -2,9 +2,6 @@
#include "./utils.h" #include "./utils.h"
#include <c++utilities/tests/testutils.h>
using namespace CppUtilities;
#include <cppunit/TestFixture.h> #include <cppunit/TestFixture.h>
#include <cppunit/extensions/HelperMacros.h> #include <cppunit/extensions/HelperMacros.h>

View File

@ -3,9 +3,6 @@
#include "./utils.h" #include "./utils.h"
#include <c++utilities/tests/testutils.h>
using namespace CppUtilities;
#include <cppunit/TestFixture.h> #include <cppunit/TestFixture.h>
#include <cppunit/extensions/HelperMacros.h> #include <cppunit/extensions/HelperMacros.h>

View File

@ -1,6 +1,6 @@
#include "../util/opensslrandomdevice.h" #include "../util/opensslrandomdevice.h"
#include <c++utilities/tests/testutils.h> #include "./utils.h"
#include <cppunit/TestFixture.h> #include <cppunit/TestFixture.h>
#include <cppunit/extensions/HelperMacros.h> #include <cppunit/extensions/HelperMacros.h>

View File

@ -2,7 +2,7 @@
#include "../io/entry.h" #include "../io/entry.h"
#include "../io/passwordfile.h" #include "../io/passwordfile.h"
#include <c++utilities/tests/testutils.h> #include "./utils.h"
#include <cppunit/TestFixture.h> #include <cppunit/TestFixture.h>
#include <cppunit/extensions/HelperMacros.h> #include <cppunit/extensions/HelperMacros.h>
@ -84,7 +84,7 @@ void PasswordFileTests::testReading(const string &context, const string &testfil
CPPUNIT_ASSERT( CPPUNIT_ASSERT(
static_cast<AccountEntry *>(rootEntry->children()[0])->fields().at(0).tiedAccount() == static_cast<AccountEntry *>(rootEntry->children()[0])); static_cast<AccountEntry *>(rootEntry->children()[0])->fields().at(0).tiedAccount() == static_cast<AccountEntry *>(rootEntry->children()[0]));
CPPUNIT_ASSERT_EQUAL_MESSAGE(context, FieldType::Normal, static_cast<AccountEntry *>(rootEntry->children()[0])->fields().at(1).type()); CPPUNIT_ASSERT_EQUAL_MESSAGE(context, FieldType::Normal, static_cast<AccountEntry *>(rootEntry->children()[0])->fields().at(1).type());
CPPUNIT_ASSERT_THROW_MESSAGE(context, static_cast<AccountEntry *>(rootEntry->children()[0])->fields().at(2), out_of_range); CPPUNIT_ASSERT_EQUAL_MESSAGE(context, 2_st, static_cast<AccountEntry *>(rootEntry->children()[0])->fields().size());
// test testaccount2 // test testaccount2
CPPUNIT_ASSERT_EQUAL_MESSAGE(context, "testaccount2"s, rootEntry->children()[1]->label()); CPPUNIT_ASSERT_EQUAL_MESSAGE(context, "testaccount2"s, rootEntry->children()[1]->label());

View File

@ -23,4 +23,8 @@ inline std::ostream &operator<<(std::ostream &out, const Io::Field *field)
} // namespace CppUtilities } // namespace CppUtilities
#include <c++utilities/tests/testutils.h>
using namespace CppUtilities;
#endif // PASSWORDFILE_TESTS_UTILS_H #endif // PASSWORDFILE_TESTS_UTILS_H