diff options
author | Vic Yang <victoryang@chromium.org> | 2014-10-01 14:43:15 +0800 |
---|---|---|
committer | chrome-internal-fetch <chrome-internal-fetch@google.com> | 2014-10-04 21:08:38 +0000 |
commit | 7bbf6d7bb3dd55a70a00e37561c747cd0a7cb315 (patch) | |
tree | cb71dc82579592ff2e1bc21a8f639105f5fa2629 /test | |
parent | 7b1e58cc4361ea0369b0326dba82e3b513ac3232 (diff) | |
download | chrome-ec-7bbf6d7bb3dd55a70a00e37561c747cd0a7cb315.tar.gz |
Slow down time when running unit tests
When a timing sensitive test run on a heavily loaded system, sometimes a
task runs for longer than it usually does and causes the test to fail.
All the timing requirements in the unit tests are trying to verify the
various delays in our codebase, and mostly we don't care about the time
taken by active running code (as they are very quick.) To improve the
stability of tests, let's slow down the time. To a test, it's as if the
code runs faster. If a test uses udelay() and exceeds the 10-second time
limit, we can make that single test faster by setting the time scale.
BUG=None
TEST=Repeatedly run 'make runtests'
BRANCH=None
Change-Id: I9bc5c77e0d34d04c8630d495387a751ef29c7bd5
Signed-off-by: Vic Yang <victoryang@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/220717
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Reviewed-by: Randall Spangler <rspangler@chromium.org>
Diffstat (limited to 'test')
-rw-r--r-- | test/build.mk | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/test/build.mk b/test/build.mk index a2094ba112..f503188410 100644 --- a/test/build.mk +++ b/test/build.mk @@ -44,6 +44,7 @@ hooks-y=hooks.o host_command-y=host_command.o inductive_charging-y=inductive_charging.o interrupt-y=interrupt.o +interrupt-scale=10 kb_8042-y=kb_8042.o kb_mkbp-y=kb_mkbp.o kb_scan-y=kb_scan.o |