Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(autoware_test_utils): set timestamp in building trajectory msg #245

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -374,6 +374,7 @@
using Point = typename T::_points_type::value_type;

T traj;
traj.header.stamp = rclcpp::Clock{RCL_ROS_TIME}.now();

Check warning on line 377 in testing/autoware_test_utils/include/autoware_test_utils/autoware_test_utils.hpp

View check run for this annotation

Codecov / codecov/patch

testing/autoware_test_utils/include/autoware_test_utils/autoware_test_utils.hpp#L377

Added line #L377 was not covered by tests
for (size_t i = 0; i < num_points; ++i) {
const double theta = init_theta + static_cast<double>(i) * delta_theta;
const double x = static_cast<double>(i) * point_interval * std::cos(theta);
Expand All @@ -399,6 +400,7 @@
const double init_theta, const double delta_theta, const size_t overlapping_point_index)
{
PathWithLaneId traj;
traj.header.stamp = rclcpp::Clock{RCL_ROS_TIME}.now();

for (size_t i = 0; i < num_points; i++) {
const double theta = init_theta + static_cast<double>(i) * delta_theta;
Expand Down
Loading