Create localizer log replay test
This creates a log replay test that confirms that the localizer can
sanely handle a situation where the drivebase's wheels are spinning. I
used the logfile when working on integrating the IMU into the EKF, and
figured it would be appropriate to test for regressions...
Change-Id: Ib7d5c5412d9e404e165ca99df41940235564b86e
diff --git a/y2020/control_loops/drivetrain/BUILD b/y2020/control_loops/drivetrain/BUILD
index 41c6d81..de669d6 100644
--- a/y2020/control_loops/drivetrain/BUILD
+++ b/y2020/control_loops/drivetrain/BUILD
@@ -125,6 +125,27 @@
],
)
+cc_test(
+ name = "drivetrain_replay_test",
+ srcs = ["drivetrain_replay_test.cc"],
+ data = [
+ "//y2020:config.json",
+ "@drivetrain_replay//file:spinning_wheels_while_still.bfbs",
+ ],
+ deps = [
+ ":drivetrain_base",
+ "//aos:configuration",
+ "//aos:init",
+ "//aos/events:shm_event_loop",
+ "//aos/events:simulated_event_loop",
+ "//aos/events/logging:logger",
+ "//aos/testing:googletest",
+ "//frc971/control_loops/drivetrain:drivetrain_lib",
+ "@com_github_gflags_gflags//:gflags",
+ "@com_github_google_glog//:glog",
+ ],
+)
+
cc_binary(
name = "drivetrain_replay",
srcs = ["drivetrain_replay.cc"],