mirror of
https://github.com/NixOS/nix.git
synced 2025-12-25 02:10:54 +01:00
Factor out UnkeyedValidPathInfo and test
This makes the path info serialisers ideomatic again, which allows me to test them.
This commit is contained in:
parent
596bd469cc
commit
70f8b96c11
10 changed files with 218 additions and 34 deletions
|
|
@ -332,7 +332,8 @@ void RemoteStore::queryPathInfoUncached(const StorePath & path,
|
|||
if (!valid) throw InvalidPath("path '%s' is not valid", printStorePath(path));
|
||||
}
|
||||
info = std::make_shared<ValidPathInfo>(
|
||||
WorkerProto::Serialise<ValidPathInfo>::read(*this, *conn, StorePath{path}));
|
||||
StorePath{path},
|
||||
WorkerProto::Serialise<UnkeyedValidPathInfo>::read(*this, *conn));
|
||||
}
|
||||
callback(std::move(info));
|
||||
} catch (...) { callback.rethrow(); }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue