fix test code to work on rosbuild environment