content: {-# LANGUAGE TypeOperators #-}
  {-# LANGUAGE DataKinds #-}
  
  module PoseidonSpec (spec) where
  
  import Test.Hspec
  import Crypto.Hash.PoseidonNative
  
  spec :: Spec
  spec = describe "poseidon" $ do
    describe "poseidon-hash" $ do
      it "computes the poseidon hash for two integers" $ do
        poseidon [1] `shouldBe` 18586133768512220936620570745912940619677854269274689475585506675881198879027
        poseidon [1, 2] `shouldBe` 7853200120776062878684798364095072458815029376092732009249414926327459813530
        poseidon [1, 2, 3] `shouldBe` 6542985608222806190361240322586112750744169038454362455181422643027100751666
        poseidon [1, 2, 3, 4] `shouldBe` 18821383157269793795438455681495246036402687001665670618754263018637548127333
        poseidon [1, 2, 3, 4, 5] `shouldBe` 6183221330272524995739186171720101788151706631170188140075976616310159254464
        poseidon [1, 2, 3, 4, 5, 6] `shouldBe` 20400040500897583745843009878988256314335038853985262692600694741116813247201
        poseidon [1, 2, 3, 4, 5, 6, 7] `shouldBe` 12748163991115452309045839028154629052133952896122405799815156419278439301912
        poseidon [1, 2, 3, 4, 5, 6, 7, 8] `shouldBe` 18604317144381847857886385684060986177838410221561136253933256952257712543953