Skip to content

Commit

Permalink
Test: eject should reset loop_start/end_pos
Browse files Browse the repository at this point in the history
  • Loading branch information
ronso0 committed Oct 26, 2023
1 parent 38af58d commit 7c9254b
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/test/looping_control_test.cpp
Expand Up @@ -678,6 +678,14 @@ TEST_F(LoopingControlTest, LoopResizeSeek) {
EXPECT_FRAMEPOS_EQ(mixxx::audio::FramePos{250}, currentFramePos());
}

TEST_F(LoopingControlTest, EjectResetsLoopInOutPositions) {
m_pLoopStartPoint->set(mixxx::audio::kStartFramePos.toEngineSamplePos());
m_pLoopEndPoint->set(mixxx::audio::FramePos{300}.toEngineSamplePos());
m_pChannel1->getEngineBuffer()->ejectTrack();
EXPECT_FRAMEPOS_EQ_CONTROL(mixxx::audio::kInvalidFramePos, m_pLoopStartPoint);
EXPECT_FRAMEPOS_EQ_CONTROL(mixxx::audio::kInvalidFramePos, m_pLoopEndPoint);
}

TEST_F(LoopingControlTest, BeatLoopSize_SetAndToggle) {
m_pTrack1->trySetBpm(120.0);
// Setting beatloop_size should not activate a loop
Expand Down

0 comments on commit 7c9254b

Please sign in to comment.