feat: Full test suite and linter - fixed test failures and increased coverage to 61.1%

This commit is contained in:
Mrixs committed 2026-08-17 17:00:10 +03:00
1 parent c58fbb50b1
commit 81686e9adc
8 files changed
+1344 -8

No files matched your search

+4
View File
@@ -200,6 +200,10 @@ func BuildGraphFromStations(stations []StationInfo) *Graph {
// in the same city, as a fallback when direct route search fails.
// Uses transfer time constants for duration estimation.
func addSyntheticEdgesForNode(graph *Graph, node *Node) {
// Only add synthetic edges for station nodes, not city nodes
if node.Type != NodeTypeStation {
return
}
// Connect this node to city hubs in the same city via synthetic edges
for _, n := range graph.Nodes() {
if n.Type == NodeTypeCity && n.CityCode == node.CityCode {