[RFC/PATCH v3 2/2] tests: Improve tests for watchdog ioctl commands

Eugene Syromyatnikov evgsyr at gmail.com
Sun Aug 25 14:11:40 UTC 2024


On Thu, Aug 08, 2024 at 01:29:56AM +0530, Sahil Siddiq wrote:
> Add new tests for WDIOC_GETSUPPORT and WDIOC_SETOPTIONS
> decoders. Also enhance tests for currently available
> watchdog ioctl decoders. This enables the verification
> of their behaviour when:
> 
> 1. the ioctl is successful (returns a non-negative
>    integer).
> 2. strace is run with the -v option.
> 
> * tests/.gitignore (ioctl_watchdog-success.c,
>   ioctl_watchdog-success-v.c): New entries.
> * tests/Makefile.am (ioctl_watchdog-success.c,
>   ioctl_watchdog-success-v.c): New entries.
> * tests/gen_tests.in (ioctl_watchdog-success.c,
>   ioctl_watchdog-success-v.c): New entries.
> * tests/ioctl_watchdog-success.c: New file.
> * tests/ioctl_watchdog-success-v.c: New file.
> * tests/ioctl_watchdog.c:
>   - (do_ioctl, do_ioctl_ptr): New functions.
>   - (main): Place argc, argv in argument list.
>   - (WDIOC_GETSUPPORT, WDIOC_SETOPTIONS): Add decoder tests.
>   - (WDIOC_GET*): Improve existing decoder tests.
> 
> Signed-off-by: Sahil Siddiq <sahilcdq at proton.me>

Reviewed-by: Eugene Syromyatnikov <evgsyr at gmail.com>


More information about the Strace-devel mailing list