Use 'elif' instead of 'if' to avoid wrong self.result when
self.state is 'off'.
We need unit-tests for the engine checking the correctness: #79
if self.expected == 'is not off':
if self.state == 'off':
self.result = 'FAIL: is off'
if self.expected == 'is not off':
if self.state == 'off':
self.result = 'FAIL: is off'
+ elif self.state == '0':
self.result = 'FAIL: is off, "0"'
elif self.state is None:
self.result = 'FAIL: is off, not found'
self.result = 'FAIL: is off, "0"'
elif self.state is None:
self.result = 'FAIL: is off, not found'