rm improper assert syntax

assert only raise AssertionError when runing python without '-O', so if
we except an Assertionerror in codes, just raise it instead of using
assert syntax instead of different result with or without '-O' flag

Change-Id: I8c1bc2c6849996f0d3f7a4b791671871d79dd939
Merge "rm improper assert syntax"