Browse Source

Use path2posix everywhere

pull/142/head
Oliverpool 9 years ago
parent
commit
7361f83645
  1. 7
      test/test_compilation/test_compilation.py

7
test/test_compilation/test_compilation.py

@ -10,6 +10,7 @@ import unittest
import logging
from patacrep.encoding import open_read
from patacrep.files import path2posix
from .. import dynamic # pylint: disable=unused-import
@ -67,16 +68,18 @@ class FileTest(unittest.TestCase, metaclass=dynamic.DynamicTest):
expected = expectfile.read().strip()
expected = expected.replace(
"@TEST_FOLDER@",
os.path.dirname(__file__),
path2posix(os.path.dirname(__file__)),
)
expected = expected.replace(
"@DATA_FOLDER@",
path2posix(
subprocess.check_output(
[sys.executable, "-c", 'import patacrep, pkg_resources; print(pkg_resources.resource_filename(patacrep.__name__, "data"))'], # pylint: disable=line-too-long
universal_newlines=True,
cwd=os.path.dirname(songbook),
).strip(),
).strip()
),
)
self.assertMultiLineEqual(

Loading…
Cancel
Save