( t *testing.T, mapper *addressRewriteMapper, candidateType CandidateType, localIP string, )
| 842 | } |
| 843 | |
| 844 | func requireFirstExternalIP( |
| 845 | t *testing.T, |
| 846 | mapper *addressRewriteMapper, |
| 847 | candidateType CandidateType, |
| 848 | localIP string, |
| 849 | ) net.IP { |
| 850 | t.Helper() |
| 851 | |
| 852 | ips, matched, _, err := mapper.findExternalIPs(candidateType, localIP, "") |
| 853 | require.NoError(t, err) |
| 854 | require.True(t, matched) |
| 855 | require.NotEmpty(t, ips) |
| 856 | |
| 857 | return ips[0] |
| 858 | } |
| 859 | |
| 860 | func requireFirstMappingIP(t *testing.T, mapping *ipMapping, localIP net.IP) net.IP { |
| 861 | t.Helper() |
no test coverage detected
searching dependent graphs…