summaryrefslogtreecommitdiffstats
path: root/test/TestAnsibleSyntax.py
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--test/TestAnsibleSyntax.py16
1 files changed, 16 insertions, 0 deletions
diff --git a/test/TestAnsibleSyntax.py b/test/TestAnsibleSyntax.py
new file mode 100644
index 0000000..8103b61
--- /dev/null
+++ b/test/TestAnsibleSyntax.py
@@ -0,0 +1,16 @@
+"""Test Ansible Syntax.
+
+This module contains tests that validate that linter does not produce errors
+when encountering what counts as valid Ansible syntax.
+"""
+
+PB_WITH_NULL_TASKS = '''
+- hosts: all
+ tasks:
+'''
+
+
+def test_null_tasks(default_text_runner):
+ """Assure we do not fail when encountering null tasks."""
+ results = default_text_runner.run_playbook(PB_WITH_NULL_TASKS)
+ assert not results