test: SBS gauge gets initially supported props

Add a test that validates fetching every property from the sbs gauge driver
results in no driver error codes being returned.

Signed-off-by: Aaron Massey <aaronmassey@google.com>
This commit is contained in:
Aaron Massey 2022-10-11 16:18:17 -06:00 committed by Anas Nashif
commit 2dd0b48140
2 changed files with 46 additions and 4 deletions

View file

@ -62,8 +62,10 @@ static int emul_sbs_gauge_reg_read(const struct emul *target, int reg, int *val)
case SBS_GAUGE_CMD_NOM_CAPACITY:
case SBS_GAUGE_CMD_AVG_TIME2EMPTY:
case SBS_GAUGE_CMD_AVG_TIME2FULL:
case SBS_GAUGE_CMD_RUNTIME2EMPTY:
case SBS_GAUGE_CMD_CYCLE_COUNT:
case SBS_GAUGE_CMD_DESIGN_VOLTAGE:
case SBS_GAUGE_CMD_CURRENT:
/* Arbitrary stub value. */
*val = 1;
break;