관리-도구
편집 파일: core.cpython-39.pyc
a �)gC$ � @ sR d dl mZmZmZ eZd dlZd dlZd dl m Z mZ d dlm Z mZ d dlmZ d dlmZmZ d dlmZ d dlmZ d d lmZ zd d lmZ dZW n ey� dZY n0 e� Zd d� Z dd� Z!dd� Z"dd� Z#dd� Z$dd� Z%dd� Z&dd� Z'd/dd �Z(d!d"� Z)d0d#d$�Z*d1d%d�Z+d2d'd(�Z,d3d)d*�Z-d4d+d,�Z.G d-d.� d.e/�Z0dS )5� )�absolute_import�division�print_functionN)�MutableMapping�MutableSequence)�LooseVersion� StrictVersion��errors)� to_native�to_text)�boolean)�Display)�SemanticVersion)�VersionTFc C s t | t�st�d��| �dd�S )z# Test if task result yields failed z&The 'failed' test expects a dictionary�failedF�� isinstancer r �AnsibleFilterError�get��result� r �=/usr/lib/python3.9/site-packages/ansible/plugins/test/core.pyr , s r c C s t | � S )z$ Test if task result yields success )r r r r r �success3 s r c C s t | t�st�d��| �dd�S )z( Test if task result yields unreachable z+The 'unreachable' test expects a dictionary�unreachableFr r r r r r 8 s r c C s t | � S )z& Test if task result yields reachable )r r r r r � reachable? s r c C s| t | t�st�d��d| vrld}d| v rxt | d t�rxt | d d t�rx| d D ]}|�dd�rPd} qxqPn| �dd�}|S )z$ Test if task result yields changed z'The 'changed' test expects a dictionary�changedF�resultsr T)r r r r r r )r r �resr r r r D s ���r c C s t | t�st�d��| �dd�S )z$ Test if task result yields skipped z'The 'skipped' test expects a dictionary�skippedFr r r r r r X s r c C s>