Avoid mocking of segment in test