servo: avoid empty domains after trimming in timelined stats manager

As a result of trimming a list might become empty i.e. have no more
values. If that's the case, then numpy's min/max functions will throw
errors. More importantly: it's meaningless to us if the list is empty
anyways. This change logs when an empty domain list is being generated,
before removing that domain from the data of the stats manager.

BUG=None
TEST=added unittest

Change-Id: Ib61fb18c667241cf12c684a385e524dfb07ea86a
Signed-off-by: Ruben Rodriguez Buchillon <coconutruben@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1371348
Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com>
Reviewed-by: Mengqi Guo <mqg@chromium.org>
2 files changed