[U-Boot] [PATCH V3 14/14] sandbox: add ADC unit tests

Simon Glass sjg at chromium.org
Fri Nov 6 01:15:48 CET 2015


Hi Przemyslaw,

On 27 October 2015 at 06:08, Przemyslaw Marczak <p.marczak at samsung.com> wrote:
> This commit adds unit tests for ADC uclass's methods using sandbox ADC.
>
> Testing proper ADC binding:
> - dm_test_adc_bind()                    - device binding
> - dm_test_adc_wrong_channel_selection() - checking wrong channel selection
>
> Testing ADC supply operations:
> - dm_test_adc_supply():
>   - Vdd/Vss values validating
>   - Vdd regulator updated value validating
>   - Vdd regulator's auto enable state validating
>
> Testing ADC operations results:
> - dm_test_adc_single_channel_conversion() - single channel start/data
> - dm_test_adc_single_channel_shot()       - single channel shot
> - dm_test_adc_multi_channel_conversion()  - multi channel start/data
> - dm_test_adc_multi_channel_shot()        - multi channel single shot
>
> Signed-off-by: Przemyslaw Marczak <p.marczak at samsung.com>
> Cc: Simon Glass <sjg at chromium.org>
> ---
> Changes V3:
> - new commit
> ---
>  include/power/sandbox_pmic.h |   4 ++
>  test/dm/Makefile             |   1 +
>  test/dm/adc.c                | 165 +++++++++++++++++++++++++++++++++++++++++++
>  3 files changed, 170 insertions(+)
>  create mode 100644 test/dm/adc.c

Great test!

Reviewed-by: Simon Glass <sjg at chromium.org>


More information about the U-Boot mailing list