From 4d270712aecf1b61249086718852b96968de2bd8 Mon Sep 17 00:00:00 2001 From: Griffin Smith Date: Mon, 2 Sep 2019 13:56:25 -0400 Subject: Add raws, loaded statically from a folder Add raw types with support for both creatures and items, loaded statically from a "raws" folder just like in the Rust version. --- test/Spec.hs | 6 ++++-- test/Xanthous/DataSpec.hs | 2 +- test/Xanthous/Entities/RawsSpec.hs | 16 ++++++++++++++++ 3 files changed, 21 insertions(+), 3 deletions(-) create mode 100644 test/Xanthous/Entities/RawsSpec.hs (limited to 'test') diff --git a/test/Spec.hs b/test/Spec.hs index 6f955aa696..7ae9b40d26 100644 --- a/test/Spec.hs +++ b/test/Spec.hs @@ -4,15 +4,17 @@ import qualified Xanthous.Data.EntityMapSpec import qualified Xanthous.GameSpec import qualified Xanthous.MessageSpec import qualified Xanthous.OrphansSpec +import qualified Xanthous.Entities.RawsSpec main :: IO () main = defaultMain test test :: TestTree test = testGroup "Xanthous" - [ Xanthous.DataSpec.test - , Xanthous.Data.EntityMapSpec.test + [ Xanthous.Data.EntityMapSpec.test + , Xanthous.Entities.RawsSpec.test , Xanthous.GameSpec.test , Xanthous.MessageSpec.test , Xanthous.OrphansSpec.test + , Xanthous.DataSpec.test ] diff --git a/test/Xanthous/DataSpec.hs b/test/Xanthous/DataSpec.hs index ba060b7ad2..2c9f9dd3f9 100644 --- a/test/Xanthous/DataSpec.hs +++ b/test/Xanthous/DataSpec.hs @@ -1,6 +1,6 @@ -- | -module Xanthous.DataSpec where +module Xanthous.DataSpec (main, test) where import Test.Prelude hiding (Right, Left, Down) import Xanthous.Data diff --git a/test/Xanthous/Entities/RawsSpec.hs b/test/Xanthous/Entities/RawsSpec.hs new file mode 100644 index 0000000000..2e6f35457f --- /dev/null +++ b/test/Xanthous/Entities/RawsSpec.hs @@ -0,0 +1,16 @@ +-- | + +module Xanthous.Entities.RawsSpec (main, test) where + +import Test.Prelude +import Xanthous.Entities.Raws + +main :: IO () +main = defaultMain test + +test :: TestTree +test = testGroup "Xanthous.Entities.Raws" + [ testGroup "raws" + [ testCase "are all valid" $ raws `deepseq` pure () + ] + ] -- cgit 1.4.1