diff --git a/gfx/tests/gtest/TestVsync.cpp b/gfx/tests/gtest/TestVsync.cpp index d50ebbd4f13..f13afc983fa 100644 --- a/gfx/tests/gtest/TestVsync.cpp +++ b/gfx/tests/gtest/TestVsync.cpp @@ -195,3 +195,12 @@ TEST_F(VsyncTester, ChildRefreshDriverGetVsyncNotifications) vsyncDispatcher = nullptr; testVsyncObserver = nullptr; } + +// Test that we can read the vsync rate +TEST_F(VsyncTester, VsyncSourceHasVsyncRate) +{ + VsyncSource::Display& globalDisplay = mVsyncSource->GetGlobalDisplay(); + TimeDuration vsyncRate = globalDisplay.GetVsyncRate(); + ASSERT_NE(vsyncRate, TimeDuration::Forever()); + ASSERT_GT(vsyncRate.ToMilliseconds(), 0); +}