A nonparametric test for the comparison of first-order structures of spatial point processes