diff options
author | Bill Richardson <wfrichar@chromium.org> | 2011-10-04 08:36:09 -0700 |
---|---|---|
committer | Bill Richardson <wfrichar@chromium.org> | 2011-10-05 11:09:23 -0700 |
commit | 94d703459063fd144ec31ea0b70b9e94b208cfc8 (patch) | |
tree | d4e225c96debee2fdf0d5e05b4e42acca7e75aba /tests/vboot_api_devmode_tests.c | |
parent | 253a58e3834631e4688da45d31b0c475926bcbd6 (diff) | |
download | vboot-94d703459063fd144ec31ea0b70b9e94b208cfc8.tar.gz |
Enable (and test) custom dev-mode sounds
BUG=none
TEST=manual
cd src/platform/vboot_reference
make && make runtests
Change-Id: I7f7d50d7c9c5541e0b99031245f882996a6b88ec
Reviewed-on: http://gerrit.chromium.org/gerrit/8731
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Tested-by: Bill Richardson <wfrichar@chromium.org>
Reviewed-by: Randall Spangler <rspangler@chromium.org>
Diffstat (limited to 'tests/vboot_api_devmode_tests.c')
-rw-r--r-- | tests/vboot_api_devmode_tests.c | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/tests/vboot_api_devmode_tests.c b/tests/vboot_api_devmode_tests.c index c42795cd..8b5989df 100644 --- a/tests/vboot_api_devmode_tests.c +++ b/tests/vboot_api_devmode_tests.c @@ -5,20 +5,20 @@ * Tests for vboot_api_firmware */ -#include <stdio.h> #include <stddef.h> +#include <stdio.h> #include <stdlib.h> #include "crc32.h" +#include "gbb_header.h" #include "host_common.h" +#include "load_kernel_fw.h" #include "rollback_index.h" #include "test_common.h" #include "vboot_common.h" +#include "vboot_display.h" #include "vboot_nvstorage.h" #include "vboot_struct.h" -#include "load_kernel_fw.h" -#include "gbb_header.h" -#include "vboot_display.h" /* Expected results */ @@ -128,12 +128,8 @@ test_case_t test[] = { {0, 0, 30360}, // returns at 30 seconds + 360ms }}, - - - }; - /* Mock data */ static VbCommonParams cparams; static LoadKernelParams lkparams; @@ -150,7 +146,6 @@ static uint32_t kbd_fire_key; static VbError_t beep_return; static note_event_t *expected_event; - /* Reset mock data (for use before each test) */ static void ResetMocks(void) { @@ -282,7 +277,6 @@ VbError_t VbExDisplayScreen(uint32_t screen_type) { return VBERROR_SUCCESS; } - /****************************************************************************/ VbError_t VbBootDeveloper(VbCommonParams* cparams, LoadKernelParams* p); @@ -304,8 +298,8 @@ static void VbBootDeveloperSoundTest(void) { (void) VbBootDeveloper(&cparams, &lkparams); VBDEBUG(("INFO: matched %d total %d expected %d\n", matched_events, current_event, test[i].num_events)); - TEST_EQ(matched_events, test[i].num_events, test[i].name); - TEST_EQ(current_event, test[i].num_events, test[i].name); + TEST_TRUE(matched_events == test[i].num_events && + current_event == test[i].num_events, test[i].name); } } |