27 BYTE capacity_flags, expected_capacity_flags;
32 memset(&ps, 0x23,
sizeof(ps));
38 skip(
"GetSystemPowerStatus not implemented or not working\n");
43 trace(
"battery detected\n");
44 expected_capacity_flags = 0;
51 capacity_flags = (ps.
BatteryFlag & ~BATTERY_FLAG_CHARGING);
52 ok(capacity_flags == expected_capacity_flags,
53 "expected %u%%-charged battery to have capacity flags 0x%02x, got 0x%02x\n",
56 "expected BatteryLifeTime %lu to be less than or equal to BatteryFullLifeTime %lu\n",
61 "expected BatteryLifeTime to be -1 when charging, got %lu\n", ps.
BatteryLifeTime);
68 trace(
"no battery detected\n");
70 "expected ACLineStatus to be 1, got %u\n", ps.
ACLineStatus);
BOOL WINAPI GetSystemPowerStatus(IN LPSYSTEM_POWER_STATUS PowerStatus)
void test_GetSystemPowerStatus(void)
DWORD BatteryFullLifeTime
#define BATTERY_FLAG_CHARGING
#define BATTERY_LIFE_UNKNOWN
#define BATTERY_FLAG_NO_BATTERY
#define BATTERY_FLAG_CRITICAL
#define BATTERY_FLAG_UNKNOWN
#define BATTERY_FLAG_HIGH
#define BATTERY_PERCENTAGE_UNKNOWN