aboutsummaryrefslogtreecommitdiff
path: root/nix-rust/src/error.rs
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2019-12-05 23:10:16 +0100
committerEelco Dolstra <edolstra@gmail.com>2019-12-10 22:04:40 +0100
commitebd89999c28e25e71048d523f9c4f8b856dee9a9 (patch)
treeb32c1a4d556119eeebed97fd982bfde64a539d21 /nix-rust/src/error.rs
parentbca0afb943da714c93b4c8621c0ed727ae86d0e2 (diff)
Add StorePath tests
Diffstat (limited to 'nix-rust/src/error.rs')
-rw-r--r--nix-rust/src/error.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/nix-rust/src/error.rs b/nix-rust/src/error.rs
index 1066a266e..28b5c43af 100644
--- a/nix-rust/src/error.rs
+++ b/nix-rust/src/error.rs
@@ -6,6 +6,7 @@ pub enum Error {
BadStorePath(std::path::PathBuf),
BadNarInfo,
BadBase32,
+ StorePathNameEmpty,
StorePathNameTooLong,
BadStorePathName,
NarSizeFieldTooBig,
@@ -42,6 +43,7 @@ impl fmt::Display for Error {
Error::BadNarInfo => write!(f, ".narinfo file is corrupt"),
Error::BadStorePath(path) => write!(f, "path '{}' is not a store path", path.display()),
Error::BadBase32 => write!(f, "invalid base32 string"),
+ Error::StorePathNameEmpty => write!(f, "store path name is empty"),
Error::StorePathNameTooLong => {
write!(f, "store path name is longer than 211 characters")
}