improve node test to avoid random failure