Template some classes in order to mock network io.