From f2f52996d4bb0bca748f09032ca70c7203e97675 Mon Sep 17 00:00:00 2001 From: Henrik Levkowetz Date: Fri, 29 Jun 2007 16:05:14 +0000 Subject: [PATCH] Make it configurable which host (and path prefix) we'll use to retrieve legacy page content for diff testing. Add a setting in settings.py pointing to http://compost.research.att.com/old/. - Legacy-Id: 767 --- ietf/settings.py | 2 ++ ietf/tests.py | 2 ++ 2 files changed, 4 insertions(+) diff --git a/ietf/settings.py b/ietf/settings.py index aa69d2b11..764a3f7c1 100644 --- a/ietf/settings.py +++ b/ietf/settings.py @@ -157,6 +157,8 @@ TEST_RUNNER = 'ietf.tests.run_tests' IPR_DOCUMENT_PATH = '/home/master-site/ftp/data/ietf/IPR' +TEST_REFERENCE_URL_PREFIX = 'http://compost.research.att.com/old/' + # Put SECRET_KEY in here, or any other sensitive or site-specific # changes. DO NOT commit settings_local.py to svn. from settings_local import * diff --git a/ietf/tests.py b/ietf/tests.py index d7dc0bec9..6cbef3403 100644 --- a/ietf/tests.py +++ b/ietf/tests.py @@ -90,6 +90,8 @@ def read_testurls(filename): goodurl = None elif len(urlspec) == 3: codes, testurl, goodurl = urlspec + # strip protocol and host -- we're making that configurable + goodurl = re.sub("^https?://[a-z0-9.]/", "", goodurl) else: raise ValueError("Expected 'HTTP_CODE TESTURL [GOODURL]' in %s line, found '%s'." % (filename, line))