diff options
author | Dan Goodliffe <dan@randomdan.homeip.net> | 2019-03-27 22:22:08 +0000 |
---|---|---|
committer | Dan Goodliffe <dan@randomdan.homeip.net> | 2019-03-27 22:22:08 +0000 |
commit | 232501140c2d6fba164aa6757a816c7da569830a (patch) | |
tree | 413dac0a4cf7f679fdd7dbe57733af7591a66ba1 /icespider/unittests/testFileSessions.cpp | |
parent | Enable some clang-tidy checks and fix up accordingly (diff) | |
download | icespider-232501140c2d6fba164aa6757a816c7da569830a.tar.bz2 icespider-232501140c2d6fba164aa6757a816c7da569830a.tar.xz icespider-232501140c2d6fba164aa6757a816c7da569830a.zip |
Add clang-tidy rules and fix all the things
Note: something in here appears to break linking in release build
Diffstat (limited to 'icespider/unittests/testFileSessions.cpp')
-rw-r--r-- | icespider/unittests/testFileSessions.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/icespider/unittests/testFileSessions.cpp b/icespider/unittests/testFileSessions.cpp index 69e4d01..1ab75f7 100644 --- a/icespider/unittests/testFileSessions.cpp +++ b/icespider/unittests/testFileSessions.cpp @@ -20,6 +20,7 @@ class TestCore : public IceSpider::CoreWithDefaultRouter { root(communicator->getProperties()->getProperty("IceSpider.FileSessions.Path")) { } + // NOLINTNEXTLINE(misc-non-private-member-variables-in-classes) const std::filesystem::path root; }; @@ -46,7 +47,7 @@ BOOST_AUTO_TEST_CASE( createAndDestroy ) auto s = prx->createSession(); BOOST_REQUIRE(std::filesystem::exists(root / s->id)); BOOST_REQUIRE_EQUAL(0, s->duration); - BOOST_REQUIRE_EQUAL(time(NULL), s->lastUsed); + BOOST_REQUIRE_EQUAL(time(nullptr), s->lastUsed); prx->destroySession(s->id); BOOST_REQUIRE(!std::filesystem::exists(root / s->id)); } @@ -71,7 +72,7 @@ BOOST_AUTO_TEST_CASE( createAndExpire ) auto s = prx->createSession(); BOOST_REQUIRE(std::filesystem::exists(root / s->id)); BOOST_REQUIRE_EQUAL(0, s->duration); - BOOST_REQUIRE_EQUAL(time(NULL), s->lastUsed); + BOOST_REQUIRE_EQUAL(time(nullptr), s->lastUsed); usleep(1001000); BOOST_REQUIRE(std::filesystem::exists(root / s->id)); BOOST_REQUIRE(!prx->getSession(s->id)); |