From 161a80be5f7af7b9cbfe34137fd2ffd8d9c455ad Mon Sep 17 00:00:00 2001 From: Moonchild Date: Sun, 22 Aug 2021 17:39:55 +0000 Subject: Revert "Issue mcp-graveyard/UXP#1806 - Update libcubeb" This reverts commit 741fd8b61ccc5b3a01ccf8ff154ccb8ce80ecc38. --- media/libcubeb/gtest/test_latency.cpp | 47 ----------------------------------- 1 file changed, 47 deletions(-) delete mode 100644 media/libcubeb/gtest/test_latency.cpp (limited to 'media/libcubeb/gtest/test_latency.cpp') diff --git a/media/libcubeb/gtest/test_latency.cpp b/media/libcubeb/gtest/test_latency.cpp deleted file mode 100644 index 522851044a..0000000000 --- a/media/libcubeb/gtest/test_latency.cpp +++ /dev/null @@ -1,47 +0,0 @@ -#include "gtest/gtest.h" -#include -#include -#include "cubeb/cubeb.h" -//#define ENABLE_NORMAL_LOG -//#define ENABLE_VERBOSE_LOG -#include "common.h" - -TEST(cubeb, latency) -{ - cubeb * ctx = NULL; - int r; - uint32_t max_channels; - uint32_t preferred_rate; - uint32_t latency_frames; - - r = common_init(&ctx, "Cubeb audio test"); - ASSERT_EQ(r, CUBEB_OK); - - std::unique_ptr - cleanup_cubeb_at_exit(ctx, cubeb_destroy); - - r = cubeb_get_max_channel_count(ctx, &max_channels); - ASSERT_TRUE(r == CUBEB_OK || r == CUBEB_ERROR_NOT_SUPPORTED); - if (r == CUBEB_OK) { - ASSERT_GT(max_channels, 0u); - } - - r = cubeb_get_preferred_sample_rate(ctx, &preferred_rate); - ASSERT_TRUE(r == CUBEB_OK || r == CUBEB_ERROR_NOT_SUPPORTED); - if (r == CUBEB_OK) { - ASSERT_GT(preferred_rate, 0u); - } - - cubeb_stream_params params = { - CUBEB_SAMPLE_FLOAT32NE, - preferred_rate, - max_channels, - CUBEB_LAYOUT_UNDEFINED, - CUBEB_STREAM_PREF_NONE - }; - r = cubeb_get_min_latency(ctx, ¶ms, &latency_frames); - ASSERT_TRUE(r == CUBEB_OK || r == CUBEB_ERROR_NOT_SUPPORTED); - if (r == CUBEB_OK) { - ASSERT_GT(latency_frames, 0u); - } -} -- cgit v1.2.3