mirror of
https://github.com/hasura/graphql-engine.git
synced 2024-12-17 20:41:49 +03:00
cc87b25373
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/6646 GitOrigin-RevId: b96a68c5eab1ac33a226d2d89141e0de9eaeff93
32 lines
1.2 KiB
Haskell
32 lines
1.2 KiB
Haskell
-- | Service liveness tests: Confirm that the harness is working
|
|
-- properly. If this passes, the rest of the tests will pass.
|
|
module Test.ServiceLivenessSpec (spec) where
|
|
|
|
import Harness.Backend.Citus qualified as Citus
|
|
import Harness.Backend.Cockroach qualified as Cockroach
|
|
import Harness.Backend.Mysql qualified as Mysql
|
|
import Harness.Backend.Postgres qualified as Postgres
|
|
import Harness.Backend.Sqlserver qualified as Sqlserver
|
|
import Harness.GraphqlEngine qualified as GraphqlEngine
|
|
import Harness.Http qualified as Http
|
|
import Harness.TestEnvironment (TestEnvironment (TestEnvironment, server))
|
|
import Hasura.Prelude
|
|
import Test.Hspec
|
|
|
|
spec :: SpecWith TestEnvironment
|
|
spec = do
|
|
ignoreSubject do
|
|
it "Postgres metadata DB" $ shouldReturn Postgres.metadataLivenessCheck ()
|
|
it "MySQL" $ shouldReturn Mysql.livenessCheck ()
|
|
it "SQLServer" $ shouldReturn Sqlserver.livenessCheck ()
|
|
it "Citus" $ shouldReturn Citus.livenessCheck ()
|
|
it "Cockroach" $ shouldReturn Cockroach.livenessCheck ()
|
|
it "Postgres" $ \testEnvironment ->
|
|
shouldReturn (Postgres.livenessCheck testEnvironment) ()
|
|
it
|
|
"graphql-engine"
|
|
\TestEnvironment {server} ->
|
|
shouldReturn
|
|
(Http.healthCheck (GraphqlEngine.serverUrl server))
|
|
()
|