test for segment