[shill] FindService should return a ServiceRefPtr, and should always return something
We weren't explicitly returning a value from FindService on failure,
which was causing a unit test to pass erroneously. Once I fixed it,
the test started failing because of a dumb thing I was doing in
MockService. So, fix that so that the tests can pass as they should.
BUG=None
TEST=unit tests
Change-Id: Ice304e514ea0e3add779ac061b0945b5712dea29
Reviewed-on: http://gerrit.chromium.org/gerrit/2374
Tested-by: Chris Masone <cmasone@chromium.org>
Reviewed-by: Paul Stewart <pstew@chromium.org>
diff --git a/manager.h b/manager.h
index 8b6ac60..2ad0d72 100644
--- a/manager.h
+++ b/manager.h
@@ -40,7 +40,7 @@
void FilterByTechnology(Device::Technology tech,
std::vector<DeviceRefPtr> *found);
- Service* FindService(const std::string& name);
+ ServiceRefPtr FindService(const std::string& name);
private:
scoped_ptr<ManagerAdaptorInterface> adaptor_;