Commit 3688279b authored by Hugo Beauzée-Luyssen's avatar Hugo Beauzée-Luyssen
Browse files

mocks: Filesystem: Update noop device to work with MediaLibrary::media(std::string)

We need a basic device and mountpoint to fetch a media through its path
parent 1bdd219b
......@@ -255,9 +255,14 @@ public:
class NoopDevice : public fs::IDevice
m_uuid = "{noop-device}";
virtual const std::string& uuid() const override
return m_uuid;
virtual bool isRemovable() const override
......@@ -272,8 +277,12 @@ public:
virtual const std::string& mountpoint() const override
return m_mountpoint;
std::string m_uuid;
std::string m_mountpoint;
// We just need a valid instance of this one
......@@ -315,7 +324,7 @@ public:
virtual std::shared_ptr<fs::IDevice> createDeviceFromPath( const std::string& ) override
return nullptr;
return std::make_shared<NoopDevice>();
virtual bool refreshDevices() override
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment