[Python-checkins] cpython: Remove sys.platform == 'riscos' checks from some Python and test files. #16501

christian.heimes python-checkins at python.org
Mon Nov 19 01:00:15 CET 2012


http://hg.python.org/cpython/rev/6b74a93a2b8a
changeset:   80524:6b74a93a2b8a
user:        Christian Heimes <christian at cheimes.de>
date:        Mon Nov 19 00:59:39 2012 +0100
summary:
  Remove sys.platform == 'riscos' checks from some Python and test files. #16501

files:
  Lib/site.py                    |  4 +---
  Lib/sysconfig.py               |  1 -
  Lib/test/test_select.py        |  2 +-
  Lib/test/test_signal.py        |  3 ---
  Lib/test/test_site.py          |  6 +-----
  Lib/test/test_threadsignals.py |  2 +-
  6 files changed, 4 insertions(+), 14 deletions(-)


diff --git a/Lib/site.py b/Lib/site.py
--- a/Lib/site.py
+++ b/Lib/site.py
@@ -300,9 +300,7 @@
             continue
         seen.add(prefix)
 
-        if sys.platform == 'riscos':
-            sitepackages.append(os.path.join(prefix, "Lib", "site-packages"))
-        elif os.sep == '/':
+        if os.sep == '/':
             sitepackages.append(os.path.join(prefix, "lib",
                                         "python" + sys.version[:3],
                                         "site-packages"))
diff --git a/Lib/sysconfig.py b/Lib/sysconfig.py
--- a/Lib/sysconfig.py
+++ b/Lib/sysconfig.py
@@ -191,7 +191,6 @@
     def joinuser(*args):
         return os.path.expanduser(os.path.join(*args))
 
-    # what about 'riscos' ?
     if os.name == "nt":
         base = os.environ.get("APPDATA") or "~"
         if env_base:
diff --git a/Lib/test/test_select.py b/Lib/test/test_select.py
--- a/Lib/test/test_select.py
+++ b/Lib/test/test_select.py
@@ -5,7 +5,7 @@
 import unittest
 from test import support
 
- at unittest.skipIf((sys.platform[:3]=='win') or (sys.platform=='riscos'),
+ at unittest.skipIf((sys.platform[:3]=='win'),
                  "can't easily test on this system")
 class SelectTestCase(unittest.TestCase):
 
diff --git a/Lib/test/test_signal.py b/Lib/test/test_signal.py
--- a/Lib/test/test_signal.py
+++ b/Lib/test/test_signal.py
@@ -15,9 +15,6 @@
 except ImportError:
     threading = None
 
-if sys.platform == 'riscos':
-    raise unittest.SkipTest("Can't test signal on %s" % sys.platform)
-
 
 class HandlerBCalled(Exception):
     pass
diff --git a/Lib/test/test_site.py b/Lib/test/test_site.py
--- a/Lib/test/test_site.py
+++ b/Lib/test/test_site.py
@@ -222,11 +222,7 @@
         site.PREFIXES = ['xoxo']
         dirs = site.getsitepackages()
 
-        if sys.platform == 'riscos':
-            self.assertEqual(len(dirs), 1)
-            wanted = os.path.join('xoxo', 'Lib', 'site-packages')
-            self.assertEqual(dirs[0], wanted)
-        elif (sys.platform == "darwin" and
+        if (sys.platform == "darwin" and
             sysconfig.get_config_var("PYTHONFRAMEWORK")):
             # OS X framework builds
             site.PREFIXES = ['Python.framework']
diff --git a/Lib/test/test_threadsignals.py b/Lib/test/test_threadsignals.py
--- a/Lib/test/test_threadsignals.py
+++ b/Lib/test/test_threadsignals.py
@@ -8,7 +8,7 @@
 thread = import_module('_thread')
 import time
 
-if (sys.platform[:3] == 'win') or (sys.platform=='riscos'):
+if (sys.platform[:3] == 'win'):
     raise unittest.SkipTest("Can't test signal on %s" % sys.platform)
 
 process_pid = os.getpid()

-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list