summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorkennyballou <kballou@onyx.boisestate.edu>2013-04-02 23:13:05 -0600
committerkennyballou <kballou@onyx.boisestate.edu>2013-04-02 23:13:05 -0600
commit0c701766e66912f57374e077f863019ccd645c6f (patch)
tree537a776aaf26d96d43389cf39b57dbba61b0b095
parentbc411efd684f02253bc9e432082a087ccddaf8dd (diff)
downloadxnt-0c701766e66912f57374e077f863019ccd645c6f.tar.gz
xnt-0c701766e66912f57374e077f863019ccd645c6f.tar.xz
Do different tests based on OS
-rw-r--r--xnt/tests/taskmisctests.py10
1 files changed, 8 insertions, 2 deletions
diff --git a/xnt/tests/taskmisctests.py b/xnt/tests/taskmisctests.py
index bcabf3d..c20e24b 100644
--- a/xnt/tests/taskmisctests.py
+++ b/xnt/tests/taskmisctests.py
@@ -60,7 +60,10 @@ class TaskMiscTests(unittest.TestCase):
def test_which_finds_python(self):
"""Test which can find python"""
- path = xnt.tasks.which("python")
+ if os.name == 'posix':
+ path = xnt.tasks.which("python")
+ else:
+ path = xnt.tasks.which("python.exe")
self.assertIsNotNone(path)
def test_which_dne(self):
@@ -70,7 +73,10 @@ class TaskMiscTests(unittest.TestCase):
def test_python_in_path(self):
"""Test in_path task"""
- self.assertTrue(xnt.tasks.in_path("python"))
+ if os.name == 'posix':
+ self.assertTrue(xnt.tasks.in_path("python"))
+ else:
+ self.assertTrue(xnt.tasks.in_path("python.exe"))
def test_arst_not_in_path(self):
"""Test not in_path"""