diff options
author | Jack Rosenthal <jrosenth@chromium.org> | 2022-06-27 15:22:35 -0600 |
---|---|---|
committer | Chromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com> | 2022-06-28 06:20:42 +0000 |
commit | 029982ec8fc82fbe4fa1d7fa6273d61e714506be (patch) | |
tree | 324014b75644eb1280ea071616f406ac4ac47ae9 /test/stillness_detector.c | |
parent | b1b06014fe5fb12935852d33a94e78f3312bc0fc (diff) | |
download | chrome-ec-029982ec8fc82fbe4fa1d7fa6273d61e714506be.tar.gz |
test/stillness_detector.c: Format with clang-format
BUG=b:236386294
BRANCH=none
TEST=none
Change-Id: I8f01bc7a954c89b4fd19da2feb69f1ede7a6eb0f
Signed-off-by: Jack Rosenthal <jrosenth@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3730523
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
Diffstat (limited to 'test/stillness_detector.c')
-rw-r--r-- | test/stillness_detector.c | 32 |
1 files changed, 14 insertions, 18 deletions
diff --git a/test/stillness_detector.c b/test/stillness_detector.c index 57057e217e..ce28c76eb1 100644 --- a/test/stillness_detector.c +++ b/test/stillness_detector.c @@ -35,8 +35,8 @@ static int test_not_still_short_window(void) int i; for (i = 0; i < 6; ++i) - TEST_ASSERT(!still_det_update(&det, i * 100 * MSEC, - 0.0f, 0.0f, 0.0f)); + TEST_ASSERT(!still_det_update(&det, i * 100 * MSEC, 0.0f, 0.0f, + 0.0f)); return EC_SUCCESS; } @@ -47,8 +47,8 @@ static int test_not_still_long_window(void) int i; for (i = 0; i < 5; ++i) - TEST_ASSERT(!still_det_update(&det, i * 300 * MSEC, - 0.0f, 0.0f, 0.0f)); + TEST_ASSERT(!still_det_update(&det, i * 300 * MSEC, 0.0f, 0.0f, + 0.0f)); return EC_SUCCESS; } @@ -59,8 +59,8 @@ static int test_not_still_not_enough_samples(void) int i; for (i = 0; i < 4; ++i) - TEST_ASSERT(!still_det_update(&det, i * 200 * MSEC, - 0.0f, 0.0f, 0.0f)); + TEST_ASSERT(!still_det_update(&det, i * 200 * MSEC, 0.0f, 0.0f, + 0.0f)); return EC_SUCCESS; } @@ -71,9 +71,8 @@ static int test_is_still_all_axes(void) int i; for (i = 0; i < 9; ++i) { - int result = still_det_update(&det, i * 100 * MSEC, - i * 0.001f, i * 0.001f, - i * 0.001f); + int result = still_det_update(&det, i * 100 * MSEC, i * 0.001f, + i * 0.001f, i * 0.001f); TEST_EQ(result, i == 8 ? 1 : 0, "%d"); } @@ -90,9 +89,8 @@ static int test_not_still_one_axis(void) int i; for (i = 0; i < 9; ++i) { - TEST_ASSERT(!still_det_update(&det, i * 100 * MSEC, - i * 0.001f, i * 0.001f, - i * 0.01f)); + TEST_ASSERT(!still_det_update(&det, i * 100 * MSEC, i * 0.001f, + i * 0.001f, i * 0.01f)); } return EC_SUCCESS; @@ -104,15 +102,13 @@ static int test_resets(void) int i; for (i = 0; i < 9; ++i) { - TEST_ASSERT(!still_det_update(&det, i * 100 * MSEC, - i * 0.001f, i * 0.001f, - i * 0.01f)); + TEST_ASSERT(!still_det_update(&det, i * 100 * MSEC, i * 0.001f, + i * 0.001f, i * 0.01f)); } for (i = 0; i < 9; ++i) { - int result = still_det_update(&det, i * 100 * MSEC, - i * 0.001f, i * 0.001f, - i * 0.001f); + int result = still_det_update(&det, i * 100 * MSEC, i * 0.001f, + i * 0.001f, i * 0.001f); TEST_EQ(result, i == 8 ? 1 : 0, "%d"); } |