aboutsummaryrefslogtreecommitdiff
path: root/src/test/AudioTest.cpp
diff options
context:
space:
mode:
authorLoek Le Blansch <loek@pipeframe.xyz>2024-12-10 19:50:26 +0100
committerLoek Le Blansch <loek@pipeframe.xyz>2024-12-10 19:50:26 +0100
commit770496ee9d0e45480c0e0f8951adb8eee247bfe1 (patch)
tree98c68b0d37d8a1c0c8b8013ea7884d56f04aaa28 /src/test/AudioTest.cpp
parent0cb7f2f82ca167656b3c5cb9f0cc3b44c59cb0eb (diff)
big WIP
Diffstat (limited to 'src/test/AudioTest.cpp')
-rw-r--r--src/test/AudioTest.cpp28
1 files changed, 14 insertions, 14 deletions
diff --git a/src/test/AudioTest.cpp b/src/test/AudioTest.cpp
index 48bba1b..415a12e 100644
--- a/src/test/AudioTest.cpp
+++ b/src/test/AudioTest.cpp
@@ -50,11 +50,11 @@ TEST_F(AudioTest, Default) {
EXPECT_CALL(context, stop(_)).Times(0);
EXPECT_CALL(context, set_volume(_, _)).Times(0);
EXPECT_CALL(context, set_loop(_, _)).Times(0);
- system.update();
+ system.fixed_update();
}
TEST_F(AudioTest, Play) {
- system.update();
+ system.fixed_update();
{
InSequence seq;
@@ -67,12 +67,12 @@ TEST_F(AudioTest, Play) {
InSequence seq;
EXPECT_CALL(context, play(_)).Times(1);
- system.update();
+ system.fixed_update();
}
}
TEST_F(AudioTest, Stop) {
- system.update();
+ system.fixed_update();
{
InSequence seq;
@@ -85,12 +85,12 @@ TEST_F(AudioTest, Stop) {
InSequence seq;
EXPECT_CALL(context, stop(_)).Times(1);
- system.update();
+ system.fixed_update();
}
}
TEST_F(AudioTest, Volume) {
- system.update();
+ system.fixed_update();
{
InSequence seq;
@@ -103,12 +103,12 @@ TEST_F(AudioTest, Volume) {
InSequence seq;
EXPECT_CALL(context, set_volume(_, component.volume)).Times(1);
- system.update();
+ system.fixed_update();
}
}
TEST_F(AudioTest, Looping) {
- system.update();
+ system.fixed_update();
{
InSequence seq;
@@ -121,33 +121,33 @@ TEST_F(AudioTest, Looping) {
InSequence seq;
EXPECT_CALL(context, set_loop(_, component.loop)).Times(1);
- system.update();
+ system.fixed_update();
}
}
TEST_F(AudioTest, StopOnDeactivate) {
- system.update();
+ system.fixed_update();
{
InSequence seq;
EXPECT_CALL(context, stop(_)).Times(1);
component.active = false;
- system.update();
+ system.fixed_update();
}
}
TEST_F(AudioTest, PlayOnActive) {
component.active = false;
component.play_on_awake = true;
- system.update();
+ system.fixed_update();
{
InSequence seq;
EXPECT_CALL(context, play(_)).Times(1);
component.active = true;
- system.update();
+ system.fixed_update();
}
}
@@ -157,5 +157,5 @@ TEST_F(AudioTest, PlayImmediately) {
EXPECT_CALL(context, play(_)).Times(1);
- system.update();
+ system.fixed_update();
}