930 B
930 B
Tests
Go package tests
go test ./...
internal/config— YAML load/save, listen bind rules, URL redactioninternal/logger— token/password redactioninternal/tunnel— HTTP client + Navicat magic-header sniffinternal/navicat— GetBlock/header parser, actn=C/Q client, mockntunnel_mysql.phpinternal/mysqlserver— handshake, mysql_native_password, COM_QUERY/PING/QUIT, ResultSet; official Go MySQL driver against the local server
Go tests do not hit the live tunnel.
Python: 与影刀同一用法
rpa_tunnel.py 即影刀流程写法(硬编码,不读 yaml),main 返回 args["conn"]。
python tests\rpa_tunnel.py
须先启动 mysql-tunnel.exe,listen / local_auth 与脚本里 host/port/user/password 一致。
完整探测(读 config.yaml、多条 SQL、可选 --direct)见 http_tunnel.py。