implement a unittest to simulate network transer