Lines Matching refs:status

147         ::ndk::ScopedAStatus status = mThermal->registerThermalChangedCallback(mThermalCallback);  in SetUp()
148 ASSERT_TRUE(status.isOk()) << status.getMessage(); in SetUp()
155 status = mThermal->registerCoolingDeviceChangedCallbackWithType(mCoolingDeviceCallback, in SetUp()
157 ASSERT_TRUE(status.isOk()) << status.getMessage(); in SetUp()
162 ::ndk::ScopedAStatus status = mThermal->unregisterThermalChangedCallback(mThermalCallback); in TearDown()
163 ASSERT_TRUE(status.isOk()) << status.getMessage(); in TearDown()
166 status = mThermal->unregisterThermalChangedCallback(mThermalCallback); in TearDown()
167 ASSERT_EQ(EX_ILLEGAL_ARGUMENT, status.getExceptionCode()); in TearDown()
172 status = mThermal->unregisterCoolingDeviceChangedCallback(mCoolingDeviceCallback); in TearDown()
173 ASSERT_TRUE(status.isOk()) << status.getMessage(); in TearDown()
174 status = mThermal->unregisterCoolingDeviceChangedCallback(mCoolingDeviceCallback); in TearDown()
175 ASSERT_EQ(EX_ILLEGAL_ARGUMENT, status.getExceptionCode()); in TearDown()
191 ::ndk::ScopedAStatus status = thermalCallback->notifyThrottling(kThrottleTemp); in TEST_P()
192 ASSERT_TRUE(status.isOk()) << status.getMessage(); in TEST_P()
206 ::ndk::ScopedAStatus status = cdevCallback->notifyCoolingDeviceChanged(kCoolingDevice); in TEST_P()
207 ASSERT_TRUE(status.isOk()) << status.getMessage(); in TEST_P()
214 ::ndk::ScopedAStatus status = mThermal->registerThermalChangedCallback(mThermalCallback); in TEST_P()
215 ASSERT_EQ(EX_ILLEGAL_ARGUMENT, status.getExceptionCode()); in TEST_P()
217 status = mThermal->registerThermalChangedCallback(nullptr); in TEST_P()
218 ASSERT_TRUE(status.getExceptionCode() == EX_ILLEGAL_ARGUMENT in TEST_P()
219 || status.getExceptionCode() == EX_NULL_POINTER); in TEST_P()
223 status = mThermal->registerThermalChangedCallback(localThermalCallback); in TEST_P()
224 ASSERT_TRUE(status.isOk()) << status.getMessage(); in TEST_P()
226 status = mThermal->unregisterThermalChangedCallback(localThermalCallback); in TEST_P()
227 ASSERT_TRUE(status.isOk()) << status.getMessage(); in TEST_P()
229 status = mThermal->unregisterThermalChangedCallback(nullptr); in TEST_P()
230 ASSERT_TRUE(status.getExceptionCode() == EX_ILLEGAL_ARGUMENT in TEST_P()
231 || status.getExceptionCode() == EX_NULL_POINTER); in TEST_P()
237 ::ndk::ScopedAStatus status = mThermal->registerThermalChangedCallbackWithType( in TEST_P()
239 ASSERT_EQ(EX_ILLEGAL_ARGUMENT, status.getExceptionCode()); in TEST_P()
241 status = mThermal->registerThermalChangedCallbackWithType(nullptr, TemperatureType::SKIN); in TEST_P()
242 ASSERT_TRUE(status.getExceptionCode() == EX_ILLEGAL_ARGUMENT in TEST_P()
243 || status.getExceptionCode() == EX_NULL_POINTER); in TEST_P()
247 status = mThermal->registerThermalChangedCallbackWithType(localThermalCallback, in TEST_P()
249 ASSERT_TRUE(status.isOk()) << status.getMessage(); in TEST_P()
251 status = mThermal->unregisterThermalChangedCallback(localThermalCallback); in TEST_P()
252 ASSERT_TRUE(status.isOk()) << status.getMessage(); in TEST_P()
254 status = mThermal->unregisterThermalChangedCallback(nullptr); in TEST_P()
255 ASSERT_TRUE(status.getExceptionCode() == EX_ILLEGAL_ARGUMENT in TEST_P()
256 || status.getExceptionCode() == EX_NULL_POINTER); in TEST_P()
268 ::ndk::ScopedAStatus status = mThermal->registerCoolingDeviceChangedCallbackWithType( in TEST_P()
270 ASSERT_EQ(EX_ILLEGAL_ARGUMENT, status.getExceptionCode()); in TEST_P()
272 status = mThermal->registerCoolingDeviceChangedCallbackWithType(nullptr, CoolingType::CPU); in TEST_P()
273 ASSERT_TRUE(status.getExceptionCode() == EX_ILLEGAL_ARGUMENT || in TEST_P()
274 status.getExceptionCode() == EX_NULL_POINTER); in TEST_P()
278 status = mThermal->registerCoolingDeviceChangedCallbackWithType(localCoolingDeviceCallback, in TEST_P()
280 ASSERT_TRUE(status.isOk()) << status.getMessage(); in TEST_P()
282 status = mThermal->unregisterCoolingDeviceChangedCallback(localCoolingDeviceCallback); in TEST_P()
283 ASSERT_TRUE(status.isOk()) << status.getMessage(); in TEST_P()
285 status = mThermal->unregisterCoolingDeviceChangedCallback(nullptr); in TEST_P()
286 ASSERT_TRUE(status.getExceptionCode() == EX_ILLEGAL_ARGUMENT || in TEST_P()
287 status.getExceptionCode() == EX_NULL_POINTER); in TEST_P()
293 ::ndk::ScopedAStatus status = mThermal->getTemperatures(&ret); in TEST_P()
294 if (status.isOk()) { in TEST_P()
300 ASSERT_EQ(EX_ILLEGAL_STATE, status.getExceptionCode()); in TEST_P()
305 status = mThermal->getTemperaturesWithType(type, &ret); in TEST_P()
307 if (status.isOk()) { in TEST_P()
314 ASSERT_EQ(EX_ILLEGAL_STATE, status.getExceptionCode()); in TEST_P()
322 ::ndk::ScopedAStatus status = mThermal->getTemperatureThresholds(&ret); in TEST_P()
323 if (status.isOk()) { in TEST_P()
329 ASSERT_EQ(EX_ILLEGAL_STATE, status.getExceptionCode()); in TEST_P()
334 status = mThermal->getTemperatureThresholdsWithType(type, &ret); in TEST_P()
336 if (status.isOk()) { in TEST_P()
343 ASSERT_EQ(EX_ILLEGAL_STATE, status.getExceptionCode()); in TEST_P()
364 ::ndk::ScopedAStatus status = in TEST_P()
366 ASSERT_TRUE(status.isOk()) << "getTemperaturesWithType(SKIN) failed"; in TEST_P()
372 status = mThermal->getTemperatureThresholdsWithType(TemperatureType::SKIN, &thresholds); in TEST_P()
373 ASSERT_TRUE(status.isOk()) << "getTemperatureThresholdsWithType(SKIN) failed"; in TEST_P()
399 ::ndk::ScopedAStatus status = mThermal->getCoolingDevices(&ret); in TEST_P()
400 if (status.isOk()) { in TEST_P()
406 ASSERT_EQ(EX_ILLEGAL_STATE, status.getExceptionCode()); in TEST_P()
411 status = mThermal->getCoolingDevicesWithType(type, &ret); in TEST_P()
412 if (status.isOk()) { in TEST_P()
413 ASSERT_TRUE(status.isOk()); in TEST_P()
420 ASSERT_EQ(EX_ILLEGAL_STATE, status.getExceptionCode()); in TEST_P()