From 6c0242fcbb3a2e8e5ee9fa3a67a19e2efada37af Mon Sep 17 00:00:00 2001 From: 7000pctAUTO Date: Thu, 29 Jan 2026 21:28:07 +0000 Subject: [PATCH] Add remaining test files --- tests/test_validators/test_security.py | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 tests/test_validators/test_security.py diff --git a/tests/test_validators/test_security.py b/tests/test_validators/test_security.py new file mode 100644 index 0000000..2f7164d --- /dev/null +++ b/tests/test_validators/test_security.py @@ -0,0 +1,14 @@ +import pytest +from src.validators import SecurityValidator + +class TestSecurityValidator: + def setup_method(self): + self.validator = SecurityValidator() + + def test_detect_unquoted_variable(self): + findings = self.validator.check("cp $SRC_DIR $DEST_DIR") + assert len(findings) >= 1 + + def test_safe_quoted_variables(self): + findings = self.validator.check('cp "$SRC_DIR" "$DEST_DIR"') + assert len(findings) == 0