added a test case for the bug and refactored the tests for the G(n, p) random graphs
added a test case for the bug and refactored the tests for the G(n, p) random graphs

dmoliveira/networkx,yashu-seth/networkx,ghdk/networkx,wasade/networkx,jni/networkx,dhimmel/networkx,tmilicic/networkx,jakevdp/networkx,RMKD/networkx,farhaanbukhsh/networkx,RMKD/networkx,goulu/networkx,kernc/networkx,ionanrozenfeld/networkx,sharifulgeo/networkx,chrisnatali/networkx,debsankha/networkx,ltiao/networkx,harlowja/networkx,debsankha/networkx,sharifulgeo/networkx,chrisnatali/networkx,sharifulgeo/networkx,beni55/networkx,jcurbelo/networkx,dmoliveira/networkx,aureooms/networkx,ionanrozenfeld/networkx,kernc/networkx,OrkoHunter/networkx,jfinkels/networkx,nathania/networkx,harlowja/networkx,blublud/networkx,kernc/networkx,aureooms/networkx,ionanrozenfeld/networkx,jni/networkx,Sixshaman/networkx,aureooms/networkx,jakevdp/networkx,dhimmel/networkx,RMKD/networkx,farhaanbukhsh/networkx,farhaanbukhsh/networkx,ghdk/networkx,jakevdp/networkx,bzero/networkx,debsankha/networkx,nathania/networkx,cmtm/networkx,jni/networkx,NvanAdrichem/networkx,dhimmel/networkx,blublud/networkx,JamesClough/networkx,bzero/networkx,blublud/networkx,ghdk/networkx,bzero/networkx,harlowja/networkx,SanketDG/networkx,nathania/networkx,dmoliveira/networkx,michaelpacer/networkx,chrisnatali/networkx,andnovar/networkx