diff options
author | Vic Yang <victoryang@chromium.org> | 2013-06-12 11:17:32 +0800 |
---|---|---|
committer | ChromeBot <chrome-bot@google.com> | 2013-06-13 18:13:19 -0700 |
commit | 61ae739eef0af9aa24d15dd9d0de42456f1e6420 (patch) | |
tree | f4c1c59764999cdff2a5a6a7ed96ddbff3bb85f8 /test | |
parent | 37597465503b30bbd2565e3f1affe9b683c418ce (diff) | |
download | chrome-ec-61ae739eef0af9aa24d15dd9d0de42456f1e6420.tar.gz |
More queue unit test
Check queue_remove_unit returns 0 on queue empty.
BUG=chrome-os-partner:19236
TEST=Pass the test.
BRANCH=None
Change-Id: I3162ba5e57e9111e1896954d815c26882fa372eb
Signed-off-by: Vic Yang <victoryang@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/58331
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Diffstat (limited to 'test')
-rw-r--r-- | test/queue.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/test/queue.c b/test/queue.c index 9fb886c8a3..c7b4518e02 100644 --- a/test/queue.c +++ b/test/queue.c @@ -39,6 +39,7 @@ static int test_queue6_empty(void) queue_reset(&test_queue6); TEST_ASSERT(queue_is_empty(&test_queue6)); + TEST_ASSERT(!queue_remove_unit(&test_queue6, &dummy)); queue_add_units(&test_queue6, &dummy, 1); TEST_ASSERT(!queue_is_empty(&test_queue6)); |