Skip to content

Commit

Permalink
fix(contol): fix the lat controller test bug
Browse files Browse the repository at this point in the history
  • Loading branch information
WildBeast114514 committed Apr 16, 2024
1 parent 0ac55bb commit 22cb4d8
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,10 @@ class LatControllerTest : public ::testing::Test, LatController {
const double linear_v, const double angular_v,
const double linear_a,
const TrajectoryAnalyzer &trajectory_analyzer,
SimpleLateralDebug *debug) {
SimpleLateralDebug *debug,
const canbus::Chassis *chassis) {
LatController::ComputeLateralErrors(x, y, theta, linear_v, angular_v,
linear_a, trajectory_analyzer, debug);
linear_a, trajectory_analyzer, debug, chassis);
}

protected:
Expand Down Expand Up @@ -104,7 +105,7 @@ TEST_F(LatControllerTest, ComputeLateralErrors) {
ComputeLateralErrors(
vehicle_state->x(), vehicle_state->y(), vehicle_state->heading(),
vehicle_state->linear_velocity(), vehicle_state->angular_velocity(),
vehicle_state->linear_acceleration(), trajectory_analyzer, debug);
vehicle_state->linear_acceleration(), trajectory_analyzer, debug, &chassis_pb);

double theta_error_expected = -0.03549;
double theta_error_dot_expected = 0.0044552856731;
Expand Down

0 comments on commit 22cb4d8

Please sign in to comment.