mirror of
https://github.com/platformio/platformio-core.git
synced 2025-07-30 18:17:13 +02:00
PyLint fix for Python 3.12
This commit is contained in:
@ -223,6 +223,7 @@ def rmtree(path):
|
|||||||
err=True,
|
err=True,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# pylint: disable=unexpected-keyword-arg, deprecated-argument
|
||||||
if sys.version_info < (3, 12):
|
if sys.version_info < (3, 12):
|
||||||
return shutil.rmtree(path, onerror=_onexc)
|
return shutil.rmtree(path, onerror=_onexc)
|
||||||
return shutil.rmtree(path, onexc=_onexc) # pylint: disable=unexpected-keyword-arg
|
return shutil.rmtree(path, onexc=_onexc)
|
||||||
|
@ -654,7 +654,7 @@ def test_nested_interpolation(tmp_path: Path):
|
|||||||
"""
|
"""
|
||||||
[platformio]
|
[platformio]
|
||||||
build_dir = /tmp/pio-$PROJECT_HASH
|
build_dir = /tmp/pio-$PROJECT_HASH
|
||||||
data_dir = /$PROJECT_DIR/assets
|
data_dir = $PROJECT_DIR/assets
|
||||||
|
|
||||||
[env:myenv]
|
[env:myenv]
|
||||||
build_flags = -D UTIME=${UNIX_TIME}
|
build_flags = -D UTIME=${UNIX_TIME}
|
||||||
@ -668,7 +668,9 @@ test_testing_command =
|
|||||||
"""
|
"""
|
||||||
)
|
)
|
||||||
config = ProjectConfig(str(project_conf))
|
config = ProjectConfig(str(project_conf))
|
||||||
assert config.get("platformio", "data_dir") == "/$PROJECT_DIR/assets"
|
assert config.get("platformio", "data_dir").endswith(
|
||||||
|
os.path.join("$PROJECT_DIR", "assets")
|
||||||
|
)
|
||||||
assert config.get("env:myenv", "build_flags")[0][-10:].isdigit()
|
assert config.get("env:myenv", "build_flags")[0][-10:].isdigit()
|
||||||
testing_command = config.get("env:myenv", "test_testing_command")
|
testing_command = config.get("env:myenv", "test_testing_command")
|
||||||
assert "$" not in " ".join(testing_command)
|
assert "$" not in " ".join(testing_command)
|
||||||
|
Reference in New Issue
Block a user