aboutsummaryrefslogtreecommitdiffhomepage
path: root/test/test_latency.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'test/test_latency.cpp')
-rw-r--r--test/test_latency.cpp22
1 files changed, 9 insertions, 13 deletions
diff --git a/test/test_latency.cpp b/test/test_latency.cpp
index 5228510..97f24ea 100644
--- a/test/test_latency.cpp
+++ b/test/test_latency.cpp
@@ -1,9 +1,9 @@
+#include "cubeb/cubeb.h"
#include "gtest/gtest.h"
-#include <stdlib.h>
#include <memory>
-#include "cubeb/cubeb.h"
-//#define ENABLE_NORMAL_LOG
-//#define ENABLE_VERBOSE_LOG
+#include <stdlib.h>
+// #define ENABLE_NORMAL_LOG
+// #define ENABLE_VERBOSE_LOG
#include "common.h"
TEST(cubeb, latency)
@@ -17,8 +17,8 @@ TEST(cubeb, latency)
r = common_init(&ctx, "Cubeb audio test");
ASSERT_EQ(r, CUBEB_OK);
- std::unique_ptr<cubeb, decltype(&cubeb_destroy)>
- cleanup_cubeb_at_exit(ctx, cubeb_destroy);
+ std::unique_ptr<cubeb, decltype(&cubeb_destroy)> 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);
@@ -32,13 +32,9 @@ TEST(cubeb, latency)
ASSERT_GT(preferred_rate, 0u);
}
- cubeb_stream_params params = {
- CUBEB_SAMPLE_FLOAT32NE,
- preferred_rate,
- max_channels,
- CUBEB_LAYOUT_UNDEFINED,
- CUBEB_STREAM_PREF_NONE
- };
+ cubeb_stream_params params = {CUBEB_SAMPLE_FLOAT32NE, preferred_rate,
+ max_channels, CUBEB_LAYOUT_UNDEFINED,
+ CUBEB_STREAM_PREF_NONE};
r = cubeb_get_min_latency(ctx, &params, &latency_frames);
ASSERT_TRUE(r == CUBEB_OK || r == CUBEB_ERROR_NOT_SUPPORTED);
if (r == CUBEB_OK) {