mirror of
https://github.com/Start9Labs/start-os.git
synced 2026-04-01 21:13:09 +00:00
0.2.5 initial commit
Makefile incomplete
This commit is contained in:
16
agent/test/Lib/SoundSpec.hs
Normal file
16
agent/test/Lib/SoundSpec.hs
Normal file
@@ -0,0 +1,16 @@
|
||||
module Lib.SoundSpec where
|
||||
|
||||
import Startlude
|
||||
|
||||
import Test.Hspec
|
||||
|
||||
import Lib.Sound
|
||||
|
||||
spec :: Spec
|
||||
spec = describe "Sound Interface" $ do
|
||||
it "Async sound actions should be FIFO" $ do
|
||||
action <- async $ playSongTimed 400 marioDeath
|
||||
action' <- async $ playSongTimed 400 marioDeath
|
||||
marks0 <- wait action
|
||||
marks1 <- wait action'
|
||||
(marks0, marks1) `shouldSatisfy` \((s0, f0), (s1, f1)) -> s1 > s0 && s1 > f0 || s0 > s1 && s0 > f1
|
||||
Reference in New Issue
Block a user