summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorSpencer Janssen <sjanssen@cse.unl.edu>2007-05-08 23:19:07 +0200
committerSpencer Janssen <sjanssen@cse.unl.edu>2007-05-08 23:19:07 +0200
commitd56eba2fb972e108648f722d2f46c8d690b7b0d9 (patch)
tree04397897fe2cc99e77d6e8b84d872d8909aa0014 /tests
parent77118e41f29cdbf90c10d390af77a6bc8b5c23d6 (diff)
downloadmetatile-d56eba2fb972e108648f722d2f46c8d690b7b0d9.tar
metatile-d56eba2fb972e108648f722d2f46c8d690b7b0d9.zip
Remove broken prop_promoterotate, replace it with prop_promote_raise_id
darcs-hash:20070508211907-a5988-25a6a03356b3017540a53f73bc609a98938c9a9e
Diffstat (limited to 'tests')
-rw-r--r--tests/Properties.hs11
1 files changed, 7 insertions, 4 deletions
diff --git a/tests/Properties.hs b/tests/Properties.hs
index 0766401..d3f0e3a 100644
--- a/tests/Properties.hs
+++ b/tests/Properties.hs
@@ -244,9 +244,12 @@ prop_promotescreen n x = screen n (promote x) == screen n x
where _ = x :: T
-- promote doesn't mess with other windows
-prop_promoterotate x b = focus (rotate dir (promote x)) == focus (rotate dir x)
- where _ = x :: T
- dir = if b then LT else GT
+prop_promote_raise_id x b = (not . null . fromMaybe [] . flip index x . current $ x) ==>
+ (raiseFocus y . promote . raiseFocus z . promote) x == x
+ where _ = x :: T
+ dir = if b then LT else GT
+ (Just y) = peek x
+ (Just (z:_)) = flip index x . current $ x
-- push shouldn't change anything but the current workspace
prop_push_local (x :: T) i = not (member i x) ==> hidden x == hidden (push i x)
@@ -390,7 +393,7 @@ main = do
,("promote idempotent", mytest prop_promote2)
,("promote focus", mytest prop_promotefocus)
,("promote current", mytest prop_promotecurrent)
- ,("promote only swaps", mytest prop_promoterotate)
+ ,("promote only swaps", mytest prop_promote_raise_id)
,("promote/screen" , mytest prop_promotescreen)
,("swap", mytest prop_swap)