utils: add TimeSource to make time depending testing simpler

inspired by Guava's Ticker as well as similar patch from Paul

Acked-by: Paul Millar
Acked-by: Karsten Schwank
Target: master