diff options
author | Don Stewart <dons@galois.com> | 2008-03-23 01:34:36 +0100 |
---|---|---|
committer | Don Stewart <dons@galois.com> | 2008-03-23 01:34:36 +0100 |
commit | 462f2e26f9f1dde08c82f15c51d8e948ef9ea688 (patch) | |
tree | ceb8250dddcc879cee4745ca2f2654dc2873768c /tests | |
parent | c549c20a84193b9ea7df7a7b9310cbdf4c3e8791 (diff) | |
download | xmonad-462f2e26f9f1dde08c82f15c51d8e948ef9ea688.tar.gz xmonad-462f2e26f9f1dde08c82f15c51d8e948ef9ea688.tar.xz xmonad-462f2e26f9f1dde08c82f15c51d8e948ef9ea688.zip |
more tests
darcs-hash:20080323003436-cba2c-f896cff759d6413571b6c32f2a78f64e6399feea.gz
Diffstat (limited to 'tests')
-rw-r--r-- | tests/Properties.hs | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/tests/Properties.hs b/tests/Properties.hs index 3f78b03..010a05e 100644 --- a/tests/Properties.hs +++ b/tests/Properties.hs @@ -4,7 +4,7 @@ module Properties where import XMonad.StackSet hiding (filter) import XMonad.Layout import XMonad.Core hiding (workspaces,trace) -import XMonad.Operations ( applyResizeIncHint ) +import XMonad.Operations ( applyResizeIncHint, applyMaxSizeHint ) import qualified XMonad.StackSet as S (filter) import Debug.Trace @@ -823,6 +823,16 @@ prop_resize_inc_extra ((NonNegative inc_w)) b@(w,h) = where (w',h') = applyResizeIncHint a b a = (-inc_w,0::Dimension)-- inc_h) +prop_resize_max (NonZero (NonNegative inc_w),NonZero (NonNegative inc_h)) b@(w,h) = + w' <= inc_w && h' <= inc_h + where (w',h') = applyMaxSizeHint a b + a = (inc_w,inc_h) + +prop_resize_max_extra ((NonNegative inc_w)) b@(w,h) = + (w,h) == (w',h') + where (w',h') = applyMaxSizeHint a b + a = (-inc_w,0::Dimension)-- inc_h) + ------------------------------------------------------------------------ main :: IO () @@ -971,6 +981,8 @@ main = do -- resize hints ,("window hints: inc", mytest prop_resize_inc) ,("window hints: inc all", mytest prop_resize_inc_extra) + ,("window hints: max", mytest prop_resize_max) + ,("window hints: max all ", mytest prop_resize_max_extra) ] |