propellor spin
This commit is contained in:
parent
022e70d822
commit
595794a250
|
@ -79,14 +79,17 @@ upgrade = runApt ["-y", "dist-upgrade"]
|
||||||
type Package = String
|
type Package = String
|
||||||
|
|
||||||
installed :: [Package] -> Property
|
installed :: [Package] -> Property
|
||||||
installed ps = robustly $ check (isInstallable ps) go
|
installed = installed' ["-y"]
|
||||||
|
|
||||||
|
installed' :: [String] -> [Package] -> Property
|
||||||
|
installed' params ps = robustly $ check (isInstallable ps) go
|
||||||
`describe` (unwords $ "apt installed":ps)
|
`describe` (unwords $ "apt installed":ps)
|
||||||
where
|
where
|
||||||
go = runApt $ ["-y", "install"] ++ ps
|
go = runApt $ params ++ ["install"] ++ ps
|
||||||
|
|
||||||
-- | Minimal install of package, without recommends.
|
-- | Minimal install of package, without recommends.
|
||||||
installedMin :: [Package] -> Property
|
installedMin :: [Package] -> Property
|
||||||
installedMin ps = installed ("--no-install-recommends" : ps)
|
installedMin = installed' ["--no-install-recommends"]
|
||||||
|
|
||||||
removed :: [Package] -> Property
|
removed :: [Package] -> Property
|
||||||
removed ps = check (or <$> isInstalled' ps) go
|
removed ps = check (or <$> isInstalled' ps) go
|
||||||
|
|
Loading…
Reference in New Issue