From 7ce261e22cdfe09bb2b4daa7f6d1b42ed07d4f5f Mon Sep 17 00:00:00 2001 From: Jim Date: Wed, 27 Apr 2016 19:00:18 -0400 Subject: fixes --- testkiki/testkiki.hs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'testkiki/testkiki.hs') diff --git a/testkiki/testkiki.hs b/testkiki/testkiki.hs index 7821df7..ea6ad80 100644 --- a/testkiki/testkiki.hs +++ b/testkiki/testkiki.hs @@ -268,7 +268,6 @@ doTests tkConfig = hspec $ do gnuhome = home ".gnupg" cfg = cfg' { gnupghome = gnuhome } etcFile = chroot cfg "etc" "ssh" "ssh_config" - etcFileBS = B.pack etcFile -- dump stderr here withErrFile (takeDirectory (chroot cfg)) $ \myStdErr -> do -- initialize config file with actual systems @@ -282,14 +281,14 @@ doTests tkConfig = hspec $ do doesFileExist file >>= (bool (return False) $ B.isPrefixOf x . snd . B.breakSubstring x <$> B.readFile file) -- does it already mention /var/cache/kiki/ssh_known_hosts? expect not - subStr0 <- etcFileBS `hasSubStr` "/var/cache/kiki/ssh_known_hosts" + subStr0 <- etcFile `hasSubStr` "/var/cache/kiki/ssh_known_hosts" cokiki cfg ["ssh-client"] myStdErr -- get counts of lines subtracted, and lines added, expect (1,1) (lost,gained) <- linesSubtractedAndAdded etcFile -- did Sha1 change? expect it did bChanged <- compareSha1 etcFile -- does it mention /var/cache/kiki/ssh_known_hosts now? expect it does - subStr <- etcFileBS `hasSubStr` "/var/cache/kiki/ssh_known_hosts" + subStr <- etcFile `hasSubStr` "/var/cache/kiki/ssh_known_hosts" -- new mtime mtime <- getModificationTime etcFile (lost,gained,bChanged,(subStr0,subStr),compare mtime mtime0) `shouldBe` (1,1,True,(False,True),GT) -- cgit v1.2.3