5#include "flutter/flow/stopwatch.h"
7#include "gmock/gmock.h"
8#include "gtest/gtest.h"
25TEST(Instrumentation, GetDefaultFrameBudgetTest) {
30 EXPECT_EQ(frame_budget_60fps, actual_frame_budget);
33TEST(Instrumentation, GetOneShotFrameBudgetTest) {
37 EXPECT_EQ(frame_budget_90fps, actual_frame_budget);
40TEST(Instrumentation, GetFrameBudgetFromUpdaterTest) {
47 EXPECT_EQ(frame_budget_90fps, actual_frame_budget);
50TEST(Instrumentation, GetLapByIndexTest) {
57TEST(Instrumentation, GetCurrentSampleTest) {
65TEST(Instrumentation, GetLapsCount) {
Used for fixed refresh rate cases.
The refresh rate interface for Stopwatch.
const fml::TimeDelta & GetLap(size_t index) const
fml::Milliseconds GetFrameBudget() const
All places which want to get frame_budget should call this function.
size_t GetLapsCount() const
Return a reference to all the laps.
size_t GetCurrentSample() const
void SetLapTime(const fml::TimeDelta &delta)
fml::Milliseconds GetFrameBudget() const override
void SetFrameBudget(fml::Milliseconds budget)
static constexpr TimeDelta FromMilliseconds(int64_t millis)
TEST(DisplayListComplexity, EmptyDisplayList)
std::chrono::duration< double, std::milli > Milliseconds
Milliseconds RefreshRateToFrameBudget(T refresh_rate)