diff options
author | Alon Zakai <alonzakai@gmail.com> | 2011-10-05 10:50:13 -0700 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2011-10-05 10:50:13 -0700 |
commit | f7bab2b692cfa4cdf33185c123404848c268d02b (patch) | |
tree | 43524d9459b0aa7dd7ace27b59f7cb8dda072da9 | |
parent | 526f43d34325b01845bb98d379ff02b46b942e35 (diff) |
fix bug with path creation
-rw-r--r-- | tests/runner.py | 4 | ||||
-rw-r--r-- | tools/shared.py | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/tests/runner.py b/tests/runner.py index 91f40c56..3f26dd0f 100644 --- a/tests/runner.py +++ b/tests/runner.py @@ -9,9 +9,9 @@ import os, unittest, tempfile, shutil, time, inspect, sys, math, glob, tempfile, # Setup +__rootpath__ = os.path.abspath(os.path.dirname(os.path.dirname(__file__))) def path_from_root(*pathelems): - rootpath = os.path.abspath(os.path.dirname(os.path.dirname(__file__))) - return os.path.join(rootpath, *pathelems) + return os.path.join(__rootpath__, *pathelems) exec(open(path_from_root('tools', 'shared.py'), 'r').read()) # Sanity check for config diff --git a/tools/shared.py b/tools/shared.py index 86569e73..ae1ca94b 100644 --- a/tools/shared.py +++ b/tools/shared.py @@ -1,9 +1,9 @@ import shutil, time, os from subprocess import Popen, PIPE, STDOUT +__rootpath__ = os.path.abspath(os.path.dirname(os.path.dirname(__file__))) def path_from_root(*pathelems): - rootpath = os.path.abspath(os.path.dirname(os.path.dirname(__file__))) - return os.path.join(rootpath, *pathelems) + return os.path.join(__rootpath__, *pathelems) CONFIG_FILE = os.path.expanduser('~/.emscripten') if not os.path.exists(CONFIG_FILE): |