Replace hypothesis with random-based fuzzing#3192
Replace hypothesis with random-based fuzzing#3192adeebshihadeh wants to merge 2 commits intomasterfrom
Conversation
Remove hypothesis dependency. Replace with simple os.urandom/random based fuzzing that provides equivalent coverage 17-50% faster. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Car behavior reportReplays driving segments through this PR and compares the behavior to master. Testing 541 segments for: FORD_BRONCO_SPORT_MK1, FORD_ESCAPE_MK4, FORD_ESCAPE_MK4_5, FORD_EXPLORER_MK6, FORD_F_150_MK14, FORD_F_150_LIGHTNING_MK1, FORD_FOCUS_MK4, FORD_MAVERICK_MK1, FORD_MUSTANG_MACH_E_MK1, FORD_RANGER_MK2, HYUNDAI_AZERA_HEV_6TH_GEN, HYUNDAI_ELANTRA_GT_I30, HYUNDAI_ELANTRA_2021, HYUNDAI_ELANTRA_HEV_2021, HYUNDAI_GENESIS, HYUNDAI_IONIQ, HYUNDAI_IONIQ_HEV_2022, HYUNDAI_IONIQ_EV_2020, HYUNDAI_IONIQ_PHEV_2019, HYUNDAI_IONIQ_PHEV, HYUNDAI_KONA_2022, HYUNDAI_KONA_EV, HYUNDAI_KONA_EV_2022, HYUNDAI_KONA_EV_2ND_GEN, HYUNDAI_SANTA_FE, HYUNDAI_SANTA_FE_2022, HYUNDAI_SANTA_FE_HEV_2022, HYUNDAI_SANTA_FE_PHEV_2022, HYUNDAI_SONATA, HYUNDAI_SONATA_LF, HYUNDAI_STARIA_4TH_GEN, HYUNDAI_PALISADE, HYUNDAI_SONATA_HYBRID, HYUNDAI_IONIQ_5, HYUNDAI_IONIQ_6, HYUNDAI_TUCSON_4TH_GEN, HYUNDAI_SANTA_CRUZ_1ST_GEN, HYUNDAI_CUSTIN_1ST_GEN, TOYOTA_ALPHARD_TSS2, TOYOTA_AVALON, TOYOTA_AVALON_2019, TOYOTA_AVALON_TSS2, TOYOTA_CAMRY, TOYOTA_CAMRY_TSS2, TOYOTA_CHR, TOYOTA_CHR_TSS2, TOYOTA_COROLLA, TOYOTA_COROLLA_TSS2, TOYOTA_HIGHLANDER, TOYOTA_HIGHLANDER_TSS2, TOYOTA_PRIUS, TOYOTA_PRIUS_V, TOYOTA_PRIUS_TSS2, TOYOTA_RAV4, TOYOTA_RAV4H, TOYOTA_RAV4_TSS2, TOYOTA_RAV4_TSS2_2022, TOYOTA_RAV4_TSS2_2023, TOYOTA_RAV4_PRIME, TOYOTA_YARIS, TOYOTA_MIRAI, TOYOTA_SIENNA, TOYOTA_SIENNA_4TH_GEN ✅ 0 changed, 541 passed, 0 errors |
Summary
hypothesisdependencyos.urandom/randombased fuzzing (same coverage, no framework overhead)test_toyota.pyto unittest.TestCaseLocal benchmarks
Coverage
hypothesis generates random data with shrinking (finds minimal failing inputs). Our replacement generates purely random data without shrinking. Since these tests validate sanity bounds (mass > 1, wheelbase > 0) rather than edge cases, shrinking adds no practical value — a random failure is just as informative. The fuzzy FW tests just assert "no crash on random input" where shrinking is meaningless.
🤖 Generated with Claude Code