Do not use any() to check whether a list is empty

any() is used to check whether there is at least
one element in an iterator that is True, e.g.,
>>> any([0, 0])
False

Although self.assertEqual(any([])) will get the same
result as self.assertEmpty([]), but it will make the
code look not so straightforward, so this is to fix
the unsuitable usage of any()

Change-Id: Icd313ebc1ca22b1c23e3f397bd16dfda0e31f8ee
7 files changed