A distributed and topology-agnostic approach for on-line NoC testing