elm-matrix-sdk-beta/tests/Test/Matrix/Settings.elm

36 lines
988 B
Elm
Raw Permalink Normal View History

2023-12-24 10:30:50 +00:00
module Test.Matrix.Settings exposing (..)
import Expect
import Fuzz
import Matrix.Settings
import Test exposing (..)
import Test.Types as TestTypes
settings : Test
settings =
describe "Exposed Matrix.Settings"
[ describe "Set values"
[ fuzz2 TestTypes.vault
Fuzz.string
"Set device name"
(\vault name ->
vault
|> Matrix.Settings.setDeviceName name
|> Matrix.Settings.getDeviceName
|> Expect.equal name
)
, fuzz2 TestTypes.vault
Fuzz.int
"Set sync time"
(\vault sync ->
vault
|> Matrix.Settings.setSyncTime sync
|> Matrix.Settings.getSyncTime
2024-01-12 16:15:07 +00:00
|> Expect.equal (max 1 sync)
2023-12-24 10:30:50 +00:00
)
]
-- , describe "Read values" []
]