From 95b49f41dd171340f15139ccd5898bd0eda7a246 Mon Sep 17 00:00:00 2001 From: Julian Ospald Date: Mon, 2 May 2016 19:18:15 +0200 Subject: [PATCH] TESTS: run all tests twice to detect state skew --- test/Spec.hs | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/test/Spec.hs b/test/Spec.hs index b520c42..e1c9cbb 100644 --- a/test/Spec.hs +++ b/test/Spec.hs @@ -36,13 +36,19 @@ import System.Process main :: IO () main = hspec $ do - copyFileSpec - copyDirRecursiveSpec - createDirSpec - createRegularFileSpec - renameFileSpec - moveFileSpec - recreateSymlinkSpec + let tests = [copyFileSpec + , copyDirRecursiveSpec + , createDirSpec + , createRegularFileSpec + , renameFileSpec + , moveFileSpec + ,recreateSymlinkSpec + ] + + -- run all tests twice to catch missing cleanups or state skew + sequence_ tests + sequence_ tests + -- TODO: deleteFile, deleteDir, deleteDirRecursive, getDirsFiles, getFileType