From 84db310736c278f97dc439431c6a317c6c35618c Mon Sep 17 00:00:00 2001 From: Matt Simerson Date: Tue, 11 Nov 2014 02:02:21 -0500 Subject: [PATCH] geoip: don't run ASN tests if ASN db didn't load --- t/plugin_tests/ident/geoip | 2 ++ 1 file changed, 2 insertions(+) diff --git a/t/plugin_tests/ident/geoip b/t/plugin_tests/ident/geoip index 43392fd..56e0b38 100644 --- a/t/plugin_tests/ident/geoip +++ b/t/plugin_tests/ident/geoip @@ -169,6 +169,8 @@ sub test_set_distance { sub test_set_asn { my $self = shift; + return if !$self->{GeoIPASNum}; + $self->qp->connection->remote_ip(''); $self->set_asn(); my $asn = $self->set_asn();