mirror of
https://github.com/ilyakooo0/roboservant.git
synced 2024-09-11 08:05:47 +03:00
Apply suggestions from code review
thanks musedev. Co-authored-by: muse-dev[bot] <37194012+muse-dev[bot]@users.noreply.github.com>
This commit is contained in:
parent
c41cee3296
commit
1728c99798
@ -3,7 +3,6 @@
|
||||
{-# LANGUAGE DataKinds #-}
|
||||
{-# LANGUAGE AllowAmbiguousTypes #-}
|
||||
{-# LANGUAGE DataKinds #-}
|
||||
{-# LANGUAGE NamedFieldPuns#-}
|
||||
{-# LANGUAGE GADTs #-}
|
||||
{-# LANGUAGE PolyKinds #-}
|
||||
{-# LANGUAGE ScopedTypeVariables #-}
|
||||
@ -42,7 +41,10 @@ import Data.Hashable
|
||||
|
||||
fuzz :: forall api . (ToReifiedClientApi (Endpoints api), FlattenClient api, HasClient ClientM api)
|
||||
=> ClientEnv -> Config -> IO (Maybe Report)
|
||||
fuzz clientEnv config = fuzz' (toReifiedClientApi (flattenClient @api apiClient) (Proxy @(Endpoints api)) clientEnv ) config
|
||||
fuzz clientEnv
|
||||
= fuzz'
|
||||
(toReifiedClientApi
|
||||
(flattenClient @api apiClient) (Proxy @(Endpoints api)) clientEnv)
|
||||
where apiClient = client (Proxy @api)
|
||||
|
||||
|
||||
|
@ -4,12 +4,9 @@
|
||||
{-# LANGUAGE AllowAmbiguousTypes #-}
|
||||
{-# LANGUAGE FlexibleContexts #-}
|
||||
{-# LANGUAGE GADTs #-}
|
||||
{-# LANGUAGE LambdaCase #-}
|
||||
{-# LANGUAGE PolyKinds #-}
|
||||
{-# LANGUAGE RankNTypes #-}
|
||||
{-# LANGUAGE RecordWildCards #-}
|
||||
{-# LANGUAGE ScopedTypeVariables #-}
|
||||
{-# LANGUAGE TupleSections #-}
|
||||
{-# LANGUAGE TypeApplications #-}
|
||||
{-# LANGUAGE TypeFamilies #-}
|
||||
{-# LANGUAGE UndecidableInstances #-}
|
||||
@ -37,4 +34,3 @@ fuzz s = fuzz' (reifyServer s)
|
||||
reifyServer server = toReifiedApi (flattenServer @api server) (Proxy @(Endpoints api))
|
||||
-- reifyServer server = toReifiedApi server (Proxy @(Endpoints api))
|
||||
|
||||
|
||||
|
@ -7,9 +7,7 @@
|
||||
{-# LANGUAGE LambdaCase #-}
|
||||
{-# LANGUAGE PolyKinds #-}
|
||||
{-# LANGUAGE RankNTypes #-}
|
||||
{-# LANGUAGE RecordWildCards #-}
|
||||
{-# LANGUAGE ScopedTypeVariables #-}
|
||||
{-# LANGUAGE TupleSections #-}
|
||||
{-# LANGUAGE TypeApplications #-}
|
||||
{-# LANGUAGE TypeFamilies #-}
|
||||
{-# LANGUAGE UndecidableInstances #-}
|
||||
|
@ -29,7 +29,8 @@ import qualified Seeded
|
||||
import Test.Hspec
|
||||
import Test.Hspec.Core.Spec (FailureReason (Reason), ResultStatus (Failure, Success), itemExample, mapSpecItem_, resultStatus)
|
||||
import qualified Valid
|
||||
import Servant(Server,Proxy(..), serve)
|
||||
import Servant ( Server, Proxy(..), serve, Endpoints, HasServer )
|
||||
|
||||
import Servant.Client(ClientEnv, mkClientEnv, baseUrlPort, parseBaseUrl,HasClient,ClientM)
|
||||
import Network.Wai(Application)
|
||||
import qualified Network.Wai.Handler.Warp as Warp
|
||||
|
Loading…
Reference in New Issue
Block a user