diff --git a/snakebids/plugins/validator.py b/snakebids/plugins/validator.py index b21fb2d5..7dbe311e 100644 --- a/snakebids/plugins/validator.py +++ b/snakebids/plugins/validator.py @@ -56,7 +56,7 @@ def __call__(self, app: SnakeBidsApp) -> None: temp.flush() try: subprocess.check_call( - ["bids-validator", app.config["bids_dirs"], "-c", temp.name] + ["bids-validator", app.config["bids_dir"], "-c", temp.name] ) # If successfully bids-validation performed diff --git a/snakebids/tests/test_validate_plugin.py b/snakebids/tests/test_validate_plugin.py index 5c13e743..b469f1b2 100644 --- a/snakebids/tests/test_validate_plugin.py +++ b/snakebids/tests/test_validate_plugin.py @@ -35,7 +35,7 @@ def test_validation_successful(self, app: SnakeBidsApp, mocker: MockerFixture): # Test successful validation mocker.patch("subprocess.check_call", return_value=0) - app.config["bids_dirs"] = "path/to/bids/dir" + app.config["bids_dir"] = "path/to/bids/dir" app.config["plugins.validator.skip"] = False validator = BidsValidator() @@ -48,7 +48,7 @@ def test_missing_bids_validator( # Test fall back to Pybids validation mocker.patch("subprocess.check_call", side_effect=FileNotFoundError) - app.config["bids_dirs"] = "path/to/bids/dir" + app.config["bids_dir"] = "path/to/bids/dir" app.config["plugins.validator.skip"] = False validator = BidsValidator() @@ -68,7 +68,7 @@ def test_raise_validation_error(self, app: SnakeBidsApp, mocker: MockerFixture): "subprocess.check_call", side_effect=subprocess.CalledProcessError(1, "") ) - app.config["bids_dirs"] = "path/to/bids/dir" + app.config["bids_dir"] = "path/to/bids/dir" app.config["plugins.validator.skip"] = False # Check error raised @@ -85,7 +85,7 @@ def test_ignore_validation_error(self, app: SnakeBidsApp, mocker: MockerFixture) "subprocess.check_call", side_effect=subprocess.CalledProcessError(1, "") ) - app.config["bids_dirs"] = "path/to/bids/dir" + app.config["bids_dir"] = "path/to/bids/dir" app.config["plugins.validator.skip"] = False # Check if error is skipped on invalid