"""
    FreeClimb API

    FreeClimb is a cloud-based application programming interface (API) that puts the power of the Vail platform in your hands. FreeClimb simplifies the process of creating applications that can use a full range of telephony features without requiring specialized or on-site telephony equipment. Using the FreeClimb REST API to write applications is easy! You have the option to use the language of your choice or hit the API directly. Your application can execute a command by issuing a RESTful request to the FreeClimb API. The base URL to send HTTP requests to the FreeClimb REST API is: /apiserver. FreeClimb authenticates and processes your request.  # noqa: E501

    The version of the OpenAPI document: 1.0.0
    Contact: support@freeclimb.com
    Generated by: https://openapi-generator.tech
"""


import sys
import unittest
from datetime import datetime, date
import pytest

import freeclimb
from freeclimb.model.answered_by import AnsweredBy
from freeclimb.model.call_direction import CallDirection
from freeclimb.model.call_result_all_of import CallResultAllOf
from freeclimb.model.call_status import CallStatus
from freeclimb.model.mutable_resource_model import MutableResourceModel
globals()['AnsweredBy'] = AnsweredBy
globals()['CallDirection'] = CallDirection
globals()['CallResultAllOf'] = CallResultAllOf
globals()['CallStatus'] = CallStatus
globals()['MutableResourceModel'] = MutableResourceModel

from freeclimb.model.call_result import CallResult  # noqa: E501

class TestCallResult(unittest.TestCase):
    """CallResult unit test stubs"""

    def setUp(self):
        self.model = CallResult(
        )
    
    def test_uri(self):
        """Test CallResult.uri"""
        self.model.uri = "TEST_STRING"
        assert self.model.get("uri") == "TEST_STRING"

    def test_date_created(self):
        """Test CallResult.date_created"""
        self.model.date_created = "TEST_STRING"
        assert self.model.get("date_created") == "TEST_STRING"

    def test_date_updated(self):
        """Test CallResult.date_updated"""
        self.model.date_updated = "TEST_STRING"
        assert self.model.get("date_updated") == "TEST_STRING"

    def test_revision(self):
        """Test CallResult.revision"""
        self.model.revision = 1
        assert self.model.get("revision") == 1

    def test_call_id(self):
        """Test CallResult.call_id"""
        self.model.call_id = "TEST_STRING"
        assert self.model.get("call_id") == "TEST_STRING"

    def test_parent_call_id(self):
        """Test CallResult.parent_call_id"""
        self.model.parent_call_id = "TEST_STRING"
        assert self.model.get("parent_call_id") == "TEST_STRING"

    def test_account_id(self):
        """Test CallResult.account_id"""
        self.model.account_id = "TEST_STRING"
        assert self.model.get("account_id") == "TEST_STRING"

    def test__from(self):
        """Test CallResult._from"""
        self.model._from = "TEST_STRING"
        assert self.model.get("_from") == "TEST_STRING"

    def test_to(self):
        """Test CallResult.to"""
        self.model.to = "TEST_STRING"
        assert self.model.get("to") == "TEST_STRING"

    def test_phone_number_id(self):
        """Test CallResult.phone_number_id"""
        self.model.phone_number_id = "TEST_STRING"
        assert self.model.get("phone_number_id") == "TEST_STRING"

    def test_call_status(self):
        """Test CallResult.call_status"""
        self.model.call_status = CallStatus.QUEUED
        assert self.model.get("call_status") == CallStatus.QUEUED
        self.model.call_status = CallStatus.RINGING
        assert self.model.get("call_status") == CallStatus.RINGING
        self.model.call_status = CallStatus.IN_PROGRESS
        assert self.model.get("call_status") == CallStatus.IN_PROGRESS
        self.model.call_status = CallStatus.CANCELED
        assert self.model.get("call_status") == CallStatus.CANCELED
        self.model.call_status = CallStatus.COMPLETED
        assert self.model.get("call_status") == CallStatus.COMPLETED
        self.model.call_status = CallStatus.FAILED
        assert self.model.get("call_status") == CallStatus.FAILED
        self.model.call_status = CallStatus.BUSY
        assert self.model.get("call_status") == CallStatus.BUSY
        self.model.call_status = CallStatus.NO_ANSWER
        assert self.model.get("call_status") == CallStatus.NO_ANSWER

    def test_start_time(self):
        """Test CallResult.start_time"""
        self.model.start_time = "TEST_STRING"
        assert self.model.get("start_time") == "TEST_STRING"

    def test_connect_time(self):
        """Test CallResult.connect_time"""
        self.model.connect_time = "TEST_STRING"
        assert self.model.get("connect_time") == "TEST_STRING"

    def test_end_time(self):
        """Test CallResult.end_time"""
        self.model.end_time = "TEST_STRING"
        assert self.model.get("end_time") == "TEST_STRING"

    def test_duration(self):
        """Test CallResult.duration"""
        self.model.duration = 1
        assert self.model.get("duration") == 1

    def test_connect_duration(self):
        """Test CallResult.connect_duration"""
        self.model.connect_duration = 1
        assert self.model.get("connect_duration") == 1

    def test_direction(self):
        """Test CallResult.direction"""
        self.model.direction = CallDirection.INBOUND
        assert self.model.get("direction") == CallDirection.INBOUND
        self.model.direction = CallDirection.OUTBOUND_API
        assert self.model.get("direction") == CallDirection.OUTBOUND_API
        self.model.direction = CallDirection.OUTBOUND_DIAL
        assert self.model.get("direction") == CallDirection.OUTBOUND_DIAL

    def test_answered_by(self):
        """Test CallResult.answered_by"""
        self.model.answered_by = AnsweredBy.HUMAN
        assert self.model.get("answered_by") == AnsweredBy.HUMAN
        self.model.answered_by = AnsweredBy.MACHINE
        assert self.model.get("answered_by") == AnsweredBy.MACHINE

    def test_subresource_uris(self):
        """Test CallResult.subresource_uris"""
        testObject = {}
        self.model.subresource_uris = testObject
        assert self.model.get("subresource_uris") == testObject

if __name__ == '__main__':
    unittest.main()
