Remaining unit tests for rollback_index.c

BUG=chromium-os:17564
TEST=make && make runtests

Change-Id: If2fbfb788bc3199603c8646e8f1c9e061199bc6f
Reviewed-on: http://gerrit.chromium.org/gerrit/6832
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Tested-by: Randall Spangler <rspangler@chromium.org>
This commit is contained in:
Randall Spangler
2011-08-29 12:37:15 -07:00
parent cb3313e8cb
commit 46d37cfbbb
3 changed files with 438 additions and 39 deletions

View File

@@ -12,6 +12,14 @@
#include "utility.h"
#include "vboot_api.h"
#ifdef ROLLBACK_UNITTEST
/* Compiling for unit test, so we need the real implementations of
* rollback functions. The unit test mocks the underlying tlcl
* functions, so this is ok to run on the host. */
#undef CHROMEOS_ENVIRONMENT
#undef DISABLE_ROLLBACK_TPM
#endif
static int g_rollback_recovery_mode = 0;
/* disable MSVC warning on const logical expression (as in } while(0);) */