aboutsummaryrefslogtreecommitdiffstats
path: root/tests/tests.h
diff options
context:
space:
mode:
authorAnastasia Klimchuk <aklm@chromium.org>2021-08-12 10:41:03 +1000
committerEdward O'Callaghan <quasisec@chromium.org>2021-08-19 04:30:03 +0000
commitcdf8cf4afe305b10bc6169856282cdbb6bcfbf32 (patch)
tree2a25baad5236b1901427f3d05d79b8b83d5f164d /tests/tests.h
parent47f4c18260e1eff46b0605b1039166238fc4797c (diff)
downloadflashrom-cdf8cf4afe305b10bc6169856282cdbb6bcfbf32.tar.gz
flashrom-cdf8cf4afe305b10bc6169856282cdbb6bcfbf32.tar.bz2
flashrom-cdf8cf4afe305b10bc6169856282cdbb6bcfbf32.zip
tests: Use real spi_send_command for all tests except spi25.c
At the moment one test (spi25.c) uses wrap of spi_send_command, and all other existing tests don't care about this function (don't call it at all). However in the next patch a new test in introduced, which needs a real spi_send_command. Following the approach "don't mock unless it is strictly necessary", all tests that don't care go into real function bucket. A declaration for __real_spi_send_command is needed for visibility, this way wrap function can redirect to real function for all other tests except spi25.c. Additionally, wrap function moves below mock_chip, so that mock_chip is visible inside wrap. BUG=b:181803212 TEST=builds and ninja test Change-Id: I22945cce3d0f36adaa8032167a3ef4e54eccb611 Signed-off-by: Anastasia Klimchuk <aklm@chromium.org> Reviewed-on: https://review.coreboot.org/c/flashrom/+/56753 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Edward O'Callaghan <quasisec@chromium.org>
Diffstat (limited to 'tests/tests.h')
0 files changed, 0 insertions, 0 deletions