diff --git a/source/AirGQL/GQLWrapper.hs b/source/AirGQL/GQLWrapper.hs deleted file mode 100644 index 1e07c26..0000000 --- a/source/AirGQL/GQLWrapper.hs +++ /dev/null @@ -1,47 +0,0 @@ -{-| -Increase readability of code -by wrapping `graphql` library with descriptive wrappers --} -module AirGQL.GQLWrapper ( - OutField (..), - outFieldToField, - InArgument (..), - inArgumentToArgument, -) -where - -import Protolude (Maybe, Text) - -import Language.GraphQL.Type (Value) -import Language.GraphQL.Type.In qualified as In -import Language.GraphQL.Type.Out qualified as Out - - -data OutField m = OutField - { descriptionMb :: Maybe Text - , fieldType :: Out.Type m - , arguments :: In.Arguments - } - - -outFieldToField :: OutField m -> Out.Field m -outFieldToField outField = - Out.Field - outField.descriptionMb - outField.fieldType - outField.arguments - - -data InArgument = InArgument - { argDescMb :: Maybe Text - , argType :: In.Type - , valueMb :: Maybe Value - } - - -inArgumentToArgument :: InArgument -> In.Argument -inArgumentToArgument inArgument = - In.Argument - inArgument.argDescMb - inArgument.argType - inArgument.valueMb diff --git a/tests/Tests/Utils.hs b/tests/Tests/Utils.hs index 00ab60a..abaadcd 100644 --- a/tests/Tests/Utils.hs +++ b/tests/Tests/Utils.hs @@ -101,8 +101,8 @@ rmSpaces text = Nothing -> "ERROR: Failed to decode JSON" -{-| Checks whether a value would get encoded to a json string. Does not care -about the order of fields or elements in lists. +{-| Checks whether a value would get encoded to a given json string. +Does not care about the order of fields or elements in lists. -} unorderedShouldBe :: (ToJSON a) => a -> Text -> IO () unorderedShouldBe actual expected = do