From 206f2cf5520a9d9bcc08736013cbed4c2387e444 Mon Sep 17 00:00:00 2001 From: cloudant-sdks-automation <71659186+cloudant-sdks-automation@users.noreply.github.com> Date: Tue, 27 Apr 2021 16:03:28 +0000 Subject: [PATCH] Update generated source code Generated SDK source code using: - Generator version 3.30.0 - Specification version 1.0.0-dev0.0.35 - Automation (cloudant-sdks) version c774d33 --- ibmcloudant/cloudant_v1.py | 123 +++++++--------------------- test/unit/test_cloudant_v1.py | 149 +++++++++++++--------------------- 2 files changed, 84 insertions(+), 188 deletions(-) diff --git a/ibmcloudant/cloudant_v1.py b/ibmcloudant/cloudant_v1.py index f32c007e..8a30107c 100644 --- a/ibmcloudant/cloudant_v1.py +++ b/ibmcloudant/cloudant_v1.py @@ -197,8 +197,8 @@ def get_capacity_throughput_information(self, """ Retrieve provisioned throughput capacity information. - View the amount of provisioned throughput capacity allocated to an IBM Cloudant - instance and what is the target provisioned throughput capacity. + View the amount of provisioned throughput capacity that is allocated to an IBM + Cloudant instance and what is the target provisioned throughput capacity. :param dict headers: A `dict` containing the request headers :return: A `DetailedResponse` containing the result, headers and HTTP status code. @@ -224,7 +224,7 @@ def get_capacity_throughput_information(self, return response - def put_capacity_throughput_information(self, + def put_capacity_throughput_configuration(self, blocks: int, **kwargs ) -> DetailedResponse: @@ -248,7 +248,7 @@ def put_capacity_throughput_information(self, headers = {} sdk_headers = get_sdk_headers(service_name=self.DEFAULT_SERVICE_NAME, service_version='V1', - operation_id='put_capacity_throughput_information') + operation_id='put_capacity_throughput_configuration') headers.update(sdk_headers) data = { @@ -1879,13 +1879,11 @@ def get_document(self, if_none_match: str = None, attachments: bool = None, att_encoding_info: bool = None, - atts_since: List[str] = None, conflicts: bool = None, deleted_conflicts: bool = None, latest: bool = None, local_seq: bool = None, meta: bool = None, - open_revs: List[str] = None, rev: str = None, revs: bool = None, revs_info: bool = None, @@ -1907,9 +1905,6 @@ def get_document(self, :param bool att_encoding_info: (optional) Query parameter to specify whether to include the encoding information in attachment stubs if the particular attachment is compressed. - :param List[str] atts_since: (optional) Query parameter to specify whether - to include attachments only since specified revisions. Note this does not - include the attachments for the specified revisions. :param bool conflicts: (optional) Query parameter to specify whether to include a list of conflicted revisions in the `_conflicts` property of the returned document. Ignored if `include_docs` isn't `true`. @@ -1923,9 +1918,6 @@ def get_document(self, :param bool meta: (optional) Query parameter to specify whether to include document meta information. Acts the same as specifying all of the conflicts, deleted_conflicts and open_revs query parameters. - :param List[str] open_revs: (optional) Query parameter to specify leaf - revisions to retrieve. Additionally, it accepts a value of `all` to return - all leaf revisions. :param str rev: (optional) Query parameter to specify a document revision. :param bool revs: (optional) Query parameter to specify whether to include a list of all known document revisions. @@ -1951,13 +1943,11 @@ def get_document(self, params = { 'attachments': attachments, 'att_encoding_info': att_encoding_info, - 'atts_since': convert_list(atts_since), 'conflicts': conflicts, 'deleted_conflicts': deleted_conflicts, 'latest': latest, 'local_seq': local_seq, 'meta': meta, - 'open_revs': convert_list(open_revs), 'rev': rev, 'revs': revs, 'revs_info': revs_info @@ -1987,13 +1977,11 @@ def get_document_as_mixed(self, if_none_match: str = None, attachments: bool = None, att_encoding_info: bool = None, - atts_since: List[str] = None, conflicts: bool = None, deleted_conflicts: bool = None, latest: bool = None, local_seq: bool = None, meta: bool = None, - open_revs: List[str] = None, rev: str = None, revs: bool = None, revs_info: bool = None, @@ -2015,9 +2003,6 @@ def get_document_as_mixed(self, :param bool att_encoding_info: (optional) Query parameter to specify whether to include the encoding information in attachment stubs if the particular attachment is compressed. - :param List[str] atts_since: (optional) Query parameter to specify whether - to include attachments only since specified revisions. Note this does not - include the attachments for the specified revisions. :param bool conflicts: (optional) Query parameter to specify whether to include a list of conflicted revisions in the `_conflicts` property of the returned document. Ignored if `include_docs` isn't `true`. @@ -2031,9 +2016,6 @@ def get_document_as_mixed(self, :param bool meta: (optional) Query parameter to specify whether to include document meta information. Acts the same as specifying all of the conflicts, deleted_conflicts and open_revs query parameters. - :param List[str] open_revs: (optional) Query parameter to specify leaf - revisions to retrieve. Additionally, it accepts a value of `all` to return - all leaf revisions. :param str rev: (optional) Query parameter to specify a document revision. :param bool revs: (optional) Query parameter to specify whether to include a list of all known document revisions. @@ -2059,13 +2041,11 @@ def get_document_as_mixed(self, params = { 'attachments': attachments, 'att_encoding_info': att_encoding_info, - 'atts_since': convert_list(atts_since), 'conflicts': conflicts, 'deleted_conflicts': deleted_conflicts, 'latest': latest, 'local_seq': local_seq, 'meta': meta, - 'open_revs': convert_list(open_revs), 'rev': rev, 'revs': revs, 'revs_info': revs_info @@ -2095,13 +2075,11 @@ def get_document_as_related(self, if_none_match: str = None, attachments: bool = None, att_encoding_info: bool = None, - atts_since: List[str] = None, conflicts: bool = None, deleted_conflicts: bool = None, latest: bool = None, local_seq: bool = None, meta: bool = None, - open_revs: List[str] = None, rev: str = None, revs: bool = None, revs_info: bool = None, @@ -2123,9 +2101,6 @@ def get_document_as_related(self, :param bool att_encoding_info: (optional) Query parameter to specify whether to include the encoding information in attachment stubs if the particular attachment is compressed. - :param List[str] atts_since: (optional) Query parameter to specify whether - to include attachments only since specified revisions. Note this does not - include the attachments for the specified revisions. :param bool conflicts: (optional) Query parameter to specify whether to include a list of conflicted revisions in the `_conflicts` property of the returned document. Ignored if `include_docs` isn't `true`. @@ -2139,9 +2114,6 @@ def get_document_as_related(self, :param bool meta: (optional) Query parameter to specify whether to include document meta information. Acts the same as specifying all of the conflicts, deleted_conflicts and open_revs query parameters. - :param List[str] open_revs: (optional) Query parameter to specify leaf - revisions to retrieve. Additionally, it accepts a value of `all` to return - all leaf revisions. :param str rev: (optional) Query parameter to specify a document revision. :param bool revs: (optional) Query parameter to specify whether to include a list of all known document revisions. @@ -2167,13 +2139,11 @@ def get_document_as_related(self, params = { 'attachments': attachments, 'att_encoding_info': att_encoding_info, - 'atts_since': convert_list(atts_since), 'conflicts': conflicts, 'deleted_conflicts': deleted_conflicts, 'latest': latest, 'local_seq': local_seq, 'meta': meta, - 'open_revs': convert_list(open_revs), 'rev': rev, 'revs': revs, 'revs_info': revs_info @@ -2203,13 +2173,11 @@ def get_document_as_stream(self, if_none_match: str = None, attachments: bool = None, att_encoding_info: bool = None, - atts_since: List[str] = None, conflicts: bool = None, deleted_conflicts: bool = None, latest: bool = None, local_seq: bool = None, meta: bool = None, - open_revs: List[str] = None, rev: str = None, revs: bool = None, revs_info: bool = None, @@ -2231,9 +2199,6 @@ def get_document_as_stream(self, :param bool att_encoding_info: (optional) Query parameter to specify whether to include the encoding information in attachment stubs if the particular attachment is compressed. - :param List[str] atts_since: (optional) Query parameter to specify whether - to include attachments only since specified revisions. Note this does not - include the attachments for the specified revisions. :param bool conflicts: (optional) Query parameter to specify whether to include a list of conflicted revisions in the `_conflicts` property of the returned document. Ignored if `include_docs` isn't `true`. @@ -2247,9 +2212,6 @@ def get_document_as_stream(self, :param bool meta: (optional) Query parameter to specify whether to include document meta information. Acts the same as specifying all of the conflicts, deleted_conflicts and open_revs query parameters. - :param List[str] open_revs: (optional) Query parameter to specify leaf - revisions to retrieve. Additionally, it accepts a value of `all` to return - all leaf revisions. :param str rev: (optional) Query parameter to specify a document revision. :param bool revs: (optional) Query parameter to specify whether to include a list of all known document revisions. @@ -2275,13 +2237,11 @@ def get_document_as_stream(self, params = { 'attachments': attachments, 'att_encoding_info': att_encoding_info, - 'atts_since': convert_list(atts_since), 'conflicts': conflicts, 'deleted_conflicts': deleted_conflicts, 'latest': latest, 'local_seq': local_seq, 'meta': meta, - 'open_revs': convert_list(open_revs), 'rev': rev, 'revs': revs, 'revs_info': revs_info @@ -2526,13 +2486,11 @@ def get_design_document(self, if_none_match: str = None, attachments: bool = None, att_encoding_info: bool = None, - atts_since: List[str] = None, conflicts: bool = None, deleted_conflicts: bool = None, latest: bool = None, local_seq: bool = None, meta: bool = None, - open_revs: List[str] = None, rev: str = None, revs: bool = None, revs_info: bool = None, @@ -2556,9 +2514,6 @@ def get_design_document(self, :param bool att_encoding_info: (optional) Query parameter to specify whether to include the encoding information in attachment stubs if the particular attachment is compressed. - :param List[str] atts_since: (optional) Query parameter to specify whether - to include attachments only since specified revisions. Note this does not - include the attachments for the specified revisions. :param bool conflicts: (optional) Query parameter to specify whether to include a list of conflicted revisions in the `_conflicts` property of the returned document. Ignored if `include_docs` isn't `true`. @@ -2572,9 +2527,6 @@ def get_design_document(self, :param bool meta: (optional) Query parameter to specify whether to include document meta information. Acts the same as specifying all of the conflicts, deleted_conflicts and open_revs query parameters. - :param List[str] open_revs: (optional) Query parameter to specify leaf - revisions to retrieve. Additionally, it accepts a value of `all` to return - all leaf revisions. :param str rev: (optional) Query parameter to specify a document revision. :param bool revs: (optional) Query parameter to specify whether to include a list of all known document revisions. @@ -2600,13 +2552,11 @@ def get_design_document(self, params = { 'attachments': attachments, 'att_encoding_info': att_encoding_info, - 'atts_since': convert_list(atts_since), 'conflicts': conflicts, 'deleted_conflicts': deleted_conflicts, 'latest': latest, 'local_seq': local_seq, 'meta': meta, - 'open_revs': convert_list(open_revs), 'rev': rev, 'revs': revs, 'revs_info': revs_info @@ -6017,13 +5967,11 @@ def get_replication_document(self, if_none_match: str = None, attachments: bool = None, att_encoding_info: bool = None, - atts_since: List[str] = None, conflicts: bool = None, deleted_conflicts: bool = None, latest: bool = None, local_seq: bool = None, meta: bool = None, - open_revs: List[str] = None, rev: str = None, revs: bool = None, revs_info: bool = None, @@ -6044,9 +5992,6 @@ def get_replication_document(self, :param bool att_encoding_info: (optional) Query parameter to specify whether to include the encoding information in attachment stubs if the particular attachment is compressed. - :param List[str] atts_since: (optional) Query parameter to specify whether - to include attachments only since specified revisions. Note this does not - include the attachments for the specified revisions. :param bool conflicts: (optional) Query parameter to specify whether to include a list of conflicted revisions in the `_conflicts` property of the returned document. Ignored if `include_docs` isn't `true`. @@ -6060,9 +6005,6 @@ def get_replication_document(self, :param bool meta: (optional) Query parameter to specify whether to include document meta information. Acts the same as specifying all of the conflicts, deleted_conflicts and open_revs query parameters. - :param List[str] open_revs: (optional) Query parameter to specify leaf - revisions to retrieve. Additionally, it accepts a value of `all` to return - all leaf revisions. :param str rev: (optional) Query parameter to specify a document revision. :param bool revs: (optional) Query parameter to specify whether to include a list of all known document revisions. @@ -6086,13 +6028,11 @@ def get_replication_document(self, params = { 'attachments': attachments, 'att_encoding_info': att_encoding_info, - 'atts_since': convert_list(atts_since), 'conflicts': conflicts, 'deleted_conflicts': deleted_conflicts, 'latest': latest, 'local_seq': local_seq, 'meta': meta, - 'open_revs': convert_list(open_revs), 'rev': rev, 'revs': revs, 'revs_info': revs_info @@ -7133,7 +7073,6 @@ def get_local_document(self, if_none_match: str = None, attachments: bool = None, att_encoding_info: bool = None, - atts_since: List[str] = None, local_seq: bool = None, **kwargs ) -> DetailedResponse: @@ -7155,9 +7094,6 @@ def get_local_document(self, :param bool att_encoding_info: (optional) Query parameter to specify whether to include the encoding information in attachment stubs if the particular attachment is compressed. - :param List[str] atts_since: (optional) Query parameter to specify whether - to include attachments only since specified revisions. Note this does not - include the attachments for the specified revisions. :param bool local_seq: (optional) Query parameter to specify whether to include the last update sequence for the document. :param dict headers: A `dict` containing the request headers @@ -7181,7 +7117,6 @@ def get_local_document(self, params = { 'attachments': attachments, 'att_encoding_info': att_encoding_info, - 'atts_since': convert_list(atts_since), 'local_seq': local_seq } @@ -7565,24 +7500,24 @@ def get_up_information(self, return response - def get_activity_tracker_events_information(self, + def get_activity_tracker_events(self, **kwargs ) -> DetailedResponse: """ Retrieve Activity Tracker events information. - Check event types that are being sent to IBM Cloud Activity Tracker with LogDNA - for the IBM Cloudant instance. + Check event types that are being sent to IBM Cloud Activity Tracker for the IBM + Cloudant instance. :param dict headers: A `dict` containing the request headers :return: A `DetailedResponse` containing the result, headers and HTTP status code. - :rtype: DetailedResponse with `dict` result representing a `ActivityTrackerEventsConfiguration` object + :rtype: DetailedResponse with `dict` result representing a `ActivityTrackerEvents` object """ headers = {} sdk_headers = get_sdk_headers(service_name=self.DEFAULT_SERVICE_NAME, service_version='V1', - operation_id='get_activity_tracker_events_information') + operation_id='get_activity_tracker_events') headers.update(sdk_headers) if 'headers' in kwargs: @@ -7598,19 +7533,19 @@ def get_activity_tracker_events_information(self, return response - def post_activity_tracker_events_configuration(self, + def post_activity_tracker_events(self, types: List[str], **kwargs ) -> DetailedResponse: """ Modify Activity Tracker events configuration. - Configure event types that are being sent to IBM Cloud Activity Tracker with - LogDNA for the IBM Cloudant instance. + Configure event types that are being sent to IBM Cloud Activity Tracker for the + IBM Cloudant instance. :param List[str] types: An array of event types that are being sent to IBM - Cloud Activity Tracker with LogDNA for the IBM Cloudant instance. - "management" is a required element of this array. + Cloud Activity Tracker for the IBM Cloudant instance. "management" is a + required element of this array. :param dict headers: A `dict` containing the request headers :return: A `DetailedResponse` containing the result, headers and HTTP status code. :rtype: DetailedResponse with `dict` result representing a `Ok` object @@ -7621,7 +7556,7 @@ def post_activity_tracker_events_configuration(self, headers = {} sdk_headers = get_sdk_headers(service_name=self.DEFAULT_SERVICE_NAME, service_version='V1', - operation_id='post_activity_tracker_events_configuration') + operation_id='post_activity_tracker_events') headers.update(sdk_headers) data = { @@ -8179,39 +8114,39 @@ def __ne__(self, other: 'ActiveTask') -> bool: """Return `true` when self and other are not equal, false otherwise.""" return not self == other -class ActivityTrackerEventsConfiguration(): +class ActivityTrackerEvents(): """ - Schema for Activity Tracker events configuration. + Schema for Activity Tracker events. :attr List[str] types: An array of event types that are being sent to IBM Cloud - Activity Tracker with LogDNA for the IBM Cloudant instance. "management" is a - required element of this array. + Activity Tracker for the IBM Cloudant instance. "management" is a required + element of this array. """ def __init__(self, types: List[str]) -> None: """ - Initialize a ActivityTrackerEventsConfiguration object. + Initialize a ActivityTrackerEvents object. :param List[str] types: An array of event types that are being sent to IBM - Cloud Activity Tracker with LogDNA for the IBM Cloudant instance. - "management" is a required element of this array. + Cloud Activity Tracker for the IBM Cloudant instance. "management" is a + required element of this array. """ self.types = types @classmethod - def from_dict(cls, _dict: Dict) -> 'ActivityTrackerEventsConfiguration': - """Initialize a ActivityTrackerEventsConfiguration object from a json dictionary.""" + def from_dict(cls, _dict: Dict) -> 'ActivityTrackerEvents': + """Initialize a ActivityTrackerEvents object from a json dictionary.""" args = {} if 'types' in _dict: args['types'] = _dict.get('types') else: - raise ValueError('Required property \'types\' not present in ActivityTrackerEventsConfiguration JSON') + raise ValueError('Required property \'types\' not present in ActivityTrackerEvents JSON') return cls(**args) @classmethod def _from_dict(cls, _dict): - """Initialize a ActivityTrackerEventsConfiguration object from a json dictionary.""" + """Initialize a ActivityTrackerEvents object from a json dictionary.""" return cls.from_dict(_dict) def to_dict(self) -> Dict: @@ -8226,16 +8161,16 @@ def _to_dict(self): return self.to_dict() def __str__(self) -> str: - """Return a `str` version of this ActivityTrackerEventsConfiguration object.""" + """Return a `str` version of this ActivityTrackerEvents object.""" return json.dumps(self.to_dict(), indent=2) - def __eq__(self, other: 'ActivityTrackerEventsConfiguration') -> bool: + def __eq__(self, other: 'ActivityTrackerEvents') -> bool: """Return `true` when self and other are equal, false otherwise.""" if not isinstance(other, self.__class__): return False return self.__dict__ == other.__dict__ - def __ne__(self, other: 'ActivityTrackerEventsConfiguration') -> bool: + def __ne__(self, other: 'ActivityTrackerEvents') -> bool: """Return `true` when self and other are not equal, false otherwise.""" return not self == other diff --git a/test/unit/test_cloudant_v1.py b/test/unit/test_cloudant_v1.py index cc6126cd..3440ce2f 100644 --- a/test/unit/test_cloudant_v1.py +++ b/test/unit/test_cloudant_v1.py @@ -227,9 +227,9 @@ def test_get_capacity_throughput_information_all_params(self): assert response.status_code == 200 -class TestPutCapacityThroughputInformation(): +class TestPutCapacityThroughputConfiguration(): """ - Test Class for put_capacity_throughput_information + Test Class for put_capacity_throughput_configuration """ def preprocess_url(self, request_url: str): @@ -242,9 +242,9 @@ def preprocess_url(self, request_url: str): return re.compile(request_url.rstrip('/') + '/+') @responses.activate - def test_put_capacity_throughput_information_all_params(self): + def test_put_capacity_throughput_configuration_all_params(self): """ - put_capacity_throughput_information() + put_capacity_throughput_configuration() """ # Set up mock url = self.preprocess_url(base_url + '/_api/v2/user/capacity/throughput') @@ -259,7 +259,7 @@ def test_put_capacity_throughput_information_all_params(self): blocks = 0 # Invoke method - response = service.put_capacity_throughput_information( + response = service.put_capacity_throughput_configuration( blocks, headers={} ) @@ -276,9 +276,9 @@ def test_put_capacity_throughput_information_all_params(self): @responses.activate - def test_put_capacity_throughput_information_value_error(self): + def test_put_capacity_throughput_configuration_value_error(self): """ - test_put_capacity_throughput_information_value_error() + test_put_capacity_throughput_configuration_value_error() """ # Set up mock url = self.preprocess_url(base_url + '/_api/v2/user/capacity/throughput') @@ -299,7 +299,7 @@ def test_put_capacity_throughput_information_value_error(self): for param in req_param_dict.keys(): req_copy = {key:val if key is not param else None for (key,val) in req_param_dict.items()} with pytest.raises(ValueError): - service.put_capacity_throughput_information(**req_copy) + service.put_capacity_throughput_configuration(**req_copy) @@ -2407,9 +2407,9 @@ def test_post_bulk_get_as_mixed_all_params(self): # Construct a dict representation of a BulkGetQueryDocument model bulk_get_query_document_model = {} bulk_get_query_document_model['atts_since'] = ['testString'] - bulk_get_query_document_model['id'] = 'small-appliances:1000042' + bulk_get_query_document_model['id'] = 'order00067' bulk_get_query_document_model['open_revs'] = ['testString'] - bulk_get_query_document_model['rev'] = 'testString' + bulk_get_query_document_model['rev'] = '3-917fa2381192822767f010b95b45325b' # Set up parameter values db = 'testString' @@ -2465,9 +2465,9 @@ def test_post_bulk_get_as_mixed_required_params(self): # Construct a dict representation of a BulkGetQueryDocument model bulk_get_query_document_model = {} bulk_get_query_document_model['atts_since'] = ['testString'] - bulk_get_query_document_model['id'] = 'small-appliances:1000042' + bulk_get_query_document_model['id'] = 'order00067' bulk_get_query_document_model['open_revs'] = ['testString'] - bulk_get_query_document_model['rev'] = 'testString' + bulk_get_query_document_model['rev'] = '3-917fa2381192822767f010b95b45325b' # Set up parameter values db = 'testString' @@ -2508,9 +2508,9 @@ def test_post_bulk_get_as_mixed_value_error(self): # Construct a dict representation of a BulkGetQueryDocument model bulk_get_query_document_model = {} bulk_get_query_document_model['atts_since'] = ['testString'] - bulk_get_query_document_model['id'] = 'small-appliances:1000042' + bulk_get_query_document_model['id'] = 'order00067' bulk_get_query_document_model['open_revs'] = ['testString'] - bulk_get_query_document_model['rev'] = 'testString' + bulk_get_query_document_model['rev'] = '3-917fa2381192822767f010b95b45325b' # Set up parameter values db = 'testString' @@ -2559,9 +2559,9 @@ def test_post_bulk_get_as_related_all_params(self): # Construct a dict representation of a BulkGetQueryDocument model bulk_get_query_document_model = {} bulk_get_query_document_model['atts_since'] = ['testString'] - bulk_get_query_document_model['id'] = 'small-appliances:1000042' + bulk_get_query_document_model['id'] = 'order00067' bulk_get_query_document_model['open_revs'] = ['testString'] - bulk_get_query_document_model['rev'] = 'testString' + bulk_get_query_document_model['rev'] = '3-917fa2381192822767f010b95b45325b' # Set up parameter values db = 'testString' @@ -2617,9 +2617,9 @@ def test_post_bulk_get_as_related_required_params(self): # Construct a dict representation of a BulkGetQueryDocument model bulk_get_query_document_model = {} bulk_get_query_document_model['atts_since'] = ['testString'] - bulk_get_query_document_model['id'] = 'small-appliances:1000042' + bulk_get_query_document_model['id'] = 'order00067' bulk_get_query_document_model['open_revs'] = ['testString'] - bulk_get_query_document_model['rev'] = 'testString' + bulk_get_query_document_model['rev'] = '3-917fa2381192822767f010b95b45325b' # Set up parameter values db = 'testString' @@ -2660,9 +2660,9 @@ def test_post_bulk_get_as_related_value_error(self): # Construct a dict representation of a BulkGetQueryDocument model bulk_get_query_document_model = {} bulk_get_query_document_model['atts_since'] = ['testString'] - bulk_get_query_document_model['id'] = 'small-appliances:1000042' + bulk_get_query_document_model['id'] = 'order00067' bulk_get_query_document_model['open_revs'] = ['testString'] - bulk_get_query_document_model['rev'] = 'testString' + bulk_get_query_document_model['rev'] = '3-917fa2381192822767f010b95b45325b' # Set up parameter values db = 'testString' @@ -2711,9 +2711,9 @@ def test_post_bulk_get_as_stream_all_params(self): # Construct a dict representation of a BulkGetQueryDocument model bulk_get_query_document_model = {} bulk_get_query_document_model['atts_since'] = ['testString'] - bulk_get_query_document_model['id'] = 'small-appliances:1000042' + bulk_get_query_document_model['id'] = 'order00067' bulk_get_query_document_model['open_revs'] = ['testString'] - bulk_get_query_document_model['rev'] = 'testString' + bulk_get_query_document_model['rev'] = '3-917fa2381192822767f010b95b45325b' # Set up parameter values db = 'testString' @@ -2775,9 +2775,9 @@ def test_post_bulk_get_as_stream_required_params(self): # Construct a dict representation of a BulkGetQueryDocument model bulk_get_query_document_model = {} bulk_get_query_document_model['atts_since'] = ['testString'] - bulk_get_query_document_model['id'] = 'small-appliances:1000042' + bulk_get_query_document_model['id'] = 'order00067' bulk_get_query_document_model['open_revs'] = ['testString'] - bulk_get_query_document_model['rev'] = 'testString' + bulk_get_query_document_model['rev'] = '3-917fa2381192822767f010b95b45325b' # Set up parameter values db = 'testString' @@ -2824,9 +2824,9 @@ def test_post_bulk_get_as_stream_value_error(self): # Construct a dict representation of a BulkGetQueryDocument model bulk_get_query_document_model = {} bulk_get_query_document_model['atts_since'] = ['testString'] - bulk_get_query_document_model['id'] = 'small-appliances:1000042' + bulk_get_query_document_model['id'] = 'order00067' bulk_get_query_document_model['open_revs'] = ['testString'] - bulk_get_query_document_model['rev'] = 'testString' + bulk_get_query_document_model['rev'] = '3-917fa2381192822767f010b95b45325b' # Set up parameter values db = 'testString' @@ -2993,13 +2993,11 @@ def test_get_document_all_params(self): if_none_match = 'testString' attachments = True att_encoding_info = True - atts_since = ['testString'] conflicts = True deleted_conflicts = True latest = True local_seq = True meta = True - open_revs = ['testString'] rev = 'testString' revs = True revs_info = True @@ -3011,13 +3009,11 @@ def test_get_document_all_params(self): if_none_match=if_none_match, attachments=attachments, att_encoding_info=att_encoding_info, - atts_since=atts_since, conflicts=conflicts, deleted_conflicts=deleted_conflicts, latest=latest, local_seq=local_seq, meta=meta, - open_revs=open_revs, rev=rev, revs=revs, revs_info=revs_info, @@ -3032,13 +3028,11 @@ def test_get_document_all_params(self): query_string = urllib.parse.unquote_plus(query_string) assert 'attachments={}'.format('true' if attachments else 'false') in query_string assert 'att_encoding_info={}'.format('true' if att_encoding_info else 'false') in query_string - assert 'atts_since={}'.format(','.join(atts_since)) in query_string assert 'conflicts={}'.format('true' if conflicts else 'false') in query_string assert 'deleted_conflicts={}'.format('true' if deleted_conflicts else 'false') in query_string assert 'latest={}'.format('true' if latest else 'false') in query_string assert 'local_seq={}'.format('true' if local_seq else 'false') in query_string assert 'meta={}'.format('true' if meta else 'false') in query_string - assert 'open_revs={}'.format(','.join(open_revs)) in query_string assert 'rev={}'.format(rev) in query_string assert 'revs={}'.format('true' if revs else 'false') in query_string assert 'revs_info={}'.format('true' if revs_info else 'false') in query_string @@ -3138,13 +3132,11 @@ def test_get_document_as_mixed_all_params(self): if_none_match = 'testString' attachments = True att_encoding_info = True - atts_since = ['testString'] conflicts = True deleted_conflicts = True latest = True local_seq = True meta = True - open_revs = ['testString'] rev = 'testString' revs = True revs_info = True @@ -3156,13 +3148,11 @@ def test_get_document_as_mixed_all_params(self): if_none_match=if_none_match, attachments=attachments, att_encoding_info=att_encoding_info, - atts_since=atts_since, conflicts=conflicts, deleted_conflicts=deleted_conflicts, latest=latest, local_seq=local_seq, meta=meta, - open_revs=open_revs, rev=rev, revs=revs, revs_info=revs_info, @@ -3177,13 +3167,11 @@ def test_get_document_as_mixed_all_params(self): query_string = urllib.parse.unquote_plus(query_string) assert 'attachments={}'.format('true' if attachments else 'false') in query_string assert 'att_encoding_info={}'.format('true' if att_encoding_info else 'false') in query_string - assert 'atts_since={}'.format(','.join(atts_since)) in query_string assert 'conflicts={}'.format('true' if conflicts else 'false') in query_string assert 'deleted_conflicts={}'.format('true' if deleted_conflicts else 'false') in query_string assert 'latest={}'.format('true' if latest else 'false') in query_string assert 'local_seq={}'.format('true' if local_seq else 'false') in query_string assert 'meta={}'.format('true' if meta else 'false') in query_string - assert 'open_revs={}'.format(','.join(open_revs)) in query_string assert 'rev={}'.format(rev) in query_string assert 'revs={}'.format('true' if revs else 'false') in query_string assert 'revs_info={}'.format('true' if revs_info else 'false') in query_string @@ -3283,13 +3271,11 @@ def test_get_document_as_related_all_params(self): if_none_match = 'testString' attachments = True att_encoding_info = True - atts_since = ['testString'] conflicts = True deleted_conflicts = True latest = True local_seq = True meta = True - open_revs = ['testString'] rev = 'testString' revs = True revs_info = True @@ -3301,13 +3287,11 @@ def test_get_document_as_related_all_params(self): if_none_match=if_none_match, attachments=attachments, att_encoding_info=att_encoding_info, - atts_since=atts_since, conflicts=conflicts, deleted_conflicts=deleted_conflicts, latest=latest, local_seq=local_seq, meta=meta, - open_revs=open_revs, rev=rev, revs=revs, revs_info=revs_info, @@ -3322,13 +3306,11 @@ def test_get_document_as_related_all_params(self): query_string = urllib.parse.unquote_plus(query_string) assert 'attachments={}'.format('true' if attachments else 'false') in query_string assert 'att_encoding_info={}'.format('true' if att_encoding_info else 'false') in query_string - assert 'atts_since={}'.format(','.join(atts_since)) in query_string assert 'conflicts={}'.format('true' if conflicts else 'false') in query_string assert 'deleted_conflicts={}'.format('true' if deleted_conflicts else 'false') in query_string assert 'latest={}'.format('true' if latest else 'false') in query_string assert 'local_seq={}'.format('true' if local_seq else 'false') in query_string assert 'meta={}'.format('true' if meta else 'false') in query_string - assert 'open_revs={}'.format(','.join(open_revs)) in query_string assert 'rev={}'.format(rev) in query_string assert 'revs={}'.format('true' if revs else 'false') in query_string assert 'revs_info={}'.format('true' if revs_info else 'false') in query_string @@ -3428,13 +3410,11 @@ def test_get_document_as_stream_all_params(self): if_none_match = 'testString' attachments = True att_encoding_info = True - atts_since = ['testString'] conflicts = True deleted_conflicts = True latest = True local_seq = True meta = True - open_revs = ['testString'] rev = 'testString' revs = True revs_info = True @@ -3446,13 +3426,11 @@ def test_get_document_as_stream_all_params(self): if_none_match=if_none_match, attachments=attachments, att_encoding_info=att_encoding_info, - atts_since=atts_since, conflicts=conflicts, deleted_conflicts=deleted_conflicts, latest=latest, local_seq=local_seq, meta=meta, - open_revs=open_revs, rev=rev, revs=revs, revs_info=revs_info, @@ -3467,13 +3445,11 @@ def test_get_document_as_stream_all_params(self): query_string = urllib.parse.unquote_plus(query_string) assert 'attachments={}'.format('true' if attachments else 'false') in query_string assert 'att_encoding_info={}'.format('true' if att_encoding_info else 'false') in query_string - assert 'atts_since={}'.format(','.join(atts_since)) in query_string assert 'conflicts={}'.format('true' if conflicts else 'false') in query_string assert 'deleted_conflicts={}'.format('true' if deleted_conflicts else 'false') in query_string assert 'latest={}'.format('true' if latest else 'false') in query_string assert 'local_seq={}'.format('true' if local_seq else 'false') in query_string assert 'meta={}'.format('true' if meta else 'false') in query_string - assert 'open_revs={}'.format(','.join(open_revs)) in query_string assert 'rev={}'.format(rev) in query_string assert 'revs={}'.format('true' if revs else 'false') in query_string assert 'revs_info={}'.format('true' if revs_info else 'false') in query_string @@ -4046,13 +4022,11 @@ def test_get_design_document_all_params(self): if_none_match = 'testString' attachments = True att_encoding_info = True - atts_since = ['testString'] conflicts = True deleted_conflicts = True latest = True local_seq = True meta = True - open_revs = ['testString'] rev = 'testString' revs = True revs_info = True @@ -4064,13 +4038,11 @@ def test_get_design_document_all_params(self): if_none_match=if_none_match, attachments=attachments, att_encoding_info=att_encoding_info, - atts_since=atts_since, conflicts=conflicts, deleted_conflicts=deleted_conflicts, latest=latest, local_seq=local_seq, meta=meta, - open_revs=open_revs, rev=rev, revs=revs, revs_info=revs_info, @@ -4085,13 +4057,11 @@ def test_get_design_document_all_params(self): query_string = urllib.parse.unquote_plus(query_string) assert 'attachments={}'.format('true' if attachments else 'false') in query_string assert 'att_encoding_info={}'.format('true' if att_encoding_info else 'false') in query_string - assert 'atts_since={}'.format(','.join(atts_since)) in query_string assert 'conflicts={}'.format('true' if conflicts else 'false') in query_string assert 'deleted_conflicts={}'.format('true' if deleted_conflicts else 'false') in query_string assert 'latest={}'.format('true' if latest else 'false') in query_string assert 'local_seq={}'.format('true' if local_seq else 'false') in query_string assert 'meta={}'.format('true' if meta else 'false') in query_string - assert 'open_revs={}'.format(','.join(open_revs)) in query_string assert 'rev={}'.format(rev) in query_string assert 'revs={}'.format('true' if revs else 'false') in query_string assert 'revs_info={}'.format('true' if revs_info else 'false') in query_string @@ -9067,13 +9037,11 @@ def test_get_replication_document_all_params(self): if_none_match = 'testString' attachments = True att_encoding_info = True - atts_since = ['testString'] conflicts = True deleted_conflicts = True latest = True local_seq = True meta = True - open_revs = ['testString'] rev = 'testString' revs = True revs_info = True @@ -9084,13 +9052,11 @@ def test_get_replication_document_all_params(self): if_none_match=if_none_match, attachments=attachments, att_encoding_info=att_encoding_info, - atts_since=atts_since, conflicts=conflicts, deleted_conflicts=deleted_conflicts, latest=latest, local_seq=local_seq, meta=meta, - open_revs=open_revs, rev=rev, revs=revs, revs_info=revs_info, @@ -9105,13 +9071,11 @@ def test_get_replication_document_all_params(self): query_string = urllib.parse.unquote_plus(query_string) assert 'attachments={}'.format('true' if attachments else 'false') in query_string assert 'att_encoding_info={}'.format('true' if att_encoding_info else 'false') in query_string - assert 'atts_since={}'.format(','.join(atts_since)) in query_string assert 'conflicts={}'.format('true' if conflicts else 'false') in query_string assert 'deleted_conflicts={}'.format('true' if deleted_conflicts else 'false') in query_string assert 'latest={}'.format('true' if latest else 'false') in query_string assert 'local_seq={}'.format('true' if local_seq else 'false') in query_string assert 'meta={}'.format('true' if meta else 'false') in query_string - assert 'open_revs={}'.format(','.join(open_revs)) in query_string assert 'rev={}'.format(rev) in query_string assert 'revs={}'.format('true' if revs else 'false') in query_string assert 'revs_info={}'.format('true' if revs_info else 'false') in query_string @@ -11091,7 +11055,6 @@ def test_get_local_document_all_params(self): if_none_match = 'testString' attachments = True att_encoding_info = True - atts_since = ['testString'] local_seq = True # Invoke method @@ -11102,7 +11065,6 @@ def test_get_local_document_all_params(self): if_none_match=if_none_match, attachments=attachments, att_encoding_info=att_encoding_info, - atts_since=atts_since, local_seq=local_seq, headers={} ) @@ -11115,7 +11077,6 @@ def test_get_local_document_all_params(self): query_string = urllib.parse.unquote_plus(query_string) assert 'attachments={}'.format('true' if attachments else 'false') in query_string assert 'att_encoding_info={}'.format('true' if att_encoding_info else 'false') in query_string - assert 'atts_since={}'.format(','.join(atts_since)) in query_string assert 'local_seq={}'.format('true' if local_seq else 'false') in query_string @@ -11842,9 +11803,9 @@ def test_get_up_information_all_params(self): assert response.status_code == 200 -class TestGetActivityTrackerEventsInformation(): +class TestGetActivityTrackerEvents(): """ - Test Class for get_activity_tracker_events_information + Test Class for get_activity_tracker_events """ def preprocess_url(self, request_url: str): @@ -11857,9 +11818,9 @@ def preprocess_url(self, request_url: str): return re.compile(request_url.rstrip('/') + '/+') @responses.activate - def test_get_activity_tracker_events_information_all_params(self): + def test_get_activity_tracker_events_all_params(self): """ - get_activity_tracker_events_information() + get_activity_tracker_events() """ # Set up mock url = self.preprocess_url(base_url + '/_api/v2/user/activity_tracker/events') @@ -11871,7 +11832,7 @@ def test_get_activity_tracker_events_information_all_params(self): status=200) # Invoke method - response = service.get_activity_tracker_events_information() + response = service.get_activity_tracker_events() # Check for correct operation @@ -11879,9 +11840,9 @@ def test_get_activity_tracker_events_information_all_params(self): assert response.status_code == 200 -class TestPostActivityTrackerEventsConfiguration(): +class TestPostActivityTrackerEvents(): """ - Test Class for post_activity_tracker_events_configuration + Test Class for post_activity_tracker_events """ def preprocess_url(self, request_url: str): @@ -11894,9 +11855,9 @@ def preprocess_url(self, request_url: str): return re.compile(request_url.rstrip('/') + '/+') @responses.activate - def test_post_activity_tracker_events_configuration_all_params(self): + def test_post_activity_tracker_events_all_params(self): """ - post_activity_tracker_events_configuration() + post_activity_tracker_events() """ # Set up mock url = self.preprocess_url(base_url + '/_api/v2/user/activity_tracker/events') @@ -11911,7 +11872,7 @@ def test_post_activity_tracker_events_configuration_all_params(self): types = ['management'] # Invoke method - response = service.post_activity_tracker_events_configuration( + response = service.post_activity_tracker_events( types, headers={} ) @@ -11928,9 +11889,9 @@ def test_post_activity_tracker_events_configuration_all_params(self): @responses.activate - def test_post_activity_tracker_events_configuration_value_error(self): + def test_post_activity_tracker_events_value_error(self): """ - test_post_activity_tracker_events_configuration_value_error() + test_post_activity_tracker_events_value_error() """ # Set up mock url = self.preprocess_url(base_url + '/_api/v2/user/activity_tracker/events') @@ -11951,7 +11912,7 @@ def test_post_activity_tracker_events_configuration_value_error(self): for param in req_param_dict.keys(): req_copy = {key:val if key is not param else None for (key,val) in req_param_dict.items()} with pytest.raises(ValueError): - service.post_activity_tracker_events_configuration(**req_copy) + service.post_activity_tracker_events(**req_copy) @@ -12041,34 +12002,34 @@ def test_active_task_serialization(self): active_task_model_json2 = active_task_model.to_dict() assert active_task_model_json2 == active_task_model_json -class TestActivityTrackerEventsConfiguration(): +class TestActivityTrackerEvents(): """ - Test Class for ActivityTrackerEventsConfiguration + Test Class for ActivityTrackerEvents """ - def test_activity_tracker_events_configuration_serialization(self): + def test_activity_tracker_events_serialization(self): """ - Test serialization/deserialization for ActivityTrackerEventsConfiguration + Test serialization/deserialization for ActivityTrackerEvents """ - # Construct a json representation of a ActivityTrackerEventsConfiguration model - activity_tracker_events_configuration_model_json = {} - activity_tracker_events_configuration_model_json['types'] = ['management'] + # Construct a json representation of a ActivityTrackerEvents model + activity_tracker_events_model_json = {} + activity_tracker_events_model_json['types'] = ['management'] - # Construct a model instance of ActivityTrackerEventsConfiguration by calling from_dict on the json representation - activity_tracker_events_configuration_model = ActivityTrackerEventsConfiguration.from_dict(activity_tracker_events_configuration_model_json) - assert activity_tracker_events_configuration_model != False + # Construct a model instance of ActivityTrackerEvents by calling from_dict on the json representation + activity_tracker_events_model = ActivityTrackerEvents.from_dict(activity_tracker_events_model_json) + assert activity_tracker_events_model != False - # Construct a model instance of ActivityTrackerEventsConfiguration by calling from_dict on the json representation - activity_tracker_events_configuration_model_dict = ActivityTrackerEventsConfiguration.from_dict(activity_tracker_events_configuration_model_json).__dict__ - activity_tracker_events_configuration_model2 = ActivityTrackerEventsConfiguration(**activity_tracker_events_configuration_model_dict) + # Construct a model instance of ActivityTrackerEvents by calling from_dict on the json representation + activity_tracker_events_model_dict = ActivityTrackerEvents.from_dict(activity_tracker_events_model_json).__dict__ + activity_tracker_events_model2 = ActivityTrackerEvents(**activity_tracker_events_model_dict) # Verify the model instances are equivalent - assert activity_tracker_events_configuration_model == activity_tracker_events_configuration_model2 + assert activity_tracker_events_model == activity_tracker_events_model2 # Convert model instance back to dict and verify no loss of data - activity_tracker_events_configuration_model_json2 = activity_tracker_events_configuration_model.to_dict() - assert activity_tracker_events_configuration_model_json2 == activity_tracker_events_configuration_model_json + activity_tracker_events_model_json2 = activity_tracker_events_model.to_dict() + assert activity_tracker_events_model_json2 == activity_tracker_events_model_json class TestAllDocsQueriesResult(): """