Skip to content
Snippets Groups Projects
Commit 8d2f8c0d authored by Gregory Becker's avatar Gregory Becker
Browse files

flake

parent 16d6d8bf
Branches
Tags
No related merge requests found
...@@ -7,7 +7,6 @@ ...@@ -7,7 +7,6 @@
import shutil import shutil
import glob import glob
import tempfile import tempfile
import re
from contextlib import contextmanager from contextlib import contextmanager
import ruamel.yaml as yaml import ruamel.yaml as yaml
......
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
spack.schema.projections.properties, spack.schema.projections.properties,
), ),
}, },
{'type': 'string',} {'type': 'string'}
], ],
}, },
'install_hash_length': {'type': 'integer', 'minimum': 1}, 'install_hash_length': {'type': 'integer', 'minimum': 1},
......
...@@ -24,7 +24,6 @@ ...@@ -24,7 +24,6 @@
""" """
import os import os
import re
import six import six
import llnl.util.lang import llnl.util.lang
......
...@@ -68,8 +68,8 @@ def test_yaml_directory_layout_parameters(tmpdir, config): ...@@ -68,8 +68,8 @@ def test_yaml_directory_layout_parameters(tmpdir, config):
ns_scheme = "${ARCHITECTURE}/${NAMESPACE}/${PACKAGE}-${VERSION}-${HASH:7}" # NOQA: ignore=E501 ns_scheme = "${ARCHITECTURE}/${NAMESPACE}/${PACKAGE}-${VERSION}-${HASH:7}" # NOQA: ignore=E501
arch_ns_scheme_projections = {'all': arch_scheme, arch_ns_scheme_projections = {'all': arch_scheme,
'python': ns_scheme} 'python': ns_scheme}
layout_arch_ns = YamlDirectoryLayout(str(tmpdir), layout_arch_ns = YamlDirectoryLayout(
projections=arch_ns_scheme_projections) str(tmpdir), projections=arch_ns_scheme_projections)
arch_path_spec2 = layout_arch_ns.relative_path_for_spec(spec2) arch_path_spec2 = layout_arch_ns.relative_path_for_spec(spec2)
assert(arch_path_spec2 == spec2.format(arch_scheme)) assert(arch_path_spec2 == spec2.format(arch_scheme))
......
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
def get_config_line(pattern, lines): def get_config_line(pattern, lines):
"""Get a configuration line that matches a particular pattern.""" """Get a configuration line that matches a particular pattern."""
line = next((l for l in lines if re.search(pattern, l)), None) line = next((x for x in lines if re.search(pattern, x)), None)
assert line is not None, 'no such line!' assert line is not None, 'no such line!'
return line return line
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment