factoring out the NetworkTest
renaming locals to be more apt