diff options
| author | Wolfram Sang <wsa+renesas@sang-engineering.com> | 2026-09-16 23:31:11 +0200 |
|---|---|---|
| committer | Alexandre Belloni <alexandre.belloni@bootlin.com> | 2026-10-19 22:16:54 +0200 |
| commit | bd55831c0bfc0aa745753db972253aba2d452da3 (patch) | |
| tree | ebaaadb55e331241acbc583981c962abe9cc959f /tools/testing | |
| parent | 7980352c78f5aac7160941569826a260c6232589 (diff) | |
| download | linux-bd55831c0bfc0aa745753db972253aba2d452da3.tar.gz linux-bd55831c0bfc0aa745753db972253aba2d452da3.zip | |
selftest: rtc: rtctest: skip properly if setting alarm fails
Use the proper framework call to mark a test as skipped. Currently, the
test is considered good, only the printout mentions the skip.
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Link: https://patch.msgid.link/20260916213108.9234-8-wsa+renesas@sang-engineering.com
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Diffstat (limited to 'tools/testing')
| -rw-r--r-- | tools/testing/selftests/rtc/rtctest.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/tools/testing/selftests/rtc/rtctest.c b/tools/testing/selftests/rtc/rtctest.c index f8e2c0ce13c1..552191fe1ca0 100644 --- a/tools/testing/selftests/rtc/rtctest.c +++ b/tools/testing/selftests/rtc/rtctest.c @@ -257,8 +257,7 @@ TEST_F(rtc, alarm_alm_set) { */ ASSERT_EQ(RTC_ALARM_UNKNOWN, alarm_state); ASSERT_EQ(EINVAL, errno); - TH_LOG("skip alarms are not supported."); - return; + SKIP(return, "alarms are not supported."); } rc = ioctl(self->fd, RTC_ALM_READ, &tm); @@ -329,8 +328,7 @@ TEST_F(rtc, alarm_wkalm_set) { */ ASSERT_EQ(RTC_ALARM_UNKNOWN, alarm_state); ASSERT_EQ(EINVAL, errno); - TH_LOG("skip alarms are not supported."); - return; + SKIP(return, "alarms are not supported."); } rc = ioctl(self->fd, RTC_WKALM_RD, &alarm); @@ -389,8 +387,7 @@ TEST_F_TIMEOUT(rtc, alarm_alm_set_minute, 65) { */ ASSERT_EQ(RTC_ALARM_UNKNOWN, alarm_state); ASSERT_EQ(EINVAL, errno); - TH_LOG("skip alarms are not supported."); - return; + SKIP(return, "alarms are not supported."); } rc = ioctl(self->fd, RTC_ALM_READ, &tm); @@ -459,8 +456,7 @@ TEST_F_TIMEOUT(rtc, alarm_wkalm_set_minute, 65) { */ ASSERT_EQ(RTC_ALARM_UNKNOWN, alarm_state); ASSERT_EQ(EINVAL, errno); - TH_LOG("skip alarms are not supported."); - return; + SKIP(return, "alarms are not supported."); } rc = ioctl(self->fd, RTC_WKALM_RD, &alarm); |
