Lines Matching refs:adaptation
110 void ApplyAdaptation(Adaptation adaptation) { in ApplyAdaptation() argument
111 adapter_->ApplyAdaptation(adaptation, nullptr); in ApplyAdaptation()
210 Adaptation adaptation = adapter_.GetAdaptationDown(); in TEST_F() local
211 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
212 EXPECT_FALSE(adaptation.min_pixel_limit_reached()); in TEST_F()
213 adapter_.ApplyAdaptation(adaptation, nullptr); in TEST_F()
234 Adaptation adaptation = adapter_.GetAdaptationDown(); in TEST_F() local
235 EXPECT_EQ(Adaptation::Status::kLimitReached, adaptation.status()); in TEST_F()
236 EXPECT_TRUE(adaptation.min_pixel_limit_reached()); in TEST_F()
280 Adaptation adaptation = adapter_.GetAdaptationDown(); in TEST_F() local
281 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
282 adapter_.ApplyAdaptation(adaptation, nullptr); in TEST_F()
298 Adaptation adaptation = adapter_.GetAdaptationDown(); in TEST_F() local
299 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
300 fake_stream.ApplyAdaptation(adaptation); in TEST_F()
319 Adaptation adaptation = adapter_.GetAdaptationUp(resource_); in TEST_F() local
320 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
321 fake_stream.ApplyAdaptation(adaptation); in TEST_F()
354 Adaptation adaptation = adapter_.GetAdaptationDown(); in TEST_F() local
355 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
356 adapter_.ApplyAdaptation(adaptation, nullptr); in TEST_F()
381 Adaptation adaptation = adapter_.GetAdaptationDown(); in TEST_F() local
382 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
383 fake_stream.ApplyAdaptation(adaptation); in TEST_F()
396 Adaptation adaptation = adapter_.GetAdaptationDown(); in TEST_F() local
397 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
398 fake_stream.ApplyAdaptation(adaptation); in TEST_F()
417 Adaptation adaptation = adapter_.GetAdaptationDown(); in TEST_F() local
418 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
419 fake_stream.ApplyAdaptation(adaptation); in TEST_F()
488 Adaptation adaptation = adapter_.GetAdaptationUp(resource_); in TEST_F() local
489 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
490 fake_stream.ApplyAdaptation(adaptation); in TEST_F()
504 Adaptation adaptation = adapter_.GetAdaptationUp(resource_); in TEST_F() local
505 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
506 fake_stream.ApplyAdaptation(adaptation); in TEST_F()
515 Adaptation adaptation = adapter_.GetAdaptationUp(resource_); in TEST_F() local
516 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
517 fake_stream.ApplyAdaptation(adaptation); in TEST_F()
526 Adaptation adaptation = adapter_.GetAdaptationUp(resource_); in TEST_F() local
527 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
528 fake_stream.ApplyAdaptation(adaptation); in TEST_F()
536 Adaptation adaptation = adapter_.GetAdaptationUp(resource_); in TEST_F() local
537 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
538 fake_stream.ApplyAdaptation(adaptation); in TEST_F()
566 Adaptation adaptation = adapter_.GetAdaptationDown(); in TEST_F() local
567 if (adaptation.status() == Adaptation::Status::kLimitReached) { in TEST_F()
571 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
572 fake_stream.ApplyAdaptation(adaptation); in TEST_F()
597 Adaptation adaptation = adapter_.GetAdaptationDown(); in TEST_F() local
599 adaptation.status()); in TEST_F()
618 Adaptation adaptation = adapter_.GetAdaptationUp(resource_); in TEST_F() local
620 adaptation.status()); in TEST_F()
642 Adaptation adaptation = adapter_.GetAdaptationUp(resource_); in TEST_F() local
643 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
666 Adaptation adaptation = adapter_.GetAdaptationUp(resource_); in TEST_F() local
667 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
688 Adaptation adaptation = adapter_.GetAdaptationUp(resource_); in TEST_F() local
689 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
703 Adaptation adaptation = adapter_.GetAdaptationDown(); in TEST_F() local
704 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
705 fake_stream.ApplyAdaptation(adaptation); in TEST_F()
720 Adaptation adaptation = adapter_.GetAdaptationDown(); in TEST_F() local
721 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
722 fake_stream.ApplyAdaptation(adaptation); in TEST_F()
739 Adaptation adaptation = adapter_.GetAdaptationDown(); in TEST_F() local
740 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
751 Adaptation adaptation = adapter_.GetAdaptationUp(resource_); in TEST_F() local
752 adapter_.ApplyAdaptation(adaptation, nullptr); in TEST_F()
758 Adaptation adaptation = adapter_.GetAdaptationDown(); in TEST_F() local
759 fake_stream.ApplyAdaptation(adaptation); in TEST_F()
761 EXPECT_EQ(adaptation.restrictions(), listener.last_restrictions()); in TEST_F()
777 Adaptation adaptation = adapter_.GetAdaptationUp(resource_); in TEST_F() local
778 EXPECT_EQ(Adaptation::Status::kLimitReached, adaptation.status()); in TEST_F()
779 EXPECT_EQ(adaptation.restrictions(), adapter_.source_restrictions()); in TEST_F()
780 EXPECT_EQ(0, adaptation.counters().Total()); in TEST_F()
784 Adaptation adaptation = adapter_.GetAdaptationDown(); in TEST_F() local
785 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
786 fake_stream.ApplyAdaptation(adaptation); in TEST_F()
787 EXPECT_EQ(adaptation.restrictions(), adapter_.source_restrictions()); in TEST_F()
788 EXPECT_EQ(adaptation.counters(), adapter_.adaptation_counters()); in TEST_F()
792 Adaptation adaptation = adapter_.GetAdaptationUp(resource_); in TEST_F() local
793 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
794 fake_stream.ApplyAdaptation(adaptation); in TEST_F()
795 EXPECT_EQ(adaptation.restrictions(), adapter_.source_restrictions()); in TEST_F()
796 EXPECT_EQ(adaptation.counters(), adapter_.adaptation_counters()); in TEST_F()
828 auto adaptation = adapter_.GetAdaptDownResolution(); in TEST_F() local
829 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
830 EXPECT_EQ(1, adaptation.counters().resolution_adaptations); in TEST_F()
831 EXPECT_EQ(0, adaptation.counters().fps_adaptations); in TEST_F()
855 auto adaptation = adapter_.GetAdaptDownResolution(); in TEST_F() local
856 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
857 EXPECT_EQ(1, adaptation.counters().resolution_adaptations); in TEST_F()
858 EXPECT_EQ(1, adaptation.counters().fps_adaptations); in TEST_F()
875 auto adaptation = adapter_.GetAdaptDownResolution(); in TEST_F() local
876 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
877 EXPECT_EQ(1, adaptation.counters().resolution_adaptations); in TEST_F()
879 adaptation.counters().fps_adaptations); in TEST_F()
891 auto adaptation = adapter_.GetAdaptDownResolution(); in TEST_F() local
892 EXPECT_EQ(Adaptation::Status::kValid, adaptation.status()); in TEST_F()
893 EXPECT_EQ(0, adaptation.counters().resolution_adaptations); in TEST_F()
894 EXPECT_EQ(1, adaptation.counters().fps_adaptations); in TEST_F()
921 auto adaptation = adapter_.GetAdaptationDown(); in TEST_F() local
922 adapter_.ApplyAdaptation(adaptation, nullptr); in TEST_F()
924 EXPECT_EQ(adaptation.restrictions(), restrictions_after); in TEST_F()
983 Adaptation adaptation = adapter.GetAdaptationDown(); in TEST() local
985 EXPECT_DEATH(adapter.ApplyAdaptation(adaptation, nullptr), ""); in TEST()
993 Adaptation adaptation = adapter.GetAdaptationDown(); in TEST() local
995 EXPECT_DEATH(adapter.ApplyAdaptation(adaptation, nullptr), ""); in TEST()