def call_service(self, body): service = NotificationsApiV1(authenticator=NoAuthAuthenticator(), ) service.set_service_url(base_url) output = service.get_public_key(**body) return output
# limitations under the License. from datetime import datetime, timezone from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import re import requests import responses from ibm_cloud_networking_services.security_events_api_v1 import * crn = 'testString' zone_id = 'testString' service = SecurityEventsApiV1(authenticator=NoAuthAuthenticator(), crn=crn, zone_id=zone_id) base_url = 'https://api.cis.cloud.ibm.com' service.set_service_url(base_url) ############################################################################## # Start of Service: SecurityEvents ############################################################################## # region #----------------------------------------------------------------------------- # Test Class for security_events #-----------------------------------------------------------------------------
# distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import re import responses from ibm_cloud_networking_services.global_load_balancer_monitor_v1 import * crn = 'testString' service = GlobalLoadBalancerMonitorV1(authenticator=NoAuthAuthenticator(), crn=crn) base_url = 'https://api.cis.cloud.ibm.com' service.set_service_url(base_url) ############################################################################## # Start of Service: GlobalLoadBalancerMonitor ############################################################################## # region #----------------------------------------------------------------------------- # Test Class for list_all_load_balancer_monitors #----------------------------------------------------------------------------- class TestListAllLoadBalancerMonitors():
# # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import requests import responses from ibm_platform_services.global_tagging_v1 import * service = GlobalTaggingV1(authenticator=NoAuthAuthenticator()) base_url = 'https://tags.global-search-tagging.cloud.ibm.com/' service.set_service_url(base_url) ############################################################################## # Start of Service: Tags ############################################################################## # region #----------------------------------------------------------------------------- # Test Class for list_tags #----------------------------------------------------------------------------- class TestListTags():
# http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import responses from ibm_cloud_networking_services.cis_ip_api_v1 import * service = CisIpApiV1(authenticator=NoAuthAuthenticator()) base_url = 'https://api.cis.cloud.ibm.com' service.set_service_url(base_url) ############################################################################## # Start of Service: IP ############################################################################## # region #----------------------------------------------------------------------------- # Test Class for list_ips #----------------------------------------------------------------------------- class TestListIps():
def call_service(self, body): service = VisualRecognitionV4(authenticator=NoAuthAuthenticator(), version='2019-02-11') service.set_service_url(base_url) output = service.delete_collection(**body) return output
# Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. from datetime import datetime, timezone from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import requests import responses from ibm_cloud_networking_services.dns_zones_v1 import * service = DnsZonesV1(authenticator=NoAuthAuthenticator()) base_url = 'https://api.dns-svcs.cloud.ibm.com/v1' service.set_service_url(base_url) ############################################################################## # Start of Service: DNSZones ############################################################################## # region #----------------------------------------------------------------------------- # Test Class for list_dnszones #----------------------------------------------------------------------------- class TestListDnszones():
Unit Tests for ToneAnalyzerV3 """ from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import re import requests import responses import urllib from ibm_watson.tone_analyzer_v3 import * version = 'testString' _service = ToneAnalyzerV3(authenticator=NoAuthAuthenticator(), version=version) _base_url = 'https://api.us-south.tone-analyzer.watson.cloud.ibm.com' _service.set_service_url(_base_url) ############################################################################## # Start of Service: Methods ############################################################################## # region class TestTone(): """ Test Class for tone """ def preprocess_url(self, request_url: str):
def call_service(self, body): service = TextToSpeechV1(authenticator=NoAuthAuthenticator(),) service.set_service_url(base_url) output = service.update_voice_model(**body) return output
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import requests import responses from ibm_cloud_cis_services.zone_firewall_access_rules_v1 import ZoneFirewallAccessRulesV1 crn = 'testString' zone_identifier = 'testString' service = ZoneFirewallAccessRulesV1(authenticator=NoAuthAuthenticator(), crn=crn, zone_identifier=zone_identifier) base_url = 'https://api.cis.cloud.ibm.com' service.set_service_url(base_url) ############################################################################## # Start of Service: ListAllAccessRules ############################################################################## # region #----------------------------------------------------------------------------- # Test Class for list_all_zone_access_rules #-----------------------------------------------------------------------------
# See the License for the specific language governing permissions and # limitations under the License. """ Unit Tests for UsageMeteringV4 """ from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import re import responses import urllib from ibm_platform_services.usage_metering_v4 import * service = UsageMeteringV4(authenticator=NoAuthAuthenticator()) base_url = 'https://billing.cloud.ibm.com' service.set_service_url(base_url) ############################################################################## # Start of Service: ResourceUsage ############################################################################## # region class TestReportResourceUsage(): """ Test Class for report_resource_usage """ def preprocess_url(self, request_url: str):
from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator from ibm_cloud_sdk_core.utils import datetime_to_string, string_to_datetime import inspect import io import json import pytest import re import requests import responses import tempfile import urllib from ibm_watson.visual_recognition_v3 import * version = 'testString' _service = VisualRecognitionV3(authenticator=NoAuthAuthenticator(), version=version) _base_url = 'https://api.us-south.visual-recognition.watson.cloud.ibm.com' _service.set_service_url(_base_url) ############################################################################## # Start of Service: General ############################################################################## # region class TestClassify(): """ Test Class for classify """
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import requests import responses from ibm_cloud_cis_services.zone_lockdown_v1 import ZoneLockdownV1 crn = 'testString' zone_identifier = 'testString' service = ZoneLockdownV1(authenticator=NoAuthAuthenticator(), crn=crn, zone_identifier=zone_identifier) base_url = 'https://api.cis.cloud.ibm.com' service.set_service_url(base_url) ############################################################################## # Start of Service: ListAllLockdownRules ############################################################################## # region #----------------------------------------------------------------------------- # Test Class for list_all_zone_lockown_rules #-----------------------------------------------------------------------------
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import requests import responses from ibm_cloud_cis_services import PageRuleApiV1 crn = 'testString' zone_id = 'testString' service = PageRuleApiV1(authenticator=NoAuthAuthenticator(), crn=crn, zone_id=zone_id) base_url = 'https://api.cis.cloud.ibm.com' service.set_service_url(base_url) ############################################################################## # Start of Service: PageRules ############################################################################## # region #----------------------------------------------------------------------------- # Test Class for get_page_rule #-----------------------------------------------------------------------------
Unit Tests for PersonalityInsightsV3 """ from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import re import requests import responses import urllib from ibm_watson.personality_insights_v3 import * version = 'testString' service = PersonalityInsightsV3(authenticator=NoAuthAuthenticator(), version=version) base_url = 'https://api.us-south.personality-insights.watson.cloud.ibm.com' service.set_service_url(base_url) ############################################################################## # Start of Service: Methods ############################################################################## # region class TestProfile(): """ Test Class for profile """
def call_service(self, body): service = TextToSpeechV1(authenticator=NoAuthAuthenticator(),) service.set_service_url(base_url) output = service.get_word(**body) return output
# limitations under the License. from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import io import json import pytest import re import responses import tempfile from ibm_cloud_networking_services.dns_record_bulk_v1 import * crn = 'testString' zone_identifier = 'testString' service = DnsRecordBulkV1(authenticator=NoAuthAuthenticator(), crn=crn, zone_identifier=zone_identifier) base_url = 'https://api.cis.cloud.ibm.com' service.set_service_url(base_url) ############################################################################## # Start of Service: DNSRecords ############################################################################## # region #----------------------------------------------------------------------------- # Test Class for get_dns_records_bulk #-----------------------------------------------------------------------------
# Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import responses from ibm_cloud_cis_services.global_load_balancer_pools_v0 import GlobalLoadBalancerPoolsV0 crn = 'testString' service = GlobalLoadBalancerPoolsV0(authenticator=NoAuthAuthenticator(), crn=crn) base_url = 'https://api.cis.cloud.ibm.com' service.set_service_url(base_url) ############################################################################## # Start of Service: ListPools ############################################################################## # region #----------------------------------------------------------------------------- # Test Class for list_all_load_balancer_pools #----------------------------------------------------------------------------- class TestListAllLoadBalancerPools():
def call_service(self, body): service = VisualRecognitionV4(authenticator=NoAuthAuthenticator(), version='2019-02-11') service.set_service_url(base_url) output = service.add_image_training_data(**body) return output
# distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import responses from ibm_cloud_networking_services.caching_api_v1 import * crn = 'testString' zone_id = 'testString' service = CachingApiV1(authenticator=NoAuthAuthenticator(), crn=crn, zone_id=zone_id) base_url = 'https://api.cis.cloud.ibm.com' service.set_service_url(base_url) ############################################################################## # Start of Service: CacheSettings ############################################################################## # region #----------------------------------------------------------------------------- # Test Class for purge_all #-----------------------------------------------------------------------------
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import requests import responses from ibm_cloud_cis_services.user_agent_blocking_rules_v1 import UserAgentBlockingRulesV1 crn = 'testString' zone_identifier = 'testString' service = UserAgentBlockingRulesV1(authenticator=NoAuthAuthenticator(), crn=crn, zone_identifier=zone_identifier) base_url = 'https://api.cis.cloud.ibm.com' service.set_service_url(base_url) ############################################################################## # Start of Service: ListAllUserAgentBlockingRules ############################################################################## # region #----------------------------------------------------------------------------- # Test Class for list_all_zone_user_agent_rules #-----------------------------------------------------------------------------
def call_service(self, body): service = NaturalLanguageClassifierV1( authenticator=NoAuthAuthenticator(), ) service.set_service_url(base_url) output = service.classify(**body) return output
# See the License for the specific language governing permissions and # limitations under the License. """ Unit Tests for IbmCloudCodeEngineV1 """ from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import re import responses import urllib from ibm_code_engine_sdk.ibm_cloud_code_engine_v1 import * service = IbmCloudCodeEngineV1(authenticator=NoAuthAuthenticator()) base_url = 'https://ibm-cloud-code-engine.cloud.ibm.com/api/v1' service.set_service_url(base_url) ############################################################################## # Start of Service: GetKubeconfig ############################################################################## # region class TestListKubeconfig(): """ Test Class for list_kubeconfig """ def preprocess_url(self, request_url: str):
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. from datetime import datetime, timezone from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import responses from ibm_cloud_cis_services import CustomPagesV1 crn = 'testString' zone_identifier = 'testString' service = CustomPagesV1(authenticator=NoAuthAuthenticator(), crn=crn, zone_identifier=zone_identifier) base_url = 'https://api.cis.cloud.ibm.com' service.set_service_url(base_url) ############################################################################## # Start of Service: ListInstanceCustomPages ############################################################################## # region #----------------------------------------------------------------------------- # Test Class for list_instance_custom_pages #-----------------------------------------------------------------------------
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import requests import responses from ibm_cloud_cis_services.waf_rules_api_v1 import WafRulesApiV1 crn = 'testString' zone_id = 'testString' service = WafRulesApiV1(authenticator=NoAuthAuthenticator(), crn=crn, zone_id=zone_id) base_url = 'https://api.cis.cloud.ibm.com' service.set_service_url(base_url) ############################################################################## # Start of Service: ListWAFRules ############################################################################## # region #----------------------------------------------------------------------------- # Test Class for list_waf_rules #-----------------------------------------------------------------------------
""" from datetime import datetime, timezone from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator from ibm_cloud_sdk_core.utils import datetime_to_string, string_to_datetime import inspect import io import json import pytest import re import responses import tempfile import urllib from ibm_watson.natural_language_classifier_v1 import * _service = NaturalLanguageClassifierV1(authenticator=NoAuthAuthenticator()) _base_url = 'https://api.us-south.natural-language-classifier.watson.cloud.ibm.com' _service.set_service_url(_base_url) ############################################################################## # Start of Service: ClassifyText ############################################################################## # region class TestClassify(): """ Test Class for classify """ def preprocess_url(self, request_url: str):
# limitations under the License. from datetime import datetime, timezone from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import re import requests import responses from ibm_cloud_networking_services.range_applications_v1 import * crn = 'testString' zone_identifier = 'testString' service = RangeApplicationsV1(authenticator=NoAuthAuthenticator(), crn=crn, zone_identifier=zone_identifier) base_url = 'https://api.cis.cloud.ibm.com' service.set_service_url(base_url) ############################################################################## # Start of Service: RangeApplications ############################################################################## # region #----------------------------------------------------------------------------- # Test Class for list_range_apps #-----------------------------------------------------------------------------
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. from datetime import datetime, timezone from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import re import responses from ibm_cloud_networking_services.global_load_balancer_events_v1 import * crn = 'testString' service = GlobalLoadBalancerEventsV1(authenticator=NoAuthAuthenticator(), crn=crn) base_url = 'https://api.cis.cloud.ibm.com' service.set_service_url(base_url) ############################################################################## # Start of Service: GlobalLoadBalancerEvents ############################################################################## # region #----------------------------------------------------------------------------- # Test Class for get_load_balancer_events #----------------------------------------------------------------------------- class TestGetLoadBalancerEvents():
# limitations under the License. from ibm_cloud_sdk_core.authenticators.no_auth_authenticator import NoAuthAuthenticator import inspect import json import pytest import re import requests import responses from ibm_cloud_networking_services.waf_rules_api_v1 import * crn = 'testString' zone_id = 'testString' service = WafRulesApiV1( authenticator=NoAuthAuthenticator(), crn=crn, zone_id=zone_id ) base_url = 'https://api.cis.cloud.ibm.com' service.set_service_url(base_url) ############################################################################## # Start of Service: WAFRules ############################################################################## # region #----------------------------------------------------------------------------- # Test Class for list_waf_rules #-----------------------------------------------------------------------------
def call_service(self, body): service = NotificationsApiV1(authenticator=NoAuthAuthenticator(), ) service.set_service_url(base_url) output = service.test_notification_channel(**body) return output