mirror of
https://github.com/wasp-lang/wasp.git
synced 2024-12-02 12:53:14 +03:00
0002414fa1
* Telemetry now recognizes when running on CI. * Bumped cabal version from 0.8.0 to 0.8.1 . * fixed e2e tests.
26 lines
768 B
Haskell
26 lines
768 B
Haskell
module Wasp.Cli.Command.Telemetry.ProjectTest where
|
|
|
|
import Test.Tasty.Hspec
|
|
import Wasp.Cli.Command.Telemetry.Project
|
|
( checkIfEnvValueIsTruthy,
|
|
)
|
|
|
|
spec_checkIfEnvValueIsTruthy :: Spec
|
|
spec_checkIfEnvValueIsTruthy = do
|
|
it "Correctly determines if different env values are truthy" $ do
|
|
let testCases =
|
|
[ (Nothing, False),
|
|
(Just "", False),
|
|
(Just "false", False),
|
|
(Just "False", False),
|
|
(Just "FALSE", False),
|
|
(Just "true", True),
|
|
(Just "something", True),
|
|
(Just "0", True),
|
|
(Just "1", True),
|
|
(Just "falsy", True),
|
|
(Just "foo", True)
|
|
]
|
|
checkIfEnvValueIsTruthy . fst <$> testCases
|
|
`shouldBe` snd <$> testCases
|