proper update device state at end of invocation

Avoid relying on exception type thrown from test invocation to infer
device state at end of test.

Bug: 22950992
Change-Id: Iac7ed02033a47a3968c1b369bc1f1f99423ff481
3 files changed