This commit is contained in:
Thorn Avery 2024-06-29 13:35:41 +12:00
parent d9305136ff
commit 82be9f2cf5
3 changed files with 48 additions and 0 deletions

4
src/Universe/World.hs Normal file
View file

@ -0,0 +1,4 @@
module Universe.World (world) where
world :: String
world = "WORLD"

14
test/Main.hs Normal file
View file

@ -0,0 +1,14 @@
module Main where
import Universe.World
import Test.HUnit
tests = test
[ "message correct" ~: "WORLD" ~=? world
, "expected to pass" ~: assertBool "failed anyway" $ not ("WORLD" == "BLAH")
, "sanity check" ~: 3 ~=? (2 + 1)
]
main :: IO ()
main = runTestTTAndExit tests

30
universe.cabal Normal file
View file

@ -0,0 +1,30 @@
cabal-version: 1.12
name: universe
version: 0.0.0.1
license: MIT
build-type: Simple
synopsis: example library
description: an example library to test this repo's CI
author: Thorn Avery
maintainer: ta@p7.co.nz
library
exposed-modules:
Universe.World
hs-source-dirs:
src
build-depends:
base
default-language: Haskell2010
Test-Suite test-universe
type: exitcode-stdio-1.0
main-is: Main.hs
hs-source-dirs: test
build-depends:
base
, HUnit
, universe