diff options
author | Abhijeet Kasurde <akasurde@redhat.com> | 2020-07-21 19:47:11 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-07-21 19:47:11 +0200 |
commit | 4f96f9826c38e008112a45599a3550dc3cc98b07 (patch) | |
tree | 825b9efc71e2f0ba0c39f3f78f96174cb6bf8c14 /hacking/tests | |
parent | runtime os_image_facts is now called os_image_info (#70776) (diff) | |
download | ansible-4f96f9826c38e008112a45599a3550dc3cc98b07.tar.xz ansible-4f96f9826c38e008112a45599a3550dc3cc98b07.zip |
distribution: Add support for DragonFly (#70748)
partially fixes #43739
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
Diffstat (limited to 'hacking/tests')
-rwxr-xr-x | hacking/tests/gen_distribution_version_testcase.py | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/hacking/tests/gen_distribution_version_testcase.py b/hacking/tests/gen_distribution_version_testcase.py index 39c0a2fc2c..a1573bfc52 100755 --- a/hacking/tests/gen_distribution_version_testcase.py +++ b/hacking/tests/gen_distribution_version_testcase.py @@ -12,9 +12,10 @@ This assumes a working ansible version in the path. from __future__ import (absolute_import, division, print_function) __metaclass__ = type +import json import os.path +import platform import subprocess -import json import sys from ansible.module_utils import distro @@ -91,4 +92,12 @@ output = { 'result': ansible_facts, } +system = platform.system() +if system != 'Linux': + output['platform.system'] = system + +release = platform.release() +if release: + output['platform.release'] = release + print(json.dumps(output, indent=4)) |