g11Tests :: TestTree
g11Tests = decisionTestGroup "g11" "ETag in If-Match?"
  [ testCase "True ==> h10" $
      let r = resource { generateETag = return $ StrongETag "webcrank" }
      in after' (g11 "\"webcrank\"") r req @?= Decision' "h10"
  , testCase "False (no ETag) ==> 412 Precondition Failed" $
      after' (g11 "\"webcrank\"") resource req @?= error' preconditionFailed412
  , testCase "False (mismatch ETag) ==> 412 Precondition Failed" $
      let r = resource { generateETag = return $ StrongETag "webcrank123" }
      in after' (g11 "\"webcrank456\"") r req @?= error' preconditionFailed412
  ]
g11Tests :: TestTree
g11Tests = decisionTestGroup "g11" "ETag in If-Match?"
  [ testCase "True ==> h10" $
      let r = resource { generateETag = return $ StrongETag "webcrank" }
      in after' (g11 "\"webcrank\"") r req @?= Decision' "h10"
  , testCase "False (no ETag) ==> 412 Precondition Failed" $
      after' (g11 "\"webcrank\"") resource req @?= error' preconditionFailed412
  , testCase "False (mismatch ETag) ==> 412 Precondition Failed" $
      let r = resource { generateETag = return $ StrongETag "webcrank123" }
      in after' (g11 "\"webcrank456\"") r req @?= error' preconditionFailed412
  ]
g11Tests = decisionTestGroup "g11" "ETag in If-Match?"
  [ testCase "True ==> h10" $
      let r = resource { generateETag = return $ StrongETag "webcrank" }
      in after' (g11 "\"webcrank\"") r req @?= Decision' "h10"
  , testCase "False (no ETag) ==> 412 Precondition Failed" $
      after' (g11 "\"webcrank\"") resource req @?= error' preconditionFailed412
  , testCase "False (mismatch ETag) ==> 412 Precondition Failed" $
      let r = resource { generateETag = return $ StrongETag "webcrank123" }
      in after' (g11 "\"webcrank456\"") r req @?= error' preconditionFailed412
  ]