:)
[platform/kernel/u-boot.git] / test / Kconfig
1 menuconfig UNIT_TEST
2         bool "Unit tests"
3         help
4           Select this to compile in unit tests for various parts of
5           U-Boot. Test suites will be subcommands of the "ut" command.
6           This does not require sandbox to be included, but it is most
7           often used there.
8
9 config SPL_UNIT_TEST
10         bool "Unit tests in SPL"
11         depends on SPL
12         # We need to be able to unbind devices for tests to work
13         select SPL_DM_DEVICE_REMOVE
14         help
15           Select this to enable unit tests in SPL. Most test are designed for
16           running in U-Boot proper, but some are intended for SPL, such as
17           of-platdata and SPL handover. To run these tests with the sandbox_spl
18           board, use the -u (unit test) option.
19
20 config UT_LIB
21         bool "Unit tests for library functions"
22         depends on UNIT_TEST
23         default y if !SANDBOX_VPL
24         help
25           Enables the 'ut lib' command which tests library functions like
26           memcat(), memcyp(), memmove() and ASN1 compiler/decoder.
27
28 if UT_LIB
29
30 config UT_LIB_ASN1
31         bool "Unit test for asn1 compiler and decoder function"
32         default y
33         imply ASYMMETRIC_KEY_TYPE
34         imply ASYMMETRIC_PUBLIC_KEY_SUBTYPE
35         imply X509_CERTIFICATE_PARSER
36         imply PKCS7_MESSAGE_PARSER
37         imply RSA_PUBLIC_KEY_PARSER
38         help
39           Enables a test which exercises asn1 compiler and decoder function
40           via various parsers.
41
42 config UT_LIB_CRYPT
43         bool "Unit test for crypt-style password hashing"
44         depends on !SPL && AUTOBOOT_KEYED && AUTOBOOT_ENCRYPTION
45         default y
46         select CRYPT_PW
47         select CRYPT_PW_SHA256
48         select CRYPT_PW_SHA512
49         help
50           Enables a test for the crypt-style password hash functions.
51
52 config UT_LIB_RSA
53         bool "Unit test for rsa_verify() function"
54         depends on RSA
55         depends on RSA_VERIFY_WITH_PKEY
56         select IMAGE_SIGN_INFO
57         default y
58         help
59           Enables rsa_verify() test, currently rsa_verify_with_pkey only()
60           only, at the 'ut lib' command.
61
62 endif
63
64 config UT_COMPRESSION
65         bool "Unit test for compression"
66         depends on UNIT_TEST
67         depends on CMDLINE && GZIP_COMPRESSED && BZIP2 && LZMA && LZO && LZ4
68         default y
69         help
70           Enables tests for compression and decompression routines for simple
71           sanity and for buffer overflow conditions.
72
73 config UT_LOG
74         bool "Unit tests for logging functions"
75         depends on UNIT_TEST
76         default y
77         help
78           Enables the 'ut log' command which tests logging functions like
79           log_err().
80           See also CONFIG_LOG_TEST which provides the 'log test' command.
81
82 config UT_TIME
83         bool "Unit tests for time functions"
84         depends on UNIT_TEST
85         help
86           Enables the 'ut time' command which tests that the time functions
87           work correctly. The test is fairly simple and will not catch all
88           problems. But if you are having problems with udelay() and the like,
89           this is a good place to start.
90
91 config UT_UNICODE
92         bool "Unit tests for Unicode functions"
93         depends on UNIT_TEST
94         default y
95         select CHARSET
96         help
97           Enables the 'ut unicode' command which tests that the functions for
98           manipulating Unicode strings work correctly.
99
100 source "test/dm/Kconfig"
101 source "test/env/Kconfig"
102 source "test/lib/Kconfig"
103 source "test/optee/Kconfig"
104 source "test/overlay/Kconfig"