Check in a clang-tidy
This should've been done when we first created the repo, but better late
than never.
Signed-off-by: Ed Tanous <edtanous@google.com>
Signed-off-by: John Edward Broadbent <jebr@google.com>
Change-Id: I68da1d13167ec94f9d008dea307c9f23a991d42c
diff --git a/include/filesystemInterface.hpp b/include/filesystemInterface.hpp
index 0f276a7..12495cd 100644
--- a/include/filesystemInterface.hpp
+++ b/include/filesystemInterface.hpp
@@ -17,6 +17,13 @@
public:
virtual ~FilesystemInterface() = default;
+ FilesystemInterface() = default;
+ FilesystemInterface(const FilesystemInterface&) = delete;
+ FilesystemInterface& operator=(const FilesystemInterface&) = delete;
+
+ FilesystemInterface(FilesystemInterface&&) = delete;
+ FilesystemInterface& operator=(FilesystemInterface&&) = delete;
+
/** @brief Runs the mkfs command to create the filesystem.
* @details Used for mocking purposes.
*
@@ -86,11 +93,18 @@
class Filesystem : public FilesystemInterface
{
public:
- ~Filesystem() = default;
+ ~Filesystem() override = default;
+ Filesystem() = default;
+ Filesystem(const Filesystem&) = delete;
+ Filesystem& operator=(const Filesystem&) = delete;
+
+ Filesystem(Filesystem&&) = delete;
+ Filesystem& operator=(Filesystem&&) = delete;
int runMkfs(const std::string& logicalVolume) override
{
std::string mkfsCommand("mkfs.ext4 /dev/mapper/" + logicalVolume);
+ // calling 'system' uses a command processor //NOLINTNEXTLINE
return system(mkfsCommand.c_str());
}