open-rmf / rmf_traffic

Traffic management libraries for RMF
Apache License 2.0
28 stars 26 forks source link

Add a utility for calculating negotiations in a centralized way #66

Closed mxgrey closed 2 years ago

mxgrey commented 2 years ago

This PR introduces a utility with a stable public API for easily calculating a traffic negotiation with the standard "AGV" planner in a centralized way. This PR also replaces the use of the "NegotiationRoom" utility that the tests were using. The tests now use the CentralizedNegotiation tool, whose implementation was largely derived from NegotiationRoom.

codecov[bot] commented 2 years ago

Codecov Report

Merging #66 (54f8fb2) into main (b8cee0d) will increase coverage by 0.03%. The diff coverage is 13.30%.

@@            Coverage Diff             @@
##             main      #66      +/-   ##
==========================================
+ Coverage   22.12%   22.15%   +0.03%     
==========================================
  Files         357      359       +2     
  Lines       29171    29175       +4     
  Branches    13330    13302      -28     
==========================================
+ Hits         6453     6464      +11     
- Misses      13767    13806      +39     
+ Partials     8951     8905      -46     
Flag Coverage Δ
tests 22.15% <13.30%> (+0.03%) :arrow_up:

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...affic/include/rmf_traffic/agv/SimpleNegotiator.hpp 0.00% <ø> (ø)
...raffic/include/rmf_traffic/schedule/Negotiator.hpp 0.00% <ø> (ø)
...t/agv/planning/test_DifferentialDriveHeuristic.cpp 37.62% <ø> (ø)
rmf_traffic/test/unit/agv/test_Negotiator.cpp 10.82% <7.22%> (-1.94%) :arrow_down:
...affic/test/unit/agv/test_Negotiation_edgecases.cpp 6.82% <8.33%> (+0.32%) :arrow_up:
...fic/src/rmf_traffic/agv/CentralizedNegotiation.cpp 25.00% <25.00%> (ø)
...f_traffic/src/rmf_traffic/agv/SimpleNegotiator.cpp 34.97% <72.72%> (+7.79%) :arrow_up:
...mf_traffic/src/rmf_traffic/schedule/Negotiator.cpp 60.71% <72.72%> (-4.29%) :arrow_down:
...include/rmf_traffic/agv/CentralizedNegotiation.hpp 100.00% <100.00%> (ø)
... and 8 more