OverviewFilesCommitsIssuesDocsReleasesPeers

hyperswarm-peer commits / d5c4bda

test: four gates the build script never built
test_compact_encoding, test_phase3, test_dht_godot_style and test_live_lookup had no target in build_tests.sh. Their binaries were from February; the sources kept moving. Running ./test_compact_encoding therefore measured a build from another era, and it reported 53/53 for a source file that today has 52 checks in it — the number was real and about nothing. This is §5 of hyper-games #17 reached by a second road. That one was a half-updated object cache; this one is a target the script simply never had. The guard added then (refuse to link objects older than the newest header) cannot see a file it is not asked to build. A gate the build does not rebuild is not a gate. All four compile and pass against today's source: phase3 100/100, dht_godot_style and live_lookup green against the local testnet. Also moved the "All test binaries built successfully" line to the end. It sat four targets from the bottom and announced success while four more were still to come — a build that failed in that tail printed the banner first. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
d5c4bda857a0a1b6fdfb41886fe93d10d2af173f
by plankatron <fleeky@gmail.com> · 2026-09-10T18:53:13.000Z

Changed files (4) +38 -1

test/build_tests.sh +38 -1
……@@ -243,7 +243,6 @@ g++ -o test_handshake_pool \
243243 $OBJ/noise_stream.o $OBJ/dht_rpc.o $OBJ/holepuncher.o $OBJ/hyperdht.o \
244244 $UDX_OBJS $LDFLAGS
245245echo " OK: test_handshake_pool"
246echo "=== All test binaries built successfully ==="
247246
248247# ---- test_find_peer_exhausted ----
249248# A connect attempt must fail when find_peer EXHAUSTS, not 30s later. See
……@@ -289,3 +288,41 @@ g++ -o test_self_announce_live \
289288 $OBJ/noise_stream.o $OBJ/dht_rpc.o $OBJ/holepuncher.o $OBJ/hyperdht.o \
290289 $UDX_OBJS $LDFLAGS
291290echo " OK: test_self_announce_live"
291
292# ---- test_compact_encoding ----
293# ⛔ THESE FOUR WERE NOT IN THIS SCRIPT. Their binaries sat on disk from
294# February while the sources moved under them, so running ./test_compact_encoding
295# measured a build from another era — the exact trap §5 of hyper-games #17
296# describes, reached a second way: not a half-updated object cache, but a target
297# the script never had. A gate the build does not rebuild is not a gate.
298echo "Building test_compact_encoding..."
299g++ $CXXFLAGS -o $OBJ/test_compact_encoding.o test_compact_encoding.cpp
300g++ -o test_compact_encoding $OBJ/test_compact_encoding.o $UDX_OBJS $LDFLAGS
301echo " OK: test_compact_encoding"
302
303# ---- test_phase3 ----
304echo "Building test_phase3..."
305g++ $CXXFLAGS -o $OBJ/test_phase3.o test_phase3.cpp
306g++ -o test_phase3 $OBJ/test_phase3.o $OBJ/noise_ik.o $UDX_OBJS $LDFLAGS
307echo " OK: test_phase3"
308
309# ---- test_dht_godot_style ----
310echo "Building test_dht_godot_style..."
311g++ $CXXFLAGS -o $OBJ/test_dht_godot_style.o test_dht_godot_style.cpp
312g++ -o test_dht_godot_style \
313 $OBJ/test_dht_godot_style.o $OBJ/noise_ik.o $OBJ/dht_rpc.o \
314 $OBJ/holepuncher.o $OBJ/hyperdht.o $OBJ/dht_connector.o \
315 $UDX_OBJS $LDFLAGS
316echo " OK: test_dht_godot_style"
317
318# ---- test_live_lookup ----
319# Needs a real DHT: it looks a key up for real. Built here so it cannot rot.
320echo "Building test_live_lookup..."
321g++ $CXXFLAGS -o $OBJ/test_live_lookup.o test_live_lookup.cpp
322g++ -o test_live_lookup \
323 $OBJ/test_live_lookup.o $OBJ/noise_ik.o $OBJ/dht_rpc.o \
324 $OBJ/holepuncher.o $OBJ/hyperdht.o $OBJ/dht_connector.o \
325 $UDX_OBJS $LDFLAGS
326echo " OK: test_live_lookup"
327
328echo "=== All test binaries built successfully ==="
test/test_dht_godot_style +0 -0
(no content changes — binary or rename)
test/test_live_lookup +0 -0
(no content changes — binary or rename)
test/test_phase3 +0 -0
(no content changes — binary or rename)