holy fuking shit
This commit is contained in:
@@ -97,7 +97,7 @@ class ProbeLadderGeometryTests(unittest.TestCase):
|
||||
loop.blocked_probes[7] = [blocked_point]
|
||||
return loop._next_probe(region, 7)
|
||||
|
||||
def test_antipode_reflects_blocked_probe_through_center(self):
|
||||
def test_antipode_reflects_blocked_probe_in_center(self):
|
||||
"""圆心为原点、原探点 (200,0):对跖复核应返回 (-200,0)。"""
|
||||
region = CandidateRegion.disk((0.0, 0.0), 100.0, 192) # safe≈900>=200
|
||||
probe = self._probe_after_block(region, (200.0, 0.0))
|
||||
@@ -113,7 +113,7 @@ class ProbeLadderGeometryTests(unittest.TestCase):
|
||||
self.assertAlmostEqual(math.hypot(probe[0], probe[1]), safe, places=6)
|
||||
self.assertLess(probe[0], 0.0, "应位于原探点的对跖方向")
|
||||
|
||||
def test_degenerate_center_block_walks_full_safe_radius(self):
|
||||
def test_degenerate_center_block_walks_safe_radius(self):
|
||||
"""被遮挡探点恰在圆心:沿 +x 走满安全盘半径,不再钳到 1m。"""
|
||||
region = CandidateRegion.disk((0.0, 0.0), 100.0, 192)
|
||||
probe = self._probe_after_block(region, (0.0, 0.0))
|
||||
@@ -125,7 +125,7 @@ class ProbeLadderGeometryTests(unittest.TestCase):
|
||||
class MixedLoopAcceptanceTests(unittest.TestCase):
|
||||
def test_mixed_ten_sources_all_cleared(self):
|
||||
sources = mixed_scene(seed=5, count=10, directional=3)
|
||||
summary, report, simulator, _, loop = _run_scene(sources)
|
||||
summary, report, simulator, _, _ = _run_scene(sources)
|
||||
truth = sorted(s.channel for s in sources)
|
||||
self.assertTrue(summary["completed"])
|
||||
self.assertEqual(summary["stop_reason"], "all_resolved")
|
||||
@@ -155,7 +155,7 @@ class MixedLoopAcceptanceTests(unittest.TestCase):
|
||||
self.assertEqual(sorted(simulator.cleared), truth)
|
||||
self.assertEqual(report["mismatches"], [])
|
||||
|
||||
def test_outward_boundary_directional_source_not_missed(self):
|
||||
def test_outward_boundary_directional_not_missed(self):
|
||||
"""朝向背离圆心、r_eff=1000 的近边界源:覆盖保证仍发现并清除。"""
|
||||
source = Source(channel=7, x=1790.0, y=0.0, r_eff_m=1000.0,
|
||||
directional=True, heading_deg=0.0)
|
||||
@@ -169,8 +169,8 @@ class MixedLoopAcceptanceTests(unittest.TestCase):
|
||||
"""固定批量种子回归:任何种子下不得全清失败或破坏守恒性。"""
|
||||
for seed in range(5, 10):
|
||||
sources = mixed_scene(seed=seed, count=10, directional=4)
|
||||
summary, report, simulator, _, _ = _run_scene(sources,
|
||||
config=SMALL_CAP)
|
||||
summary, report, _, _, _ = _run_scene(sources,
|
||||
config=SMALL_CAP)
|
||||
truth = sorted(s.channel for s in sources)
|
||||
self.assertTrue(summary["completed"], f"seed={seed}")
|
||||
self.assertEqual(sorted(summary["cleared_channels"]), truth,
|
||||
@@ -194,7 +194,7 @@ class JointConstraintBaselineTests(unittest.TestCase):
|
||||
for witness in region.witnesses(300.0):
|
||||
self.assertTrue(region.contains(witness, tol_m=0.05))
|
||||
|
||||
def test_directional_source_retained_through_blocked_probes(self):
|
||||
def test_directional_source_kept_after_blocked_probes(self):
|
||||
"""端到端保留性:定向源被遮挡若干次后仍被清除,不因 no_signal 误删。"""
|
||||
source = Source(channel=3, x=600.0, y=800.0, r_eff_m=1500.0,
|
||||
directional=True, heading_deg=200.0)
|
||||
@@ -261,7 +261,7 @@ class FallbackDisciplineTests(unittest.TestCase):
|
||||
cells = fallback_clear_cells(region.polygon, CONFIG)
|
||||
self.assertLessEqual(len(cells), CONFIG.search.fallback_max_cells)
|
||||
|
||||
def test_fallback_exhaustion_records_anomaly_without_deletion(self):
|
||||
def test_fallback_exhaustion_records_anomaly(self):
|
||||
"""后备全失败(空域):守恒性异常留痕,且不删除空间候选。"""
|
||||
simulator = LocalSimulator([], robot_id="T001", config=CONFIG)
|
||||
client = SimulatorClient("T001", config=CONFIG,
|
||||
|
||||
Reference in New Issue
Block a user