File: uri_list-test-requires-network-access.patch

package info (click to toggle)
spamassassin 4.0.2-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 22,988 kB
  • sloc: perl: 88,863; ansic: 5,193; sh: 3,737; javascript: 339; sql: 295; makefile: 209; python: 49
file content (35 lines) | stat: -rw-r--r-- 1,091 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
From 54be119e40be07478a95a794844e229bc6f906fd Mon Sep 17 00:00:00 2001
From: Giovanni Bechis <gbechis@apache.org>
Date: Fri, 5 Sep 2025 07:55:30 +0000
Subject: [PATCH] uri_list test requires network access

git-svn-id: https://svn.apache.org/repos/asf/spamassassin/trunk@1928242 13f79535-47bb-0310-9956-ffa450edef68
---
 t/uri_list.t | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/t/uri_list.t b/t/uri_list.t
index b01c5bf6a7..0b5df4f56c 100755
--- a/t/uri_list.t
+++ b/t/uri_list.t
@@ -4,13 +4,18 @@
 # The real root cause is obscure, so we test for the bug not the Perl version.
 
 use strict;
+use warnings;
+
 use lib '.'; use lib 't';
 use SATest; sa_t_init("uri_list");
-use Test::More tests=> 12;
 use Mail::SpamAssassin::Util;
-use warnings;
 use Cwd;
 
+use Test::More;
+plan skip_all => "Net tests disabled"          unless conf_bool('run_net_tests');
+plan skip_all => "Can't use Net::DNS Safely"   unless can_use_net_dns_safely();
+plan tests=> 12;
+
 my $twoplus = <<'EOT';
 Message-ID: <clean.1010101@x.com>
 Date: Mon, 07 Oct 2002 09:00:00 +0000