test/config.py: fix import issues (#35076)
This commit is contained in:
parent
8d0cbb9812
commit
918bb63c3a
@ -17,6 +17,7 @@
|
||||
from llnl.util.filesystem import getuid, join_path, mkdirp, touch, touchp
|
||||
|
||||
import spack.config
|
||||
import spack.directory_layout
|
||||
import spack.environment as ev
|
||||
import spack.main
|
||||
import spack.package_base
|
||||
@ -28,6 +29,7 @@
|
||||
import spack.schema.mirrors
|
||||
import spack.schema.packages
|
||||
import spack.schema.repos
|
||||
import spack.store
|
||||
import spack.util.path as spack_path
|
||||
import spack.util.spack_yaml as syaml
|
||||
|
||||
@ -451,9 +453,9 @@ def test_substitute_date(mock_low_high_config):
|
||||
assert date.today().strftime("%Y-%m-%d") in new_path
|
||||
|
||||
|
||||
PAD_STRING = spack.util.path.SPACK_PATH_PADDING_CHARS
|
||||
MAX_PATH_LEN = spack.util.path.get_system_path_max()
|
||||
MAX_PADDED_LEN = MAX_PATH_LEN - spack.util.path.SPACK_MAX_INSTALL_PATH_LENGTH
|
||||
PAD_STRING = spack_path.SPACK_PATH_PADDING_CHARS
|
||||
MAX_PATH_LEN = spack_path.get_system_path_max()
|
||||
MAX_PADDED_LEN = MAX_PATH_LEN - spack_path.SPACK_MAX_INSTALL_PATH_LENGTH
|
||||
reps = [PAD_STRING for _ in range((MAX_PADDED_LEN // len(PAD_STRING) + 1) + 2)]
|
||||
full_padded_string = os.path.join(os.sep + "path", os.sep.join(reps))[:MAX_PADDED_LEN]
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user