add regression test for issue 1876
change assert_ to assert_equal
Merge pull request #484 from jakevdp/csgraph1876_test

TST: sparse.csgraph: add regression test for issue 1876