mirror of
https://github.com/u-boot/u-boot.git
synced 2025-04-19 03:15:00 +00:00
test: py: add optee_rpmb tests
Add read/write tests for optee_rpmb cmd. Signed-off-by: Igor Opaniuk <igor.opaniuk@gmail.com> Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
This commit is contained in:
parent
dfac18e944
commit
f5d14bea8f
1 changed files with 20 additions and 0 deletions
20
test/py/tests/test_optee_rpmb.py
Normal file
20
test/py/tests/test_optee_rpmb.py
Normal file
|
@ -0,0 +1,20 @@
|
|||
# SPDX-License-Identifier: GPL-2.0+
|
||||
#
|
||||
# Tests for OP-TEE RPMB read/write support
|
||||
|
||||
"""
|
||||
This tests optee_rpmb cmd in U-Boot
|
||||
"""
|
||||
|
||||
import pytest
|
||||
import u_boot_utils as util
|
||||
|
||||
@pytest.mark.buildconfigspec('cmd_optee_rpmb')
|
||||
def test_optee_rpmb_read_write(u_boot_console):
|
||||
"""Test OP-TEE RPMB cmd read/write
|
||||
"""
|
||||
response = u_boot_console.run_command('optee_rpmb write_pvalue test_variable test_value')
|
||||
assert response == 'Wrote 11 bytes'
|
||||
|
||||
response = u_boot_console.run_command('optee_rpmb read_pvalue test_variable 11')
|
||||
assert response == 'Read 11 bytes, value = test_value'
|
Loading…
Add table
Reference in a new issue