diff options
author | Tom Smeding <tom@tomsmeding.com> | 2024-06-03 19:56:05 +0200 |
---|---|---|
committer | Tom Smeding <tom@tomsmeding.com> | 2024-06-03 19:56:05 +0200 |
commit | a25d4061e219cec153f066fddbf710abd63b5e48 (patch) | |
tree | e569635cffe75025ffc32faec38f8c3813c941d6 /test/Tests | |
parent | 91e43dd2e403ca892e235087970f52bb952b469f (diff) |
Move sh*Tail to main ox-arrays
Diffstat (limited to 'test/Tests')
-rw-r--r-- | test/Tests/C.hs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/test/Tests/C.hs b/test/Tests/C.hs index b98c23f..2a3949f 100644 --- a/test/Tests/C.hs +++ b/test/Tests/C.hs @@ -20,6 +20,7 @@ import Data.Array.Mixed.XArray qualified as X import Data.Array.Mixed.Lemmas import Data.Array.Nested import Data.Array.Nested.Internal.Mixed +import Data.Array.Nested.Internal.Shape import Hedgehog import Hedgehog.Internal.Property (forAllT) @@ -42,7 +43,7 @@ tests = testGroup "C" let inrank = SNat @(n + 1) sh <- forAll $ genShR inrank -- traceM ("sh: " ++ show sh ++ " -> " ++ show (product sh)) - guard (all (> 0) (toList (rshTail sh))) -- only constrain the tail + guard (all (> 0) (toList (shrTail sh))) -- only constrain the tail arr <- forAllT $ OR.fromVector @Double @(n + 1) (toList sh) <$> genStorables (Range.singleton (product sh)) (\w -> fromIntegral w / fromIntegral (maxBound :: Word64)) @@ -64,7 +65,7 @@ tests = testGroup "C" sht <- shuffleShR (0 :$: shtt) -- n n <- Gen.int (Range.linear 0 20) return (n :$: sht) -- n + 1 - guard (any (== 0) (toList (rshTail sh))) + guard (any (== 0) (toList (shrTail sh))) -- traceM ("sh: " ++ show sh ++ " -> " ++ show (product sh)) let arr = OR.fromList @Double @(n + 1) (toList sh) [] let rarr = rfromOrthotope inrank arr |