diff --git a/.openapi-generator/FILES b/.openapi-generator/FILES index eafc4093..f405fa0d 100644 --- a/.openapi-generator/FILES +++ b/.openapi-generator/FILES @@ -297,7 +297,104 @@ lib/freeclimb/models/update_conference_participant_request.rb lib/freeclimb/models/update_conference_request.rb lib/freeclimb/models/update_conference_request_status.rb lib/freeclimb/version.rb -spec/api/default_api_spec.rb spec/api_client_spec.rb spec/configuration_spec.rb +spec/models/account_request_spec.rb +spec/models/account_result_spec.rb +spec/models/account_status_spec.rb +spec/models/account_type_spec.rb +spec/models/add_to_conference_spec.rb +spec/models/answered_by_spec.rb +spec/models/application_list_spec.rb +spec/models/application_request_spec.rb +spec/models/application_result_spec.rb +spec/models/available_number_list_spec.rb +spec/models/available_number_spec.rb +spec/models/buy_incoming_number_request_spec.rb +spec/models/call_direction_spec.rb +spec/models/call_list_spec.rb +spec/models/call_result_spec.rb +spec/models/call_status_spec.rb +spec/models/capabilities_spec.rb +spec/models/conference_list_spec.rb +spec/models/conference_participant_list_spec.rb +spec/models/conference_participant_result_spec.rb +spec/models/conference_result_spec.rb +spec/models/conference_status_spec.rb +spec/models/create_conference_request_spec.rb +spec/models/create_conference_spec.rb +spec/models/create_web_rtc_token_spec.rb +spec/models/dequeue_spec.rb +spec/models/enqueue_spec.rb +spec/models/filter_logs_request_spec.rb +spec/models/get_digits_spec.rb +spec/models/get_speech_reason_spec.rb +spec/models/get_speech_spec.rb +spec/models/grammar_file_built_in_spec.rb +spec/models/grammar_type_spec.rb +spec/models/hangup_spec.rb +spec/models/if_machine_spec.rb +spec/models/incoming_number_list_spec.rb +spec/models/incoming_number_request_spec.rb +spec/models/incoming_number_result_spec.rb +spec/models/language_spec.rb +spec/models/log_level_spec.rb +spec/models/log_list_spec.rb +spec/models/log_result_spec.rb +spec/models/machine_type_spec.rb +spec/models/make_call_request_spec.rb +spec/models/message_direction_spec.rb +spec/models/message_request_spec.rb +spec/models/message_result_spec.rb +spec/models/message_status_spec.rb +spec/models/messages_list_spec.rb +spec/models/mutable_resource_model_spec.rb +spec/models/out_dial_spec.rb +spec/models/pagination_model_spec.rb +spec/models/park_spec.rb +spec/models/pause_spec.rb +spec/models/percl_command_spec.rb +spec/models/percl_script_spec.rb +spec/models/play_beep_spec.rb +spec/models/play_early_media_spec.rb +spec/models/play_spec.rb +spec/models/queue_list_spec.rb +spec/models/queue_member_list_spec.rb +spec/models/queue_member_spec.rb +spec/models/queue_request_spec.rb +spec/models/queue_result_spec.rb +spec/models/queue_result_status_spec.rb +spec/models/record_utterance_spec.rb +spec/models/record_utterance_term_reason_spec.rb +spec/models/recording_list_spec.rb +spec/models/recording_result_spec.rb +spec/models/redirect_spec.rb +spec/models/reject_spec.rb +spec/models/remove_from_conference_spec.rb +spec/models/request_type_spec.rb +spec/models/say_spec.rb +spec/models/send_digits_spec.rb +spec/models/set_listen_spec.rb +spec/models/set_talk_spec.rb +spec/models/sms_spec.rb +spec/models/sms_ten_dlc_brand_spec.rb +spec/models/sms_ten_dlc_brands_list_result_spec.rb +spec/models/sms_ten_dlc_campaign_spec.rb +spec/models/sms_ten_dlc_campaigns_list_result_spec.rb +spec/models/sms_ten_dlc_partner_campaign_brand_spec.rb +spec/models/sms_ten_dlc_partner_campaign_spec.rb +spec/models/sms_ten_dlc_partner_campaigns_list_result_spec.rb +spec/models/sms_toll_free_campaign_spec.rb +spec/models/sms_toll_free_campaigns_list_result_spec.rb +spec/models/start_record_call_spec.rb +spec/models/terminate_conference_spec.rb +spec/models/tfn_spec.rb +spec/models/transcribe_utterance_all_of_record_spec.rb +spec/models/transcribe_utterance_spec.rb +spec/models/unpark_spec.rb +spec/models/update_call_request_spec.rb +spec/models/update_call_request_status_spec.rb +spec/models/update_conference_participant_request_spec.rb +spec/models/update_conference_request_spec.rb +spec/models/update_conference_request_status_spec.rb spec/spec_helper.rb diff --git a/spec/models/account_request_spec.rb b/spec/models/account_request_spec.rb index 678f6be7..e8cb9344 100644 --- a/spec/models/account_request_spec.rb +++ b/spec/models/account_request_spec.rb @@ -44,9 +44,7 @@ it 'properly initializes with values' do expect{instance = Freeclimb::AccountRequest.new( _alias: "TS", - label: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::AccountRequest' do @@ -64,7 +62,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::AccountRequest.new( @@ -76,6 +74,18 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::AccountRequest.new( + _alias: "TS", + label: "TS", + ) + instance_2 = Freeclimb::AccountRequest.new( + _alias: "TS", + label: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/account_result_spec.rb b/spec/models/account_result_spec.rb index bd165cdb..d96a314f 100644 --- a/spec/models/account_result_spec.rb +++ b/spec/models/account_result_spec.rb @@ -125,28 +125,15 @@ it 'properly initializes with values' do expect{instance = Freeclimb::AccountResult.new( uri: "TS", - date_created: "TS", - date_updated: "TS", - -revision: 1, - + revision: 1, account_id: "TS", - api_key: "TS", - _alias: "TS", - label: "TS", - - type: Freeclimb::AccountType.new(), - type: "TRIAL", - status: Freeclimb::AccountStatus.new(), - status: "CLOSED", - subresource_uris: Object.new(), )}.not_to raise_error() end @@ -155,14 +142,12 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", api_key: "TS", _alias: "TS", label: "TS", - type: Freeclimb::AccountType.new(), type: "TRIAL", - status: Freeclimb::AccountStatus.new(), status: "CLOSED", subresource_uris: Object.new(), invalid_attribute: true @@ -173,35 +158,31 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", api_key: "TS", _alias: "TS", label: "TS", - type: Freeclimb::AccountType.new(), type: "TRIAL", - status: Freeclimb::AccountStatus.new(), status: "CLOSED", subresource_uris: Object.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::AccountResult.new( uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", api_key: "TS", _alias: "TS", label: "TS", - type: Freeclimb::AccountType.new(), type: "TRIAL", - status: Freeclimb::AccountStatus.new(), status: "CLOSED", subresource_uris: Object.new(), ) @@ -210,6 +191,40 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::AccountResult.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + account_id: "TS", + api_key: "TS", + _alias: "TS", + label: "TS", + type: Freeclimb::AccountType.new(), + type: "TRIAL", + status: Freeclimb::AccountStatus.new(), + status: "CLOSED", + subresource_uris: obj, + ) + instance_2 = Freeclimb::AccountResult.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + account_id: "TS", + api_key: "TS", + _alias: "TS", + label: "TS", + type: Freeclimb::AccountType.new(), + type: "TRIAL", + status: Freeclimb::AccountStatus.new(), + status: "CLOSED", + subresource_uris: obj, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -218,14 +233,12 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", api_key: "TS", _alias: "TS", label: "TS", - type: Freeclimb::AccountType.new(), type: "TRIAL", - status: Freeclimb::AccountStatus.new(), status: "CLOSED", subresource_uris: Object.new(), ) @@ -239,14 +252,12 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", api_key: "TS", _alias: "TS", label: "TS", - type: Freeclimb::AccountType.new(), type: "TRIAL", - status: Freeclimb::AccountStatus.new(), status: "CLOSED", subresource_uris: Object.new(), ) @@ -260,14 +271,12 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", api_key: "TS", _alias: "TS", label: "TS", - type: Freeclimb::AccountType.new(), type: "TRIAL", - status: Freeclimb::AccountStatus.new(), status: "CLOSED", subresource_uris: Object.new(), ) @@ -311,9 +320,7 @@ api_key: "TS", _alias: "TS", label: "TS", - type: Freeclimb::AccountType.new(), type: "TRIAL", - status: Freeclimb::AccountStatus.new(), status: "CLOSED", subresource_uris: Object.new(), ) @@ -332,9 +339,7 @@ api_key: "TS", _alias: "TS", label: "TS", - type: Freeclimb::AccountType.new(), type: "TRIAL", - status: Freeclimb::AccountStatus.new(), status: "CLOSED", subresource_uris: Object.new(), ) @@ -351,9 +356,7 @@ api_key: "TS", _alias: "TS", label: "TS", - type: Freeclimb::AccountType.new(), type: "TRIAL", - status: Freeclimb::AccountStatus.new(), status: "CLOSED", subresource_uris: obj, ) @@ -366,9 +369,7 @@ api_key: "TS", _alias: "TS", label: "TS", - type: Freeclimb::AccountType.new(), type: "TRIAL", - status: Freeclimb::AccountStatus.new(), status: "CLOSED", subresource_uris: obj, ) diff --git a/spec/models/add_to_conference_spec.rb b/spec/models/add_to_conference_spec.rb index 42d54233..744d3092 100644 --- a/spec/models/add_to_conference_spec.rb +++ b/spec/models/add_to_conference_spec.rb @@ -93,23 +93,14 @@ it 'properly initializes with values' do expect{instance = Freeclimb::AddToConference.new( allow_call_control: true, - call_control_sequence: "TS", - call_control_url: "TS", - conference_id: "TS", - leave_conference_url: "TS", - listen: true, - notification_url: "TS", - start_conf_on_enter: true, - talk: true, - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::AddToConference' do @@ -141,7 +132,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::AddToConference.new( @@ -160,6 +151,32 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::AddToConference.new( + allow_call_control: true, + call_control_sequence: "TS", + call_control_url: "TS", + conference_id: "TS", + leave_conference_url: "TS", + listen: true, + notification_url: "TS", + start_conf_on_enter: true, + talk: true, + ) + instance_2 = Freeclimb::AddToConference.new( + allow_call_control: true, + call_control_sequence: "TS", + call_control_url: "TS", + conference_id: "TS", + leave_conference_url: "TS", + listen: true, + notification_url: "TS", + start_conf_on_enter: true, + talk: true, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/application_list_spec.rb b/spec/models/application_list_spec.rb index af5a0f0c..ab03a398 100644 --- a/spec/models/application_list_spec.rb +++ b/spec/models/application_list_spec.rb @@ -103,65 +103,54 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::ApplicationList.new( -total: 1, - -start: 1, - -_end: 1, - -page: 1, - -num_pages: 1, - -page_size: 1, - + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - - applications: Freeclimb::ApplicationResult.new(), - + applications: Array.new(), )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::ApplicationList' do expect{instance = Freeclimb::ApplicationList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - applications: Freeclimb::ApplicationResult.new(), applications: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::ApplicationList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - applications: Freeclimb::ApplicationResult.new(), applications: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::ApplicationList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - applications: Freeclimb::ApplicationResult.new(), applications: Array.new(), ) expect(instance.valid?).to eq(true) @@ -169,19 +158,44 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::ApplicationList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + applications: Freeclimb::ApplicationResult.new(), + applications: [], + ) + instance_2 = Freeclimb::ApplicationList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + applications: Freeclimb::ApplicationResult.new(), + applications: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::ApplicationList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - applications: Freeclimb::ApplicationResult.new(), applications: Array.new(), ) expect(instance.hash).to be_a_kind_of(Integer) @@ -191,14 +205,13 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::ApplicationList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - applications: Freeclimb::ApplicationResult.new(), applications: Array.new(), ) instance_2 = Freeclimb::ApplicationList.new @@ -208,14 +221,13 @@ describe 'test method "_deserialize"' do instance = Freeclimb::ApplicationList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - applications: Freeclimb::ApplicationResult.new(), applications: Array.new(), ) it 'deserializes the data of total' do @@ -254,7 +266,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - applications: Freeclimb::ApplicationResult.new(), applications: Array.new(), ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -271,7 +282,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - applications: Freeclimb::ApplicationResult.new(), applications: Array.new(), ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -286,7 +296,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - applications: Freeclimb::ApplicationResult.new(), applications: Array.new(), ) instance_2 = Freeclimb::ApplicationList.new( @@ -297,7 +306,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - applications: Freeclimb::ApplicationResult.new(), applications: Array.new(), ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/application_request_spec.rb b/spec/models/application_request_spec.rb index 3abf1774..238a31e0 100644 --- a/spec/models/application_request_spec.rb +++ b/spec/models/application_request_spec.rb @@ -79,19 +79,12 @@ it 'properly initializes with values' do expect{instance = Freeclimb::ApplicationRequest.new( _alias: "TS", - voice_url: "TS", - voice_fallback_url: "TS", - call_connect_url: "TS", - status_callback_url: "TS", - sms_url: "TS", - sms_fallback_url: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::ApplicationRequest' do @@ -119,7 +112,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::ApplicationRequest.new( @@ -136,6 +129,28 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::ApplicationRequest.new( + _alias: "TS", + voice_url: "TS", + voice_fallback_url: "TS", + call_connect_url: "TS", + status_callback_url: "TS", + sms_url: "TS", + sms_fallback_url: "TS", + ) + instance_2 = Freeclimb::ApplicationRequest.new( + _alias: "TS", + voice_url: "TS", + voice_fallback_url: "TS", + call_connect_url: "TS", + status_callback_url: "TS", + sms_url: "TS", + sms_fallback_url: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/application_result_spec.rb b/spec/models/application_result_spec.rb index 06b83829..e95be816 100644 --- a/spec/models/application_result_spec.rb +++ b/spec/models/application_result_spec.rb @@ -124,31 +124,18 @@ it 'properly initializes with values' do expect{instance = Freeclimb::ApplicationResult.new( uri: "TS", - date_created: "TS", - date_updated: "TS", - -revision: 1, - + revision: 1, account_id: "TS", - application_id: "TS", - _alias: "TS", - voice_url: "TS", - voice_fallback_url: "TS", - call_connect_url: "TS", - status_callback_url: "TS", - sms_url: "TS", - sms_fallback_url: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::ApplicationResult' do @@ -156,7 +143,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", application_id: "TS", _alias: "TS", @@ -174,7 +161,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", application_id: "TS", _alias: "TS", @@ -188,14 +175,14 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::ApplicationResult.new( uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", application_id: "TS", _alias: "TS", @@ -211,6 +198,40 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::ApplicationResult.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + account_id: "TS", + application_id: "TS", + _alias: "TS", + voice_url: "TS", + voice_fallback_url: "TS", + call_connect_url: "TS", + status_callback_url: "TS", + sms_url: "TS", + sms_fallback_url: "TS", + ) + instance_2 = Freeclimb::ApplicationResult.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + account_id: "TS", + application_id: "TS", + _alias: "TS", + voice_url: "TS", + voice_fallback_url: "TS", + call_connect_url: "TS", + status_callback_url: "TS", + sms_url: "TS", + sms_fallback_url: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -219,7 +240,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", application_id: "TS", _alias: "TS", @@ -240,7 +261,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", application_id: "TS", _alias: "TS", @@ -261,7 +282,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", application_id: "TS", _alias: "TS", diff --git a/spec/models/available_number_list_spec.rb b/spec/models/available_number_list_spec.rb index 6cbf2559..2d675963 100644 --- a/spec/models/available_number_list_spec.rb +++ b/spec/models/available_number_list_spec.rb @@ -103,65 +103,54 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::AvailableNumberList.new( -total: 1, - -start: 1, - -_end: 1, - -page: 1, - -num_pages: 1, - -page_size: 1, - + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - - available_phone_numbers: Freeclimb::AvailableNumber.new(), - + available_phone_numbers: Array.new(), )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::AvailableNumberList' do expect{instance = Freeclimb::AvailableNumberList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - available_phone_numbers: Freeclimb::AvailableNumber.new(), available_phone_numbers: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::AvailableNumberList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - available_phone_numbers: Freeclimb::AvailableNumber.new(), available_phone_numbers: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::AvailableNumberList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - available_phone_numbers: Freeclimb::AvailableNumber.new(), available_phone_numbers: Array.new(), ) expect(instance.valid?).to eq(true) @@ -169,19 +158,44 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::AvailableNumberList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + available_phone_numbers: Freeclimb::AvailableNumber.new(), + available_phone_numbers: [], + ) + instance_2 = Freeclimb::AvailableNumberList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + available_phone_numbers: Freeclimb::AvailableNumber.new(), + available_phone_numbers: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::AvailableNumberList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - available_phone_numbers: Freeclimb::AvailableNumber.new(), available_phone_numbers: Array.new(), ) expect(instance.hash).to be_a_kind_of(Integer) @@ -191,14 +205,13 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::AvailableNumberList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - available_phone_numbers: Freeclimb::AvailableNumber.new(), available_phone_numbers: Array.new(), ) instance_2 = Freeclimb::AvailableNumberList.new @@ -208,14 +221,13 @@ describe 'test method "_deserialize"' do instance = Freeclimb::AvailableNumberList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - available_phone_numbers: Freeclimb::AvailableNumber.new(), available_phone_numbers: Array.new(), ) it 'deserializes the data of total' do @@ -254,7 +266,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - available_phone_numbers: Freeclimb::AvailableNumber.new(), available_phone_numbers: Array.new(), ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -271,7 +282,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - available_phone_numbers: Freeclimb::AvailableNumber.new(), available_phone_numbers: Array.new(), ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -286,7 +296,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - available_phone_numbers: Freeclimb::AvailableNumber.new(), available_phone_numbers: Array.new(), ) instance_2 = Freeclimb::AvailableNumberList.new( @@ -297,7 +306,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - available_phone_numbers: Freeclimb::AvailableNumber.new(), available_phone_numbers: Array.new(), ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/available_number_spec.rb b/spec/models/available_number_spec.rb index 39c7eb57..778b3806 100644 --- a/spec/models/available_number_spec.rb +++ b/spec/models/available_number_spec.rb @@ -79,25 +79,16 @@ it 'properly initializes with values' do expect{instance = Freeclimb::AvailableNumber.new( capabilities: Freeclimb::Capabilities.new(), - - capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", - phone_number: "TS", - voice_enabled: true, - sms_enabled: true, - region: "TS", - country: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::AvailableNumber' do expect{instance = Freeclimb::AvailableNumber.new( - capabilities: Freeclimb::Capabilities.new(), capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number: "TS", @@ -110,7 +101,6 @@ end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::AvailableNumber.new( - capabilities: Freeclimb::Capabilities.new(), capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number: "TS", @@ -122,12 +112,11 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::AvailableNumber.new( capabilities: Freeclimb::Capabilities.new(), - capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number: "TS", voice_enabled: true, @@ -140,13 +129,34 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::AvailableNumber.new( + capabilities: Freeclimb::Capabilities.new(), + campaign_id: "TS", + phone_number: "TS", + voice_enabled: true, + sms_enabled: true, + region: "TS", + country: "TS", + ) + instance_2 = Freeclimb::AvailableNumber.new( + capabilities: Freeclimb::Capabilities.new(), + campaign_id: "TS", + phone_number: "TS", + voice_enabled: true, + sms_enabled: true, + region: "TS", + country: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::AvailableNumber.new( capabilities: Freeclimb::Capabilities.new(), - capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number: "TS", voice_enabled: true, @@ -162,7 +172,6 @@ it 'builds equivalent model from hash code' do instance_1 = Freeclimb::AvailableNumber.new( capabilities: Freeclimb::Capabilities.new(), - capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number: "TS", voice_enabled: true, @@ -177,7 +186,6 @@ describe 'test method "_deserialize"' do instance = Freeclimb::AvailableNumber.new( - capabilities: Freeclimb::Capabilities.new(), capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number: "TS", @@ -212,7 +220,6 @@ describe 'test method "to_s"' do it 'returns the string representation of the object' do instance = Freeclimb::AvailableNumber.new( - capabilities: Freeclimb::Capabilities.new(), capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number: "TS", @@ -228,7 +235,6 @@ describe 'test method "to_hash"' do it 'returns the object in the form of hash' do instance = Freeclimb::AvailableNumber.new( - capabilities: Freeclimb::Capabilities.new(), capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number: "TS", @@ -242,7 +248,6 @@ it 'creates equal hash for two equal objects' do obj = Object.new() instance_1 = Freeclimb::AvailableNumber.new( - capabilities: Freeclimb::Capabilities.new(), capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number: "TS", @@ -252,7 +257,6 @@ country: "TS", ) instance_2 = Freeclimb::AvailableNumber.new( - capabilities: Freeclimb::Capabilities.new(), capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number: "TS", diff --git a/spec/models/buy_incoming_number_request_spec.rb b/spec/models/buy_incoming_number_request_spec.rb index caf83393..16067ff3 100644 --- a/spec/models/buy_incoming_number_request_spec.rb +++ b/spec/models/buy_incoming_number_request_spec.rb @@ -51,11 +51,8 @@ it 'properly initializes with values' do expect{instance = Freeclimb::BuyIncomingNumberRequest.new( phone_number: "TS", - _alias: "TS", - application_id: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::BuyIncomingNumberRequest' do @@ -75,7 +72,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::BuyIncomingNumberRequest.new( @@ -88,6 +85,20 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::BuyIncomingNumberRequest.new( + phone_number: "TS", + _alias: "TS", + application_id: "TS", + ) + instance_2 = Freeclimb::BuyIncomingNumberRequest.new( + phone_number: "TS", + _alias: "TS", + application_id: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/call_list_spec.rb b/spec/models/call_list_spec.rb index 0e18e9ea..3452ab22 100644 --- a/spec/models/call_list_spec.rb +++ b/spec/models/call_list_spec.rb @@ -103,65 +103,54 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::CallList.new( -total: 1, - -start: 1, - -_end: 1, - -page: 1, - -num_pages: 1, - -page_size: 1, - + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - - calls: Freeclimb::CallResult.new(), - + calls: Array.new(), )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::CallList' do expect{instance = Freeclimb::CallList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - calls: Freeclimb::CallResult.new(), calls: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::CallList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - calls: Freeclimb::CallResult.new(), calls: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::CallList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - calls: Freeclimb::CallResult.new(), calls: Array.new(), ) expect(instance.valid?).to eq(true) @@ -169,19 +158,44 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::CallList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + calls: Freeclimb::CallResult.new(), + calls: [], + ) + instance_2 = Freeclimb::CallList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + calls: Freeclimb::CallResult.new(), + calls: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::CallList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - calls: Freeclimb::CallResult.new(), calls: Array.new(), ) expect(instance.hash).to be_a_kind_of(Integer) @@ -191,14 +205,13 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::CallList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - calls: Freeclimb::CallResult.new(), calls: Array.new(), ) instance_2 = Freeclimb::CallList.new @@ -208,14 +221,13 @@ describe 'test method "_deserialize"' do instance = Freeclimb::CallList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - calls: Freeclimb::CallResult.new(), calls: Array.new(), ) it 'deserializes the data of total' do @@ -254,7 +266,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - calls: Freeclimb::CallResult.new(), calls: Array.new(), ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -271,7 +282,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - calls: Freeclimb::CallResult.new(), calls: Array.new(), ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -286,7 +296,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - calls: Freeclimb::CallResult.new(), calls: Array.new(), ) instance_2 = Freeclimb::CallList.new( @@ -297,7 +306,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - calls: Freeclimb::CallResult.new(), calls: Array.new(), ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/call_result_spec.rb b/spec/models/call_result_spec.rb index 92a57ccd..b9bf36a6 100644 --- a/spec/models/call_result_spec.rb +++ b/spec/models/call_result_spec.rb @@ -216,45 +216,23 @@ it 'properly initializes with values' do expect{instance = Freeclimb::CallResult.new( uri: "TS", - date_created: "TS", - date_updated: "TS", - -revision: 1, - + revision: 1, call_id: "TS", - parent_call_id: "TS", - account_id: "TS", - from: "TS", - to: "TS", - phone_number_id: "TS", - - call_status: Freeclimb::CallStatus.new(), - call_status: "QUEUED", start_time: "TS", - connect_time: "TS", - end_time: "TS", - -duration: 1, - -connect_duration: 1, - - direction: Freeclimb::CallDirection.new(), - + duration: 1, + connect_duration: 1, direction: "INBOUND", - answered_by: Freeclimb::AnsweredBy.new(), - answered_by: "HUMAN", - subresource_uris: Object.new(), )}.not_to raise_error() end @@ -263,23 +241,20 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, call_id: "TS", parent_call_id: "TS", account_id: "TS", from: "TS", to: "TS", phone_number_id: "TS", - call_status: Freeclimb::CallStatus.new(), call_status: "QUEUED", start_time: "TS", connect_time: "TS", end_time: "TS", -duration: 1, -connect_duration: 1, - direction: Freeclimb::CallDirection.new(), + duration: 1, + connect_duration: 1, direction: "INBOUND", - answered_by: Freeclimb::AnsweredBy.new(), answered_by: "HUMAN", subresource_uris: Object.new(), invalid_attribute: true @@ -290,53 +265,47 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, call_id: "TS", parent_call_id: "TS", account_id: "TS", from: "TS", to: "TS", phone_number_id: "TS", - call_status: Freeclimb::CallStatus.new(), call_status: "QUEUED", start_time: "TS", connect_time: "TS", end_time: "TS", -duration: 1, -connect_duration: 1, - direction: Freeclimb::CallDirection.new(), + duration: 1, + connect_duration: 1, direction: "INBOUND", - answered_by: Freeclimb::AnsweredBy.new(), answered_by: "HUMAN", subresource_uris: Object.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::CallResult.new( uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, call_id: "TS", parent_call_id: "TS", account_id: "TS", from: "TS", to: "TS", phone_number_id: "TS", - call_status: Freeclimb::CallStatus.new(), call_status: "QUEUED", start_time: "TS", connect_time: "TS", end_time: "TS", -duration: 1, -connect_duration: 1, - direction: Freeclimb::CallDirection.new(), + duration: 1, + connect_duration: 1, direction: "INBOUND", - answered_by: Freeclimb::AnsweredBy.new(), answered_by: "HUMAN", subresource_uris: Object.new(), ) @@ -345,6 +314,58 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::CallResult.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + call_id: "TS", + parent_call_id: "TS", + account_id: "TS", + from: "TS", + to: "TS", + phone_number_id: "TS", + call_status: Freeclimb::CallStatus.new(), + call_status: "QUEUED", + start_time: "TS", + connect_time: "TS", + end_time: "TS", + duration: 1, + connect_duration: 1, + direction: Freeclimb::CallDirection.new(), + direction: "INBOUND", + answered_by: Freeclimb::AnsweredBy.new(), + answered_by: "HUMAN", + subresource_uris: obj, + ) + instance_2 = Freeclimb::CallResult.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + call_id: "TS", + parent_call_id: "TS", + account_id: "TS", + from: "TS", + to: "TS", + phone_number_id: "TS", + call_status: Freeclimb::CallStatus.new(), + call_status: "QUEUED", + start_time: "TS", + connect_time: "TS", + end_time: "TS", + duration: 1, + connect_duration: 1, + direction: Freeclimb::CallDirection.new(), + direction: "INBOUND", + answered_by: Freeclimb::AnsweredBy.new(), + answered_by: "HUMAN", + subresource_uris: obj, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -353,23 +374,20 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, call_id: "TS", parent_call_id: "TS", account_id: "TS", from: "TS", to: "TS", phone_number_id: "TS", - call_status: Freeclimb::CallStatus.new(), call_status: "QUEUED", start_time: "TS", connect_time: "TS", end_time: "TS", -duration: 1, -connect_duration: 1, - direction: Freeclimb::CallDirection.new(), + duration: 1, + connect_duration: 1, direction: "INBOUND", - answered_by: Freeclimb::AnsweredBy.new(), answered_by: "HUMAN", subresource_uris: Object.new(), ) @@ -383,23 +401,20 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, call_id: "TS", parent_call_id: "TS", account_id: "TS", from: "TS", to: "TS", phone_number_id: "TS", - call_status: Freeclimb::CallStatus.new(), call_status: "QUEUED", start_time: "TS", connect_time: "TS", end_time: "TS", -duration: 1, -connect_duration: 1, - direction: Freeclimb::CallDirection.new(), + duration: 1, + connect_duration: 1, direction: "INBOUND", - answered_by: Freeclimb::AnsweredBy.new(), answered_by: "HUMAN", subresource_uris: Object.new(), ) @@ -413,23 +428,20 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, call_id: "TS", parent_call_id: "TS", account_id: "TS", from: "TS", to: "TS", phone_number_id: "TS", - call_status: Freeclimb::CallStatus.new(), call_status: "QUEUED", start_time: "TS", connect_time: "TS", end_time: "TS", -duration: 1, -connect_duration: 1, - direction: Freeclimb::CallDirection.new(), + duration: 1, + connect_duration: 1, direction: "INBOUND", - answered_by: Freeclimb::AnsweredBy.new(), answered_by: "HUMAN", subresource_uris: Object.new(), ) @@ -496,16 +508,13 @@ from: "TS", to: "TS", phone_number_id: "TS", - call_status: Freeclimb::CallStatus.new(), call_status: "QUEUED", start_time: "TS", connect_time: "TS", end_time: "TS", duration: 1, connect_duration: 1, - direction: Freeclimb::CallDirection.new(), direction: "INBOUND", - answered_by: Freeclimb::AnsweredBy.new(), answered_by: "HUMAN", subresource_uris: Object.new(), ) @@ -526,16 +535,13 @@ from: "TS", to: "TS", phone_number_id: "TS", - call_status: Freeclimb::CallStatus.new(), call_status: "QUEUED", start_time: "TS", connect_time: "TS", end_time: "TS", duration: 1, connect_duration: 1, - direction: Freeclimb::CallDirection.new(), direction: "INBOUND", - answered_by: Freeclimb::AnsweredBy.new(), answered_by: "HUMAN", subresource_uris: Object.new(), ) @@ -554,16 +560,13 @@ from: "TS", to: "TS", phone_number_id: "TS", - call_status: Freeclimb::CallStatus.new(), call_status: "QUEUED", start_time: "TS", connect_time: "TS", end_time: "TS", duration: 1, connect_duration: 1, - direction: Freeclimb::CallDirection.new(), direction: "INBOUND", - answered_by: Freeclimb::AnsweredBy.new(), answered_by: "HUMAN", subresource_uris: obj, ) @@ -578,16 +581,13 @@ from: "TS", to: "TS", phone_number_id: "TS", - call_status: Freeclimb::CallStatus.new(), call_status: "QUEUED", start_time: "TS", connect_time: "TS", end_time: "TS", duration: 1, connect_duration: 1, - direction: Freeclimb::CallDirection.new(), direction: "INBOUND", - answered_by: Freeclimb::AnsweredBy.new(), answered_by: "HUMAN", subresource_uris: obj, ) diff --git a/spec/models/capabilities_spec.rb b/spec/models/capabilities_spec.rb index 34d46235..b7cd8865 100644 --- a/spec/models/capabilities_spec.rb +++ b/spec/models/capabilities_spec.rb @@ -65,15 +65,10 @@ it 'properly initializes with values' do expect{instance = Freeclimb::Capabilities.new( voice: true, - sms: true, - toll_free: true, - ten_dlc: true, - short_code: true, - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::Capabilities' do @@ -97,7 +92,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::Capabilities.new( @@ -112,6 +107,24 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::Capabilities.new( + voice: true, + sms: true, + toll_free: true, + ten_dlc: true, + short_code: true, + ) + instance_2 = Freeclimb::Capabilities.new( + voice: true, + sms: true, + toll_free: true, + ten_dlc: true, + short_code: true, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/conference_list_spec.rb b/spec/models/conference_list_spec.rb index 386bbc16..2e0e4717 100644 --- a/spec/models/conference_list_spec.rb +++ b/spec/models/conference_list_spec.rb @@ -103,65 +103,54 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::ConferenceList.new( -total: 1, - -start: 1, - -_end: 1, - -page: 1, - -num_pages: 1, - -page_size: 1, - + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - - conferences: Freeclimb::ConferenceResult.new(), - + conferences: Array.new(), )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::ConferenceList' do expect{instance = Freeclimb::ConferenceList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - conferences: Freeclimb::ConferenceResult.new(), conferences: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::ConferenceList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - conferences: Freeclimb::ConferenceResult.new(), conferences: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::ConferenceList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - conferences: Freeclimb::ConferenceResult.new(), conferences: Array.new(), ) expect(instance.valid?).to eq(true) @@ -169,19 +158,44 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::ConferenceList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + conferences: Freeclimb::ConferenceResult.new(), + conferences: [], + ) + instance_2 = Freeclimb::ConferenceList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + conferences: Freeclimb::ConferenceResult.new(), + conferences: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::ConferenceList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - conferences: Freeclimb::ConferenceResult.new(), conferences: Array.new(), ) expect(instance.hash).to be_a_kind_of(Integer) @@ -191,14 +205,13 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::ConferenceList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - conferences: Freeclimb::ConferenceResult.new(), conferences: Array.new(), ) instance_2 = Freeclimb::ConferenceList.new @@ -208,14 +221,13 @@ describe 'test method "_deserialize"' do instance = Freeclimb::ConferenceList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - conferences: Freeclimb::ConferenceResult.new(), conferences: Array.new(), ) it 'deserializes the data of total' do @@ -254,7 +266,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - conferences: Freeclimb::ConferenceResult.new(), conferences: Array.new(), ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -271,7 +282,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - conferences: Freeclimb::ConferenceResult.new(), conferences: Array.new(), ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -286,7 +296,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - conferences: Freeclimb::ConferenceResult.new(), conferences: Array.new(), ) instance_2 = Freeclimb::ConferenceList.new( @@ -297,7 +306,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - conferences: Freeclimb::ConferenceResult.new(), conferences: Array.new(), ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/conference_participant_list_spec.rb b/spec/models/conference_participant_list_spec.rb index 2ca128c6..84af1e11 100644 --- a/spec/models/conference_participant_list_spec.rb +++ b/spec/models/conference_participant_list_spec.rb @@ -103,65 +103,54 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::ConferenceParticipantList.new( -total: 1, - -start: 1, - -_end: 1, - -page: 1, - -num_pages: 1, - -page_size: 1, - + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - - participants: Freeclimb::ConferenceParticipantResult.new(), - + participants: Array.new(), )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::ConferenceParticipantList' do expect{instance = Freeclimb::ConferenceParticipantList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - participants: Freeclimb::ConferenceParticipantResult.new(), participants: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::ConferenceParticipantList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - participants: Freeclimb::ConferenceParticipantResult.new(), participants: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::ConferenceParticipantList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - participants: Freeclimb::ConferenceParticipantResult.new(), participants: Array.new(), ) expect(instance.valid?).to eq(true) @@ -169,19 +158,44 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::ConferenceParticipantList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + participants: Freeclimb::ConferenceParticipantResult.new(), + participants: [], + ) + instance_2 = Freeclimb::ConferenceParticipantList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + participants: Freeclimb::ConferenceParticipantResult.new(), + participants: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::ConferenceParticipantList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - participants: Freeclimb::ConferenceParticipantResult.new(), participants: Array.new(), ) expect(instance.hash).to be_a_kind_of(Integer) @@ -191,14 +205,13 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::ConferenceParticipantList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - participants: Freeclimb::ConferenceParticipantResult.new(), participants: Array.new(), ) instance_2 = Freeclimb::ConferenceParticipantList.new @@ -208,14 +221,13 @@ describe 'test method "_deserialize"' do instance = Freeclimb::ConferenceParticipantList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - participants: Freeclimb::ConferenceParticipantResult.new(), participants: Array.new(), ) it 'deserializes the data of total' do @@ -254,7 +266,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - participants: Freeclimb::ConferenceParticipantResult.new(), participants: Array.new(), ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -271,7 +282,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - participants: Freeclimb::ConferenceParticipantResult.new(), participants: Array.new(), ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -286,7 +296,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - participants: Freeclimb::ConferenceParticipantResult.new(), participants: Array.new(), ) instance_2 = Freeclimb::ConferenceParticipantList.new( @@ -297,7 +306,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - participants: Freeclimb::ConferenceParticipantResult.new(), participants: Array.new(), ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/conference_participant_result_spec.rb b/spec/models/conference_participant_result_spec.rb index 55529397..46fd5a8c 100644 --- a/spec/models/conference_participant_result_spec.rb +++ b/spec/models/conference_participant_result_spec.rb @@ -103,25 +103,15 @@ it 'properly initializes with values' do expect{instance = Freeclimb::ConferenceParticipantResult.new( uri: "TS", - date_created: "TS", - date_updated: "TS", - -revision: 1, - + revision: 1, account_id: "TS", - conference_id: "TS", - call_id: "TS", - talk: true, - listen: true, - start_conf_on_enter: true, - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::ConferenceParticipantResult' do @@ -129,7 +119,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", conference_id: "TS", call_id: "TS", @@ -144,7 +134,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", conference_id: "TS", call_id: "TS", @@ -155,14 +145,14 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::ConferenceParticipantResult.new( uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", conference_id: "TS", call_id: "TS", @@ -175,6 +165,34 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::ConferenceParticipantResult.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + account_id: "TS", + conference_id: "TS", + call_id: "TS", + talk: true, + listen: true, + start_conf_on_enter: true, + ) + instance_2 = Freeclimb::ConferenceParticipantResult.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + account_id: "TS", + conference_id: "TS", + call_id: "TS", + talk: true, + listen: true, + start_conf_on_enter: true, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -183,7 +201,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", conference_id: "TS", call_id: "TS", @@ -201,7 +219,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", conference_id: "TS", call_id: "TS", @@ -219,7 +237,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", conference_id: "TS", call_id: "TS", diff --git a/spec/models/conference_result_spec.rb b/spec/models/conference_result_spec.rb index e140a74f..439d8c90 100644 --- a/spec/models/conference_result_spec.rb +++ b/spec/models/conference_result_spec.rb @@ -158,34 +158,18 @@ it 'properly initializes with values' do expect{instance = Freeclimb::ConferenceResult.new( uri: "TS", - date_created: "TS", - date_updated: "TS", - -revision: 1, - + revision: 1, conference_id: "TS", - account_id: "TS", - _alias: "TS", - - play_beep: Freeclimb::PlayBeep.new(), - play_beep: "ALWAYS", record: true, - - status: Freeclimb::ConferenceStatus.new(), - status: "EMPTY", wait_url: "TS", - action_url: "TS", - status_callback_url: "TS", - - subresource_uris: Object.new(), )}.not_to raise_error() end @@ -194,14 +178,12 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, conference_id: "TS", account_id: "TS", _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, - status: Freeclimb::ConferenceStatus.new(), status: "EMPTY", wait_url: "TS", action_url: "TS", @@ -215,14 +197,12 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, conference_id: "TS", account_id: "TS", _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, - status: Freeclimb::ConferenceStatus.new(), status: "EMPTY", wait_url: "TS", action_url: "TS", @@ -232,21 +212,19 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::ConferenceResult.new( uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, conference_id: "TS", account_id: "TS", _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, - status: Freeclimb::ConferenceStatus.new(), status: "EMPTY", wait_url: "TS", action_url: "TS", @@ -258,6 +236,46 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::ConferenceResult.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + conference_id: "TS", + account_id: "TS", + _alias: "TS", + play_beep: Freeclimb::PlayBeep.new(), + play_beep: "ALWAYS", + record: true, + status: Freeclimb::ConferenceStatus.new(), + status: "EMPTY", + wait_url: "TS", + action_url: "TS", + status_callback_url: "TS", + subresource_uris: obj, + ) + instance_2 = Freeclimb::ConferenceResult.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + conference_id: "TS", + account_id: "TS", + _alias: "TS", + play_beep: Freeclimb::PlayBeep.new(), + play_beep: "ALWAYS", + record: true, + status: Freeclimb::ConferenceStatus.new(), + status: "EMPTY", + wait_url: "TS", + action_url: "TS", + status_callback_url: "TS", + subresource_uris: obj, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -266,14 +284,12 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, conference_id: "TS", account_id: "TS", _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, - status: Freeclimb::ConferenceStatus.new(), status: "EMPTY", wait_url: "TS", action_url: "TS", @@ -290,14 +306,12 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, conference_id: "TS", account_id: "TS", _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, - status: Freeclimb::ConferenceStatus.new(), status: "EMPTY", wait_url: "TS", action_url: "TS", @@ -314,14 +328,12 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, conference_id: "TS", account_id: "TS", _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, - status: Freeclimb::ConferenceStatus.new(), status: "EMPTY", wait_url: "TS", action_url: "TS", @@ -376,10 +388,8 @@ conference_id: "TS", account_id: "TS", _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, - status: Freeclimb::ConferenceStatus.new(), status: "EMPTY", wait_url: "TS", action_url: "TS", @@ -400,10 +410,8 @@ conference_id: "TS", account_id: "TS", _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, - status: Freeclimb::ConferenceStatus.new(), status: "EMPTY", wait_url: "TS", action_url: "TS", @@ -422,10 +430,8 @@ conference_id: "TS", account_id: "TS", _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, - status: Freeclimb::ConferenceStatus.new(), status: "EMPTY", wait_url: "TS", action_url: "TS", @@ -440,10 +446,8 @@ conference_id: "TS", account_id: "TS", _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, - status: Freeclimb::ConferenceStatus.new(), status: "EMPTY", wait_url: "TS", action_url: "TS", diff --git a/spec/models/create_conference_request_spec.rb b/spec/models/create_conference_request_spec.rb index 735091b5..644a39f4 100644 --- a/spec/models/create_conference_request_spec.rb +++ b/spec/models/create_conference_request_spec.rb @@ -78,22 +78,15 @@ it 'properly initializes with values' do expect{instance = Freeclimb::CreateConferenceRequest.new( _alias: "TS", - - play_beep: Freeclimb::PlayBeep.new(), - play_beep: "ALWAYS", record: true, - wait_url: "TS", - status_callback_url: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::CreateConferenceRequest' do expect{instance = Freeclimb::CreateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, wait_url: "TS", @@ -104,7 +97,6 @@ it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::CreateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, wait_url: "TS", @@ -113,12 +105,11 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::CreateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, wait_url: "TS", @@ -129,13 +120,32 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::CreateConferenceRequest.new( + _alias: "TS", + play_beep: Freeclimb::PlayBeep.new(), + play_beep: "ALWAYS", + record: true, + wait_url: "TS", + status_callback_url: "TS", + ) + instance_2 = Freeclimb::CreateConferenceRequest.new( + _alias: "TS", + play_beep: Freeclimb::PlayBeep.new(), + play_beep: "ALWAYS", + record: true, + wait_url: "TS", + status_callback_url: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::CreateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, wait_url: "TS", @@ -149,7 +159,6 @@ it 'builds equivalent model from hash code' do instance_1 = Freeclimb::CreateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, wait_url: "TS", @@ -163,7 +172,6 @@ describe 'test method "_deserialize"' do instance = Freeclimb::CreateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, wait_url: "TS", @@ -187,7 +195,6 @@ it 'returns the string representation of the object' do instance = Freeclimb::CreateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, wait_url: "TS", @@ -201,7 +208,6 @@ it 'returns the object in the form of hash' do instance = Freeclimb::CreateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, wait_url: "TS", @@ -213,7 +219,6 @@ obj = Object.new() instance_1 = Freeclimb::CreateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, wait_url: "TS", @@ -221,7 +226,6 @@ ) instance_2 = Freeclimb::CreateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, wait_url: "TS", diff --git a/spec/models/create_conference_spec.rb b/spec/models/create_conference_spec.rb index bd894360..a9996266 100644 --- a/spec/models/create_conference_spec.rb +++ b/spec/models/create_conference_spec.rb @@ -85,25 +85,17 @@ it 'properly initializes with values' do expect{instance = Freeclimb::CreateConference.new( action_url: "TS", - _alias: true, - - play_beep: Freeclimb::PlayBeep.new(), - play_beep: "ALWAYS", record: true, - status_callback_url: "TS", - wait_url: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::CreateConference' do expect{instance = Freeclimb::CreateConference.new( action_url: "TS", _alias: true, - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, status_callback_url: "TS", @@ -115,7 +107,6 @@ expect{instance = Freeclimb::CreateConference.new( action_url: "TS", _alias: true, - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, status_callback_url: "TS", @@ -124,13 +115,12 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::CreateConference.new( action_url: "TS", _alias: true, - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, status_callback_url: "TS", @@ -141,6 +131,28 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::CreateConference.new( + action_url: "TS", + _alias: true, + play_beep: Freeclimb::PlayBeep.new(), + play_beep: "ALWAYS", + record: true, + status_callback_url: "TS", + wait_url: "TS", + ) + instance_2 = Freeclimb::CreateConference.new( + action_url: "TS", + _alias: true, + play_beep: Freeclimb::PlayBeep.new(), + play_beep: "ALWAYS", + record: true, + status_callback_url: "TS", + wait_url: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -148,7 +160,6 @@ instance = Freeclimb::CreateConference.new( action_url: "TS", _alias: true, - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, status_callback_url: "TS", @@ -163,7 +174,6 @@ instance_1 = Freeclimb::CreateConference.new( action_url: "TS", _alias: true, - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, status_callback_url: "TS", @@ -178,7 +188,6 @@ instance = Freeclimb::CreateConference.new( action_url: "TS", _alias: true, - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, status_callback_url: "TS", @@ -206,7 +215,6 @@ instance = Freeclimb::CreateConference.new( action_url: "TS", _alias: true, - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, status_callback_url: "TS", @@ -221,7 +229,6 @@ instance = Freeclimb::CreateConference.new( action_url: "TS", _alias: true, - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, status_callback_url: "TS", @@ -234,7 +241,6 @@ instance_1 = Freeclimb::CreateConference.new( action_url: "TS", _alias: true, - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, status_callback_url: "TS", @@ -243,7 +249,6 @@ instance_2 = Freeclimb::CreateConference.new( action_url: "TS", _alias: true, - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", record: true, status_callback_url: "TS", diff --git a/spec/models/create_web_rtc_token_spec.rb b/spec/models/create_web_rtc_token_spec.rb index b04355a6..f0ce8d0b 100644 --- a/spec/models/create_web_rtc_token_spec.rb +++ b/spec/models/create_web_rtc_token_spec.rb @@ -54,18 +54,15 @@ it 'properly initializes with values' do expect{instance = Freeclimb::CreateWebRTCToken.new( to: "TS", - from: "TS", - -uses: 1, - + uses: 1, )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::CreateWebRTCToken' do expect{instance = Freeclimb::CreateWebRTCToken.new( to: "TS", from: "TS", -uses: 1, + uses: 1, invalid_attribute: true )}.to raise_error(ArgumentError) end @@ -73,24 +70,38 @@ expect{instance = Freeclimb::CreateWebRTCToken.new( to: "TS", from: "TS", -uses: 1, + uses: 1, invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::CreateWebRTCToken.new( to: "TS", from: "TS", -uses: 1, + uses: 1, ) expect(instance.valid?).to eq(true) end end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::CreateWebRTCToken.new( + to: "TS", + from: "TS", + uses: 1, + ) + instance_2 = Freeclimb::CreateWebRTCToken.new( + to: "TS", + from: "TS", + uses: 1, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -98,7 +109,7 @@ instance = Freeclimb::CreateWebRTCToken.new( to: "TS", from: "TS", -uses: 1, + uses: 1, ) expect(instance.hash).to be_a_kind_of(Integer) end @@ -109,7 +120,7 @@ instance_1 = Freeclimb::CreateWebRTCToken.new( to: "TS", from: "TS", -uses: 1, + uses: 1, ) instance_2 = Freeclimb::CreateWebRTCToken.new expect(instance_2.build_from_hash(instance_1.hash)).to eq(instance_1.build_from_hash(instance_1.hash)) @@ -120,7 +131,7 @@ instance = Freeclimb::CreateWebRTCToken.new( to: "TS", from: "TS", -uses: 1, + uses: 1, ) it 'deserializes the data of to' do expect(instance._deserialize("String", instance.to)).to be_a_kind_of(String) diff --git a/spec/models/enqueue_spec.rb b/spec/models/enqueue_spec.rb index 6d132bdb..a3dc46a9 100644 --- a/spec/models/enqueue_spec.rb +++ b/spec/models/enqueue_spec.rb @@ -58,13 +58,9 @@ it 'properly initializes with values' do expect{instance = Freeclimb::Enqueue.new( action_url: "TS", - notification_url: "TS", - queue_id: "TS", - wait_url: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::Enqueue' do @@ -86,7 +82,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::Enqueue.new( @@ -100,6 +96,22 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::Enqueue.new( + action_url: "TS", + notification_url: "TS", + queue_id: "TS", + wait_url: "TS", + ) + instance_2 = Freeclimb::Enqueue.new( + action_url: "TS", + notification_url: "TS", + queue_id: "TS", + wait_url: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/filter_logs_request_spec.rb b/spec/models/filter_logs_request_spec.rb index a1fc3b67..ee87c185 100644 --- a/spec/models/filter_logs_request_spec.rb +++ b/spec/models/filter_logs_request_spec.rb @@ -37,7 +37,6 @@ it 'properly initializes with values' do expect{instance = Freeclimb::FilterLogsRequest.new( pql: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::FilterLogsRequest' do @@ -53,7 +52,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::FilterLogsRequest.new( @@ -64,6 +63,16 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::FilterLogsRequest.new( + pql: "TS", + ) + instance_2 = Freeclimb::FilterLogsRequest.new( + pql: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/get_digits_spec.rb b/spec/models/get_digits_spec.rb index 80699cff..794c1bf3 100644 --- a/spec/models/get_digits_spec.rb +++ b/spec/models/get_digits_spec.rb @@ -105,35 +105,25 @@ it 'properly initializes with values' do expect{instance = Freeclimb::GetDigits.new( action_url: "TS", - -digit_timeout_ms: 1, - + digit_timeout_ms: 1, finish_on_key: "TS", - flush_buffer: true, - -initial_timeout_ms: 1, - -max_digits: 1, - -min_digits: 1, - - prompts: Freeclimb::PerclCommand.new(), - + initial_timeout_ms: 1, + max_digits: 1, + min_digits: 1, + prompts: Array.new(), privacy_mode: true, - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::GetDigits' do expect{instance = Freeclimb::GetDigits.new( action_url: "TS", -digit_timeout_ms: 1, + digit_timeout_ms: 1, finish_on_key: "TS", flush_buffer: true, -initial_timeout_ms: 1, -max_digits: 1, -min_digits: 1, - prompts: Freeclimb::PerclCommand.new(), + initial_timeout_ms: 1, + max_digits: 1, + min_digits: 1, prompts: Array.new(), privacy_mode: true, invalid_attribute: true @@ -142,31 +132,29 @@ it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::GetDigits.new( action_url: "TS", -digit_timeout_ms: 1, + digit_timeout_ms: 1, finish_on_key: "TS", flush_buffer: true, -initial_timeout_ms: 1, -max_digits: 1, -min_digits: 1, - prompts: Freeclimb::PerclCommand.new(), + initial_timeout_ms: 1, + max_digits: 1, + min_digits: 1, prompts: Array.new(), privacy_mode: true, invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::GetDigits.new( action_url: "TS", -digit_timeout_ms: 1, + digit_timeout_ms: 1, finish_on_key: "TS", flush_buffer: true, -initial_timeout_ms: 1, -max_digits: 1, -min_digits: 1, - prompts: Freeclimb::PerclCommand.new(), + initial_timeout_ms: 1, + max_digits: 1, + min_digits: 1, prompts: Array.new(), privacy_mode: true, ) @@ -175,19 +163,46 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::GetDigits.new( + action_url: "TS", + digit_timeout_ms: 1, + finish_on_key: "TS", + flush_buffer: true, + initial_timeout_ms: 1, + max_digits: 1, + min_digits: 1, + prompts: Freeclimb::PerclCommand.new(), + prompts: [], + privacy_mode: true, + ) + instance_2 = Freeclimb::GetDigits.new( + action_url: "TS", + digit_timeout_ms: 1, + finish_on_key: "TS", + flush_buffer: true, + initial_timeout_ms: 1, + max_digits: 1, + min_digits: 1, + prompts: Freeclimb::PerclCommand.new(), + prompts: [], + privacy_mode: true, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::GetDigits.new( action_url: "TS", -digit_timeout_ms: 1, + digit_timeout_ms: 1, finish_on_key: "TS", flush_buffer: true, -initial_timeout_ms: 1, -max_digits: 1, -min_digits: 1, - prompts: Freeclimb::PerclCommand.new(), + initial_timeout_ms: 1, + max_digits: 1, + min_digits: 1, prompts: Array.new(), privacy_mode: true, ) @@ -199,13 +214,12 @@ it 'builds equivalent model from hash code' do instance_1 = Freeclimb::GetDigits.new( action_url: "TS", -digit_timeout_ms: 1, + digit_timeout_ms: 1, finish_on_key: "TS", flush_buffer: true, -initial_timeout_ms: 1, -max_digits: 1, -min_digits: 1, - prompts: Freeclimb::PerclCommand.new(), + initial_timeout_ms: 1, + max_digits: 1, + min_digits: 1, prompts: Array.new(), privacy_mode: true, ) @@ -217,13 +231,12 @@ describe 'test method "_deserialize"' do instance = Freeclimb::GetDigits.new( action_url: "TS", -digit_timeout_ms: 1, + digit_timeout_ms: 1, finish_on_key: "TS", flush_buffer: true, -initial_timeout_ms: 1, -max_digits: 1, -min_digits: 1, - prompts: Freeclimb::PerclCommand.new(), + initial_timeout_ms: 1, + max_digits: 1, + min_digits: 1, prompts: Array.new(), privacy_mode: true, ) @@ -266,7 +279,6 @@ initial_timeout_ms: 1, max_digits: 1, min_digits: 1, - prompts: Freeclimb::PerclCommand.new(), prompts: Array.new(), privacy_mode: true, ) @@ -284,7 +296,6 @@ initial_timeout_ms: 1, max_digits: 1, min_digits: 1, - prompts: Freeclimb::PerclCommand.new(), prompts: Array.new(), privacy_mode: true, ) @@ -300,7 +311,6 @@ initial_timeout_ms: 1, max_digits: 1, min_digits: 1, - prompts: Freeclimb::PerclCommand.new(), prompts: Array.new(), privacy_mode: true, ) @@ -312,7 +322,6 @@ initial_timeout_ms: 1, max_digits: 1, min_digits: 1, - prompts: Freeclimb::PerclCommand.new(), prompts: Array.new(), privacy_mode: true, ) diff --git a/spec/models/get_speech_spec.rb b/spec/models/get_speech_spec.rb index faa98fb6..e94279d4 100644 --- a/spec/models/get_speech_spec.rb +++ b/spec/models/get_speech_spec.rb @@ -144,46 +144,30 @@ it 'properly initializes with values' do expect{instance = Freeclimb::GetSpeech.new( action_url: "TS", - - grammar_type: Freeclimb::GrammarType.new(), - grammar_type: "URL", grammar_file: "TS", - grammar_rule: "TS", - play_beep: true, - - prompts: Freeclimb::PerclCommand.new(), - -no_input_timeout_ms: 1, - -recognition_timeout_ms: 1, - - - -speech_complete_timeout_ms: 1, - -speech_incomplete_timeout_ms: 1, - + prompts: Array.new(), + no_input_timeout_ms: 1, + recognition_timeout_ms: 1, + speech_complete_timeout_ms: 1, + speech_incomplete_timeout_ms: 1, privacy_mode: true, - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::GetSpeech' do expect{instance = Freeclimb::GetSpeech.new( action_url: "TS", - grammar_type: Freeclimb::GrammarType.new(), grammar_type: "URL", grammar_file: "TS", grammar_rule: "TS", play_beep: true, - prompts: Freeclimb::PerclCommand.new(), prompts: Array.new(), -no_input_timeout_ms: 1, -recognition_timeout_ms: 1, -speech_complete_timeout_ms: 1, -speech_incomplete_timeout_ms: 1, + no_input_timeout_ms: 1, + recognition_timeout_ms: 1, + speech_complete_timeout_ms: 1, + speech_incomplete_timeout_ms: 1, privacy_mode: true, invalid_attribute: true )}.to raise_error(ArgumentError) @@ -191,40 +175,36 @@ it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::GetSpeech.new( action_url: "TS", - grammar_type: Freeclimb::GrammarType.new(), grammar_type: "URL", grammar_file: "TS", grammar_rule: "TS", play_beep: true, - prompts: Freeclimb::PerclCommand.new(), prompts: Array.new(), -no_input_timeout_ms: 1, -recognition_timeout_ms: 1, -speech_complete_timeout_ms: 1, -speech_incomplete_timeout_ms: 1, + no_input_timeout_ms: 1, + recognition_timeout_ms: 1, + speech_complete_timeout_ms: 1, + speech_incomplete_timeout_ms: 1, privacy_mode: true, invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::GetSpeech.new( action_url: "TS", - grammar_type: Freeclimb::GrammarType.new(), grammar_type: "URL", grammar_file: "TS", grammar_rule: "TS", play_beep: true, - prompts: Freeclimb::PerclCommand.new(), prompts: Array.new(), -no_input_timeout_ms: 1, -recognition_timeout_ms: 1, -confidence_threshold: 1, -sensitivity_level: 1, -speech_complete_timeout_ms: 1, -speech_incomplete_timeout_ms: 1, + no_input_timeout_ms: 1, + recognition_timeout_ms: 1, + confidence_threshold: 1, + sensitivity_level: 1, + speech_complete_timeout_ms: 1, + speech_incomplete_timeout_ms: 1, privacy_mode: true, ) expect(instance.valid?).to eq(true) @@ -232,23 +212,55 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::GetSpeech.new( + action_url: "TS", + grammar_type: Freeclimb::GrammarType.new(), + grammar_type: "URL", + grammar_file: "TS", + grammar_rule: "TS", + play_beep: true, + prompts: Freeclimb::PerclCommand.new(), + prompts: [], + no_input_timeout_ms: 1, + recognition_timeout_ms: 1, + speech_complete_timeout_ms: 1, + speech_incomplete_timeout_ms: 1, + privacy_mode: true, + ) + instance_2 = Freeclimb::GetSpeech.new( + action_url: "TS", + grammar_type: Freeclimb::GrammarType.new(), + grammar_type: "URL", + grammar_file: "TS", + grammar_rule: "TS", + play_beep: true, + prompts: Freeclimb::PerclCommand.new(), + prompts: [], + no_input_timeout_ms: 1, + recognition_timeout_ms: 1, + speech_complete_timeout_ms: 1, + speech_incomplete_timeout_ms: 1, + privacy_mode: true, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::GetSpeech.new( action_url: "TS", - grammar_type: Freeclimb::GrammarType.new(), grammar_type: "URL", grammar_file: "TS", grammar_rule: "TS", play_beep: true, - prompts: Freeclimb::PerclCommand.new(), prompts: Array.new(), -no_input_timeout_ms: 1, -recognition_timeout_ms: 1, -speech_complete_timeout_ms: 1, -speech_incomplete_timeout_ms: 1, + no_input_timeout_ms: 1, + recognition_timeout_ms: 1, + speech_complete_timeout_ms: 1, + speech_incomplete_timeout_ms: 1, privacy_mode: true, ) expect(instance.hash).to be_a_kind_of(Integer) @@ -259,17 +271,15 @@ it 'builds equivalent model from hash code' do instance_1 = Freeclimb::GetSpeech.new( action_url: "TS", - grammar_type: Freeclimb::GrammarType.new(), grammar_type: "URL", grammar_file: "TS", grammar_rule: "TS", play_beep: true, - prompts: Freeclimb::PerclCommand.new(), prompts: Array.new(), -no_input_timeout_ms: 1, -recognition_timeout_ms: 1, -speech_complete_timeout_ms: 1, -speech_incomplete_timeout_ms: 1, + no_input_timeout_ms: 1, + recognition_timeout_ms: 1, + speech_complete_timeout_ms: 1, + speech_incomplete_timeout_ms: 1, privacy_mode: true, ) instance_2 = Freeclimb::GetSpeech.new @@ -280,17 +290,15 @@ describe 'test method "_deserialize"' do instance = Freeclimb::GetSpeech.new( action_url: "TS", - grammar_type: Freeclimb::GrammarType.new(), grammar_type: "URL", grammar_file: "TS", grammar_rule: "TS", play_beep: true, - prompts: Freeclimb::PerclCommand.new(), prompts: Array.new(), -no_input_timeout_ms: 1, -recognition_timeout_ms: 1, -speech_complete_timeout_ms: 1, -speech_incomplete_timeout_ms: 1, + no_input_timeout_ms: 1, + recognition_timeout_ms: 1, + speech_complete_timeout_ms: 1, + speech_incomplete_timeout_ms: 1, privacy_mode: true, ) it 'deserializes the data of action_url' do @@ -335,12 +343,10 @@ it 'returns the string representation of the object' do instance = Freeclimb::GetSpeech.new( action_url: "TS", - grammar_type: Freeclimb::GrammarType.new(), grammar_type: "URL", grammar_file: "TS", grammar_rule: "TS", play_beep: true, - prompts: Freeclimb::PerclCommand.new(), prompts: Array.new(), no_input_timeout_ms: 1, recognition_timeout_ms: 1, @@ -356,12 +362,10 @@ it 'returns the object in the form of hash' do instance = Freeclimb::GetSpeech.new( action_url: "TS", - grammar_type: Freeclimb::GrammarType.new(), grammar_type: "URL", grammar_file: "TS", grammar_rule: "TS", play_beep: true, - prompts: Freeclimb::PerclCommand.new(), prompts: Array.new(), no_input_timeout_ms: 1, recognition_timeout_ms: 1, @@ -375,12 +379,10 @@ obj = Object.new() instance_1 = Freeclimb::GetSpeech.new( action_url: "TS", - grammar_type: Freeclimb::GrammarType.new(), grammar_type: "URL", grammar_file: "TS", grammar_rule: "TS", play_beep: true, - prompts: Freeclimb::PerclCommand.new(), prompts: Array.new(), no_input_timeout_ms: 1, recognition_timeout_ms: 1, @@ -390,12 +392,10 @@ ) instance_2 = Freeclimb::GetSpeech.new( action_url: "TS", - grammar_type: Freeclimb::GrammarType.new(), grammar_type: "URL", grammar_file: "TS", grammar_rule: "TS", play_beep: true, - prompts: Freeclimb::PerclCommand.new(), prompts: Array.new(), no_input_timeout_ms: 1, recognition_timeout_ms: 1, diff --git a/spec/models/hangup_spec.rb b/spec/models/hangup_spec.rb index a0917e0a..3925a298 100644 --- a/spec/models/hangup_spec.rb +++ b/spec/models/hangup_spec.rb @@ -37,7 +37,6 @@ it 'properly initializes with values' do expect{instance = Freeclimb::Hangup.new( reason: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::Hangup' do @@ -53,7 +52,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::Hangup.new( @@ -64,6 +63,16 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::Hangup.new( + reason: "TS", + ) + instance_2 = Freeclimb::Hangup.new( + reason: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/incoming_number_list_spec.rb b/spec/models/incoming_number_list_spec.rb index 8f7f224b..560661c3 100644 --- a/spec/models/incoming_number_list_spec.rb +++ b/spec/models/incoming_number_list_spec.rb @@ -103,65 +103,54 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::IncomingNumberList.new( -total: 1, - -start: 1, - -_end: 1, - -page: 1, - -num_pages: 1, - -page_size: 1, - + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - - incoming_phone_numbers: Freeclimb::IncomingNumberResult.new(), - + incoming_phone_numbers: Array.new(), )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::IncomingNumberList' do expect{instance = Freeclimb::IncomingNumberList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - incoming_phone_numbers: Freeclimb::IncomingNumberResult.new(), incoming_phone_numbers: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::IncomingNumberList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - incoming_phone_numbers: Freeclimb::IncomingNumberResult.new(), incoming_phone_numbers: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::IncomingNumberList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - incoming_phone_numbers: Freeclimb::IncomingNumberResult.new(), incoming_phone_numbers: Array.new(), ) expect(instance.valid?).to eq(true) @@ -169,19 +158,44 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::IncomingNumberList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + incoming_phone_numbers: Freeclimb::IncomingNumberResult.new(), + incoming_phone_numbers: [], + ) + instance_2 = Freeclimb::IncomingNumberList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + incoming_phone_numbers: Freeclimb::IncomingNumberResult.new(), + incoming_phone_numbers: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::IncomingNumberList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - incoming_phone_numbers: Freeclimb::IncomingNumberResult.new(), incoming_phone_numbers: Array.new(), ) expect(instance.hash).to be_a_kind_of(Integer) @@ -191,14 +205,13 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::IncomingNumberList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - incoming_phone_numbers: Freeclimb::IncomingNumberResult.new(), incoming_phone_numbers: Array.new(), ) instance_2 = Freeclimb::IncomingNumberList.new @@ -208,14 +221,13 @@ describe 'test method "_deserialize"' do instance = Freeclimb::IncomingNumberList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - incoming_phone_numbers: Freeclimb::IncomingNumberResult.new(), incoming_phone_numbers: Array.new(), ) it 'deserializes the data of total' do @@ -254,7 +266,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - incoming_phone_numbers: Freeclimb::IncomingNumberResult.new(), incoming_phone_numbers: Array.new(), ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -271,7 +282,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - incoming_phone_numbers: Freeclimb::IncomingNumberResult.new(), incoming_phone_numbers: Array.new(), ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -286,7 +296,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - incoming_phone_numbers: Freeclimb::IncomingNumberResult.new(), incoming_phone_numbers: Array.new(), ) instance_2 = Freeclimb::IncomingNumberList.new( @@ -297,7 +306,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - incoming_phone_numbers: Freeclimb::IncomingNumberResult.new(), incoming_phone_numbers: Array.new(), ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/incoming_number_request_spec.rb b/spec/models/incoming_number_request_spec.rb index 73cb8df2..90d969b5 100644 --- a/spec/models/incoming_number_request_spec.rb +++ b/spec/models/incoming_number_request_spec.rb @@ -51,11 +51,8 @@ it 'properly initializes with values' do expect{instance = Freeclimb::IncomingNumberRequest.new( application_id: "TS", - _alias: "TS", - campaign_id: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::IncomingNumberRequest' do @@ -75,7 +72,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::IncomingNumberRequest.new( @@ -88,6 +85,20 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::IncomingNumberRequest.new( + application_id: "TS", + _alias: "TS", + campaign_id: "TS", + ) + instance_2 = Freeclimb::IncomingNumberRequest.new( + application_id: "TS", + _alias: "TS", + campaign_id: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/incoming_number_result_spec.rb b/spec/models/incoming_number_result_spec.rb index cc699530..f9a9dba8 100644 --- a/spec/models/incoming_number_result_spec.rb +++ b/spec/models/incoming_number_result_spec.rb @@ -152,41 +152,22 @@ it 'properly initializes with values' do expect{instance = Freeclimb::IncomingNumberResult.new( uri: "TS", - date_created: "TS", - date_updated: "TS", - -revision: 1, - + revision: 1, capabilities: Freeclimb::Capabilities.new(), - - capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", - phone_number_id: "TS", - account_id: "TS", - application_id: "TS", - phone_number: "TS", - _alias: "TS", - region: "TS", - country: "TS", - voice_enabled: true, - sms_enabled: true, - offnet: true, - tfn: Freeclimb::TFN.new(), - - tfn: Freeclimb::TFN.new, )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::IncomingNumberResult' do @@ -194,8 +175,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, - capabilities: Freeclimb::Capabilities.new(), + revision: 1, capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number_id: "TS", @@ -208,7 +188,6 @@ voice_enabled: true, sms_enabled: true, offnet: true, - tfn: Freeclimb::TFN.new(), tfn: Freeclimb::TFN.new, invalid_attribute: true )}.to raise_error(ArgumentError) @@ -218,8 +197,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, - capabilities: Freeclimb::Capabilities.new(), + revision: 1, capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number_id: "TS", @@ -232,22 +210,20 @@ voice_enabled: true, sms_enabled: true, offnet: true, - tfn: Freeclimb::TFN.new(), tfn: Freeclimb::TFN.new, invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::IncomingNumberResult.new( uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, capabilities: Freeclimb::Capabilities.new(), - capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number_id: "TS", account_id: "TS", @@ -260,13 +236,54 @@ sms_enabled: true, offnet: true, tfn: Freeclimb::TFN.new(), - tfn: Freeclimb::TFN.new, ) expect(instance.valid?).to eq(true) end end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::IncomingNumberResult.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + capabilities: Freeclimb::Capabilities.new(), + campaign_id: "TS", + phone_number_id: "TS", + account_id: "TS", + application_id: "TS", + phone_number: "TS", + _alias: "TS", + region: "TS", + country: "TS", + voice_enabled: true, + sms_enabled: true, + offnet: true, + tfn: Freeclimb::TFN.new(), + ) + instance_2 = Freeclimb::IncomingNumberResult.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + capabilities: Freeclimb::Capabilities.new(), + campaign_id: "TS", + phone_number_id: "TS", + account_id: "TS", + application_id: "TS", + phone_number: "TS", + _alias: "TS", + region: "TS", + country: "TS", + voice_enabled: true, + sms_enabled: true, + offnet: true, + tfn: Freeclimb::TFN.new(), + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -275,9 +292,8 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, capabilities: Freeclimb::Capabilities.new(), - capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number_id: "TS", account_id: "TS", @@ -290,7 +306,6 @@ sms_enabled: true, offnet: true, tfn: Freeclimb::TFN.new(), - tfn: Freeclimb::TFN.new, ) expect(instance.hash).to be_a_kind_of(Integer) end @@ -302,9 +317,8 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, capabilities: Freeclimb::Capabilities.new(), - capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number_id: "TS", account_id: "TS", @@ -317,7 +331,6 @@ sms_enabled: true, offnet: true, tfn: Freeclimb::TFN.new(), - tfn: Freeclimb::TFN.new, ) instance_2 = Freeclimb::IncomingNumberResult.new expect(instance_2.build_from_hash(instance_1.hash)).to eq(instance_1.build_from_hash(instance_1.hash)) @@ -329,8 +342,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, - capabilities: Freeclimb::Capabilities.new(), + revision: 1, capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number_id: "TS", @@ -343,7 +355,6 @@ voice_enabled: true, sms_enabled: true, offnet: true, - tfn: Freeclimb::TFN.new(), tfn: Freeclimb::TFN.new, ) it 'deserializes the data of uri' do @@ -406,7 +417,6 @@ date_created: "TS", date_updated: "TS", revision: 1, - capabilities: Freeclimb::Capabilities.new(), capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number_id: "TS", @@ -419,7 +429,6 @@ voice_enabled: true, sms_enabled: true, offnet: true, - tfn: Freeclimb::TFN.new(), tfn: Freeclimb::TFN.new, ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -433,7 +442,6 @@ date_created: "TS", date_updated: "TS", revision: 1, - capabilities: Freeclimb::Capabilities.new(), capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number_id: "TS", @@ -446,7 +454,6 @@ voice_enabled: true, sms_enabled: true, offnet: true, - tfn: Freeclimb::TFN.new(), tfn: Freeclimb::TFN.new, ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -458,7 +465,6 @@ date_created: "TS", date_updated: "TS", revision: 1, - capabilities: Freeclimb::Capabilities.new(), capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number_id: "TS", @@ -471,7 +477,6 @@ voice_enabled: true, sms_enabled: true, offnet: true, - tfn: Freeclimb::TFN.new(), tfn: Freeclimb::TFN.new, ) instance_2 = Freeclimb::IncomingNumberResult.new( @@ -479,7 +484,6 @@ date_created: "TS", date_updated: "TS", revision: 1, - capabilities: Freeclimb::Capabilities.new(), capabilities: Freeclimb::Capabilities.new, campaign_id: "TS", phone_number_id: "TS", @@ -492,7 +496,6 @@ voice_enabled: true, sms_enabled: true, offnet: true, - tfn: Freeclimb::TFN.new(), tfn: Freeclimb::TFN.new, ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/log_list_spec.rb b/spec/models/log_list_spec.rb index 5b551ee5..e69cc4d5 100644 --- a/spec/models/log_list_spec.rb +++ b/spec/models/log_list_spec.rb @@ -103,65 +103,54 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::LogList.new( -total: 1, - -start: 1, - -_end: 1, - -page: 1, - -num_pages: 1, - -page_size: 1, - + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - - logs: Freeclimb::LogResult.new(), - + logs: Array.new(), )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::LogList' do expect{instance = Freeclimb::LogList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - logs: Freeclimb::LogResult.new(), logs: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::LogList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - logs: Freeclimb::LogResult.new(), logs: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::LogList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - logs: Freeclimb::LogResult.new(), logs: Array.new(), ) expect(instance.valid?).to eq(true) @@ -169,19 +158,44 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::LogList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + logs: Freeclimb::LogResult.new(), + logs: [], + ) + instance_2 = Freeclimb::LogList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + logs: Freeclimb::LogResult.new(), + logs: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::LogList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - logs: Freeclimb::LogResult.new(), logs: Array.new(), ) expect(instance.hash).to be_a_kind_of(Integer) @@ -191,14 +205,13 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::LogList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - logs: Freeclimb::LogResult.new(), logs: Array.new(), ) instance_2 = Freeclimb::LogList.new @@ -208,14 +221,13 @@ describe 'test method "_deserialize"' do instance = Freeclimb::LogList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - logs: Freeclimb::LogResult.new(), logs: Array.new(), ) it 'deserializes the data of total' do @@ -254,7 +266,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - logs: Freeclimb::LogResult.new(), logs: Array.new(), ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -271,7 +282,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - logs: Freeclimb::LogResult.new(), logs: Array.new(), ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -286,7 +296,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - logs: Freeclimb::LogResult.new(), logs: Array.new(), ) instance_2 = Freeclimb::LogList.new( @@ -297,7 +306,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - logs: Freeclimb::LogResult.new(), logs: Array.new(), ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/log_result_spec.rb b/spec/models/log_result_spec.rb index b1f6c8f4..2789fefa 100644 --- a/spec/models/log_result_spec.rb +++ b/spec/models/log_result_spec.rb @@ -91,27 +91,18 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::LogResult.new( -timestamp: 1, - - level: Freeclimb::LogLevel.new(), - + timestamp: 1, level: "INFO", request_id: "TS", - account_id: "TS", - call_id: "TS", - message: "TS", - - metadata: Object.new(), )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::LogResult' do expect{instance = Freeclimb::LogResult.new( -timestamp: 1, - level: Freeclimb::LogLevel.new(), + timestamp: 1, level: "INFO", request_id: "TS", account_id: "TS", @@ -123,8 +114,7 @@ end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::LogResult.new( -timestamp: 1, - level: Freeclimb::LogLevel.new(), + timestamp: 1, level: "INFO", request_id: "TS", account_id: "TS", @@ -135,12 +125,11 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::LogResult.new( -timestamp: 1, - level: Freeclimb::LogLevel.new(), + timestamp: 1, level: "INFO", request_id: "TS", account_id: "TS", @@ -153,13 +142,36 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::LogResult.new( + timestamp: 1, + level: Freeclimb::LogLevel.new(), + level: "INFO", + request_id: "TS", + account_id: "TS", + call_id: "TS", + message: "TS", + metadata: obj, + ) + instance_2 = Freeclimb::LogResult.new( + timestamp: 1, + level: Freeclimb::LogLevel.new(), + level: "INFO", + request_id: "TS", + account_id: "TS", + call_id: "TS", + message: "TS", + metadata: obj, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::LogResult.new( -timestamp: 1, - level: Freeclimb::LogLevel.new(), + timestamp: 1, level: "INFO", request_id: "TS", account_id: "TS", @@ -174,8 +186,7 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::LogResult.new( -timestamp: 1, - level: Freeclimb::LogLevel.new(), + timestamp: 1, level: "INFO", request_id: "TS", account_id: "TS", @@ -190,8 +201,7 @@ describe 'test method "_deserialize"' do instance = Freeclimb::LogResult.new( -timestamp: 1, - level: Freeclimb::LogLevel.new(), + timestamp: 1, level: "INFO", request_id: "TS", account_id: "TS", @@ -223,7 +233,6 @@ it 'returns the string representation of the object' do instance = Freeclimb::LogResult.new( timestamp: 1, - level: Freeclimb::LogLevel.new(), level: "INFO", request_id: "TS", account_id: "TS", @@ -239,7 +248,6 @@ it 'returns the object in the form of hash' do instance = Freeclimb::LogResult.new( timestamp: 1, - level: Freeclimb::LogLevel.new(), level: "INFO", request_id: "TS", account_id: "TS", @@ -253,7 +261,6 @@ obj = Object.new() instance_1 = Freeclimb::LogResult.new( timestamp: 1, - level: Freeclimb::LogLevel.new(), level: "INFO", request_id: "TS", account_id: "TS", @@ -263,7 +270,6 @@ ) instance_2 = Freeclimb::LogResult.new( timestamp: 1, - level: Freeclimb::LogLevel.new(), level: "INFO", request_id: "TS", account_id: "TS", diff --git a/spec/models/make_call_request_spec.rb b/spec/models/make_call_request_spec.rb index b93224a2..7e89ea6c 100644 --- a/spec/models/make_call_request_spec.rb +++ b/spec/models/make_call_request_spec.rb @@ -103,25 +103,15 @@ it 'properly initializes with values' do expect{instance = Freeclimb::MakeCallRequest.new( from: "TS", - to: "TS", - application_id: "TS", - send_digits: "TS", - if_machine: "TS", - if_machine_url: "TS", - -timeout: 1, - + timeout: 1, parent_call_id: "TS", - privacy_mode: true, - call_connect_url: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::MakeCallRequest' do @@ -132,7 +122,7 @@ send_digits: "TS", if_machine: "TS", if_machine_url: "TS", -timeout: 1, + timeout: 1, parent_call_id: "TS", privacy_mode: true, call_connect_url: "TS", @@ -147,7 +137,7 @@ send_digits: "TS", if_machine: "TS", if_machine_url: "TS", -timeout: 1, + timeout: 1, parent_call_id: "TS", privacy_mode: true, call_connect_url: "TS", @@ -155,7 +145,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::MakeCallRequest.new( @@ -165,7 +155,7 @@ send_digits: "TS", if_machine: "TS", if_machine_url: "TS", -timeout: 1, + timeout: 1, parent_call_id: "TS", privacy_mode: true, call_connect_url: "TS", @@ -175,6 +165,34 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::MakeCallRequest.new( + from: "TS", + to: "TS", + application_id: "TS", + send_digits: "TS", + if_machine: "TS", + if_machine_url: "TS", + timeout: 1, + parent_call_id: "TS", + privacy_mode: true, + call_connect_url: "TS", + ) + instance_2 = Freeclimb::MakeCallRequest.new( + from: "TS", + to: "TS", + application_id: "TS", + send_digits: "TS", + if_machine: "TS", + if_machine_url: "TS", + timeout: 1, + parent_call_id: "TS", + privacy_mode: true, + call_connect_url: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -186,7 +204,7 @@ send_digits: "TS", if_machine: "TS", if_machine_url: "TS", -timeout: 1, + timeout: 1, parent_call_id: "TS", privacy_mode: true, call_connect_url: "TS", @@ -204,7 +222,7 @@ send_digits: "TS", if_machine: "TS", if_machine_url: "TS", -timeout: 1, + timeout: 1, parent_call_id: "TS", privacy_mode: true, call_connect_url: "TS", @@ -222,7 +240,7 @@ send_digits: "TS", if_machine: "TS", if_machine_url: "TS", -timeout: 1, + timeout: 1, parent_call_id: "TS", privacy_mode: true, call_connect_url: "TS", diff --git a/spec/models/message_request_spec.rb b/spec/models/message_request_spec.rb index eb7bfb09..3445a689 100644 --- a/spec/models/message_request_spec.rb +++ b/spec/models/message_request_spec.rb @@ -96,24 +96,14 @@ it 'properly initializes with values' do expect{instance = Freeclimb::MessageRequest.new( uri: "TS", - date_created: "TS", - date_updated: "TS", - -revision: 1, - + revision: 1, from: "TS", - to: "TS", - text: "TS", - notification_url: "TS", - - media_urls: Array.new(), - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::MessageRequest' do @@ -121,7 +111,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, from: "TS", to: "TS", text: "TS", @@ -135,7 +125,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, from: "TS", to: "TS", text: "TS", @@ -145,14 +135,14 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::MessageRequest.new( uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, from: "TS", to: "TS", text: "TS", @@ -164,6 +154,32 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::MessageRequest.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + from: "TS", + to: "TS", + text: "TS", + notification_url: "TS", + media_urls: [], + ) + instance_2 = Freeclimb::MessageRequest.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + from: "TS", + to: "TS", + text: "TS", + notification_url: "TS", + media_urls: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -172,7 +188,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, from: "TS", to: "TS", text: "TS", @@ -189,7 +205,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, from: "TS", to: "TS", text: "TS", @@ -206,7 +222,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, from: "TS", to: "TS", text: "TS", diff --git a/spec/models/message_result_spec.rb b/spec/models/message_result_spec.rb index debd49af..3f1e868c 100644 --- a/spec/models/message_result_spec.rb +++ b/spec/models/message_result_spec.rb @@ -189,38 +189,20 @@ it 'properly initializes with values' do expect{instance = Freeclimb::MessageResult.new( uri: "TS", - date_created: "TS", - date_updated: "TS", - -revision: 1, - + revision: 1, account_id: "TS", - message_id: "TS", - - status: Freeclimb::MessageStatus.new(), - status: "NEW", from: "TS", - to: "TS", - text: "TS", - direction: "TS", - notification_url: "TS", - brand_id: "TS", - campaign_id: "TS", - - - media_urls: Array.new(), - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::MessageResult' do @@ -228,10 +210,9 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", message_id: "TS", - status: Freeclimb::MessageStatus.new(), status: "NEW", from: "TS", to: "TS", @@ -249,10 +230,9 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", message_id: "TS", - status: Freeclimb::MessageStatus.new(), status: "NEW", from: "TS", to: "TS", @@ -266,17 +246,16 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::MessageResult.new( uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", message_id: "TS", - status: Freeclimb::MessageStatus.new(), status: "NEW", from: "TS", to: "TS", @@ -285,7 +264,7 @@ notification_url: "TS", brand_id: "TS", campaign_id: "TS", -segment_count: 1, + segment_count: 1, media_urls: Array.new(), ) expect(instance.valid?).to eq(true) @@ -293,6 +272,46 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::MessageResult.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + account_id: "TS", + message_id: "TS", + status: Freeclimb::MessageStatus.new(), + status: "NEW", + from: "TS", + to: "TS", + text: "TS", + direction: "TS", + notification_url: "TS", + brand_id: "TS", + campaign_id: "TS", + media_urls: [], + ) + instance_2 = Freeclimb::MessageResult.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + account_id: "TS", + message_id: "TS", + status: Freeclimb::MessageStatus.new(), + status: "NEW", + from: "TS", + to: "TS", + text: "TS", + direction: "TS", + notification_url: "TS", + brand_id: "TS", + campaign_id: "TS", + media_urls: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -301,10 +320,9 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", message_id: "TS", - status: Freeclimb::MessageStatus.new(), status: "NEW", from: "TS", to: "TS", @@ -325,10 +343,9 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", message_id: "TS", - status: Freeclimb::MessageStatus.new(), status: "NEW", from: "TS", to: "TS", @@ -349,10 +366,9 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", message_id: "TS", - status: Freeclimb::MessageStatus.new(), status: "NEW", from: "TS", to: "TS", @@ -419,7 +435,6 @@ revision: 1, account_id: "TS", message_id: "TS", - status: Freeclimb::MessageStatus.new(), status: "NEW", from: "TS", to: "TS", @@ -443,7 +458,6 @@ revision: 1, account_id: "TS", message_id: "TS", - status: Freeclimb::MessageStatus.new(), status: "NEW", from: "TS", to: "TS", @@ -465,7 +479,6 @@ revision: 1, account_id: "TS", message_id: "TS", - status: Freeclimb::MessageStatus.new(), status: "NEW", from: "TS", to: "TS", @@ -483,7 +496,6 @@ revision: 1, account_id: "TS", message_id: "TS", - status: Freeclimb::MessageStatus.new(), status: "NEW", from: "TS", to: "TS", diff --git a/spec/models/messages_list_spec.rb b/spec/models/messages_list_spec.rb index 809b1495..67175721 100644 --- a/spec/models/messages_list_spec.rb +++ b/spec/models/messages_list_spec.rb @@ -103,65 +103,54 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::MessagesList.new( -total: 1, - -start: 1, - -_end: 1, - -page: 1, - -num_pages: 1, - -page_size: 1, - + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - - messages: Freeclimb::MessageResult.new(), - + messages: Array.new(), )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::MessagesList' do expect{instance = Freeclimb::MessagesList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - messages: Freeclimb::MessageResult.new(), messages: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::MessagesList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - messages: Freeclimb::MessageResult.new(), messages: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::MessagesList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - messages: Freeclimb::MessageResult.new(), messages: Array.new(), ) expect(instance.valid?).to eq(true) @@ -169,19 +158,44 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::MessagesList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + messages: Freeclimb::MessageResult.new(), + messages: [], + ) + instance_2 = Freeclimb::MessagesList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + messages: Freeclimb::MessageResult.new(), + messages: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::MessagesList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - messages: Freeclimb::MessageResult.new(), messages: Array.new(), ) expect(instance.hash).to be_a_kind_of(Integer) @@ -191,14 +205,13 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::MessagesList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - messages: Freeclimb::MessageResult.new(), messages: Array.new(), ) instance_2 = Freeclimb::MessagesList.new @@ -208,14 +221,13 @@ describe 'test method "_deserialize"' do instance = Freeclimb::MessagesList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - messages: Freeclimb::MessageResult.new(), messages: Array.new(), ) it 'deserializes the data of total' do @@ -254,7 +266,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - messages: Freeclimb::MessageResult.new(), messages: Array.new(), ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -271,7 +282,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - messages: Freeclimb::MessageResult.new(), messages: Array.new(), ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -286,7 +296,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - messages: Freeclimb::MessageResult.new(), messages: Array.new(), ) instance_2 = Freeclimb::MessagesList.new( @@ -297,7 +306,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - messages: Freeclimb::MessageResult.new(), messages: Array.new(), ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/mutable_resource_model_spec.rb b/spec/models/mutable_resource_model_spec.rb index 8d89814c..6b280552 100644 --- a/spec/models/mutable_resource_model_spec.rb +++ b/spec/models/mutable_resource_model_spec.rb @@ -61,13 +61,9 @@ it 'properly initializes with values' do expect{instance = Freeclimb::MutableResourceModel.new( uri: "TS", - date_created: "TS", - date_updated: "TS", - -revision: 1, - + revision: 1, )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::MutableResourceModel' do @@ -75,7 +71,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, invalid_attribute: true )}.to raise_error(ArgumentError) end @@ -84,25 +80,41 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::MutableResourceModel.new( uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, ) expect(instance.valid?).to eq(true) end end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::MutableResourceModel.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + ) + instance_2 = Freeclimb::MutableResourceModel.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -111,7 +123,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, ) expect(instance.hash).to be_a_kind_of(Integer) end @@ -123,7 +135,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, ) instance_2 = Freeclimb::MutableResourceModel.new expect(instance_2.build_from_hash(instance_1.hash)).to eq(instance_1.build_from_hash(instance_1.hash)) @@ -135,7 +147,7 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, ) it 'deserializes the data of uri' do expect(instance._deserialize("String", instance.uri)).to be_a_kind_of(String) diff --git a/spec/models/out_dial_spec.rb b/spec/models/out_dial_spec.rb index 2069caf3..d944c0f9 100644 --- a/spec/models/out_dial_spec.rb +++ b/spec/models/out_dial_spec.rb @@ -108,26 +108,15 @@ it 'properly initializes with values' do expect{instance = Freeclimb::OutDial.new( action_url: "TS", - call_connect_url: "TS", - calling_number: "TS", - destination: "TS", - - if_machine: Freeclimb::IfMachine.new(), - if_machine: "REDIRECT", if_machine_url: "TS", - send_digits: "TS", - status_callback_url: "TS", - -timeout: 1, - + timeout: 1, privacy_mode: true, - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::OutDial' do @@ -136,12 +125,11 @@ call_connect_url: "TS", calling_number: "TS", destination: "TS", - if_machine: Freeclimb::IfMachine.new(), if_machine: "REDIRECT", if_machine_url: "TS", send_digits: "TS", status_callback_url: "TS", -timeout: 1, + timeout: 1, privacy_mode: true, invalid_attribute: true )}.to raise_error(ArgumentError) @@ -152,18 +140,17 @@ call_connect_url: "TS", calling_number: "TS", destination: "TS", - if_machine: Freeclimb::IfMachine.new(), if_machine: "REDIRECT", if_machine_url: "TS", send_digits: "TS", status_callback_url: "TS", -timeout: 1, + timeout: 1, privacy_mode: true, invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::OutDial.new( @@ -171,12 +158,11 @@ call_connect_url: "TS", calling_number: "TS", destination: "TS", - if_machine: Freeclimb::IfMachine.new(), if_machine: "REDIRECT", if_machine_url: "TS", send_digits: "TS", status_callback_url: "TS", -timeout: 1, + timeout: 1, privacy_mode: true, ) expect(instance.valid?).to eq(true) @@ -184,6 +170,36 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::OutDial.new( + action_url: "TS", + call_connect_url: "TS", + calling_number: "TS", + destination: "TS", + if_machine: Freeclimb::IfMachine.new(), + if_machine: "REDIRECT", + if_machine_url: "TS", + send_digits: "TS", + status_callback_url: "TS", + timeout: 1, + privacy_mode: true, + ) + instance_2 = Freeclimb::OutDial.new( + action_url: "TS", + call_connect_url: "TS", + calling_number: "TS", + destination: "TS", + if_machine: Freeclimb::IfMachine.new(), + if_machine: "REDIRECT", + if_machine_url: "TS", + send_digits: "TS", + status_callback_url: "TS", + timeout: 1, + privacy_mode: true, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -193,12 +209,11 @@ call_connect_url: "TS", calling_number: "TS", destination: "TS", - if_machine: Freeclimb::IfMachine.new(), if_machine: "REDIRECT", if_machine_url: "TS", send_digits: "TS", status_callback_url: "TS", -timeout: 1, + timeout: 1, privacy_mode: true, ) expect(instance.hash).to be_a_kind_of(Integer) @@ -212,12 +227,11 @@ call_connect_url: "TS", calling_number: "TS", destination: "TS", - if_machine: Freeclimb::IfMachine.new(), if_machine: "REDIRECT", if_machine_url: "TS", send_digits: "TS", status_callback_url: "TS", -timeout: 1, + timeout: 1, privacy_mode: true, ) instance_2 = Freeclimb::OutDial.new @@ -231,12 +245,11 @@ call_connect_url: "TS", calling_number: "TS", destination: "TS", - if_machine: Freeclimb::IfMachine.new(), if_machine: "REDIRECT", if_machine_url: "TS", send_digits: "TS", status_callback_url: "TS", -timeout: 1, + timeout: 1, privacy_mode: true, ) it 'deserializes the data of action_url' do @@ -275,7 +288,6 @@ call_connect_url: "TS", calling_number: "TS", destination: "TS", - if_machine: Freeclimb::IfMachine.new(), if_machine: "REDIRECT", if_machine_url: "TS", send_digits: "TS", @@ -294,7 +306,6 @@ call_connect_url: "TS", calling_number: "TS", destination: "TS", - if_machine: Freeclimb::IfMachine.new(), if_machine: "REDIRECT", if_machine_url: "TS", send_digits: "TS", @@ -311,7 +322,6 @@ call_connect_url: "TS", calling_number: "TS", destination: "TS", - if_machine: Freeclimb::IfMachine.new(), if_machine: "REDIRECT", if_machine_url: "TS", send_digits: "TS", @@ -324,7 +334,6 @@ call_connect_url: "TS", calling_number: "TS", destination: "TS", - if_machine: Freeclimb::IfMachine.new(), if_machine: "REDIRECT", if_machine_url: "TS", send_digits: "TS", diff --git a/spec/models/pagination_model_spec.rb b/spec/models/pagination_model_spec.rb index 2415a73f..78c1f366 100644 --- a/spec/models/pagination_model_spec.rb +++ b/spec/models/pagination_model_spec.rb @@ -96,57 +96,50 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::PaginationModel.new( -total: 1, - -start: 1, - -_end: 1, - -page: 1, - -num_pages: 1, - -page_size: 1, - + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::PaginationModel' do expect{instance = Freeclimb::PaginationModel.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::PaginationModel.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::PaginationModel.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", ) expect(instance.valid?).to eq(true) @@ -154,17 +147,39 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::PaginationModel.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + ) + instance_2 = Freeclimb::PaginationModel.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::PaginationModel.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", ) expect(instance.hash).to be_a_kind_of(Integer) @@ -174,12 +189,12 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::PaginationModel.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", ) instance_2 = Freeclimb::PaginationModel.new @@ -189,12 +204,12 @@ describe 'test method "_deserialize"' do instance = Freeclimb::PaginationModel.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", ) it 'deserializes the data of total' do diff --git a/spec/models/park_spec.rb b/spec/models/park_spec.rb index 74ffb127..970c8227 100644 --- a/spec/models/park_spec.rb +++ b/spec/models/park_spec.rb @@ -51,11 +51,8 @@ it 'properly initializes with values' do expect{instance = Freeclimb::Park.new( wait_url: "TS", - action_url: "TS", - notification_url: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::Park' do @@ -75,7 +72,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::Park.new( @@ -88,6 +85,20 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::Park.new( + wait_url: "TS", + action_url: "TS", + notification_url: "TS", + ) + instance_2 = Freeclimb::Park.new( + wait_url: "TS", + action_url: "TS", + notification_url: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/pause_spec.rb b/spec/models/pause_spec.rb index 995322c8..42cf7897 100644 --- a/spec/models/pause_spec.rb +++ b/spec/models/pause_spec.rb @@ -39,40 +39,49 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::Pause.new( -length: 1, - + length: 1, )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::Pause' do expect{instance = Freeclimb::Pause.new( -length: 1, + length: 1, invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::Pause.new( -length: 1, + length: 1, invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::Pause.new( -length: 1, + length: 1, ) expect(instance.valid?).to eq(true) end end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::Pause.new( + length: 1, + ) + instance_2 = Freeclimb::Pause.new( + length: 1, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::Pause.new( -length: 1, + length: 1, ) expect(instance.hash).to be_a_kind_of(Integer) end @@ -81,7 +90,7 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::Pause.new( -length: 1, + length: 1, ) instance_2 = Freeclimb::Pause.new expect(instance_2.build_from_hash(instance_1.hash)).to eq(instance_1.build_from_hash(instance_1.hash)) @@ -90,7 +99,7 @@ describe 'test method "_deserialize"' do instance = Freeclimb::Pause.new( -length: 1, + length: 1, ) it 'deserializes the data of length' do expect(instance._deserialize("Integer", instance.length)).to be_a_kind_of(Integer) diff --git a/spec/models/percl_command_spec.rb b/spec/models/percl_command_spec.rb index 9302874f..0ccab129 100644 --- a/spec/models/percl_command_spec.rb +++ b/spec/models/percl_command_spec.rb @@ -31,7 +31,6 @@ it 'properly initializes with values' do expect{instance = Freeclimb::PerclCommand.new( command: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::PerclCommand' do @@ -47,7 +46,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::PerclCommand.new( @@ -58,6 +57,16 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::PerclCommand.new( + command: "TS", + ) + instance_2 = Freeclimb::PerclCommand.new( + command: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/percl_script_spec.rb b/spec/models/percl_script_spec.rb index dd59487f..c3cb2457 100644 --- a/spec/models/percl_script_spec.rb +++ b/spec/models/percl_script_spec.rb @@ -36,30 +36,26 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::PerclScript.new( - commands: Freeclimb::PerclCommand.new(), - + commands: Array.new(), )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::PerclScript' do expect{instance = Freeclimb::PerclScript.new( - commands: Freeclimb::PerclCommand.new(), commands: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::PerclScript.new( - commands: Freeclimb::PerclCommand.new(), commands: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::PerclScript.new( - commands: Freeclimb::PerclCommand.new(), commands: Array.new(), ) expect(instance.valid?).to eq(true) @@ -67,12 +63,23 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::PerclScript.new( + commands: Freeclimb::PerclCommand.new(), + commands: [], + ) + instance_2 = Freeclimb::PerclScript.new( + commands: Freeclimb::PerclCommand.new(), + commands: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::PerclScript.new( - commands: Freeclimb::PerclCommand.new(), commands: Array.new(), ) expect(instance.hash).to be_a_kind_of(Integer) @@ -82,7 +89,6 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::PerclScript.new( - commands: Freeclimb::PerclCommand.new(), commands: Array.new(), ) instance_2 = Freeclimb::PerclScript.new @@ -92,7 +98,6 @@ describe 'test method "_deserialize"' do instance = Freeclimb::PerclScript.new( - commands: Freeclimb::PerclCommand.new(), commands: Array.new(), ) it 'deserializes the data of commands' do @@ -103,7 +108,6 @@ describe 'test method "to_s"' do it 'returns the string representation of the object' do instance = Freeclimb::PerclScript.new( - commands: Freeclimb::PerclCommand.new(), commands: Array.new(), ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -113,7 +117,6 @@ describe 'test method "to_hash"' do it 'returns the object in the form of hash' do instance = Freeclimb::PerclScript.new( - commands: Freeclimb::PerclCommand.new(), commands: Array.new(), ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -121,11 +124,9 @@ it 'creates equal hash for two equal objects' do obj = Object.new() instance_1 = Freeclimb::PerclScript.new( - commands: Freeclimb::PerclCommand.new(), commands: Array.new(), ) instance_2 = Freeclimb::PerclScript.new( - commands: Freeclimb::PerclCommand.new(), commands: Array.new(), ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/play_early_media_spec.rb b/spec/models/play_early_media_spec.rb index 6270595b..a4efe681 100644 --- a/spec/models/play_early_media_spec.rb +++ b/spec/models/play_early_media_spec.rb @@ -37,7 +37,6 @@ it 'properly initializes with values' do expect{instance = Freeclimb::PlayEarlyMedia.new( file: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::PlayEarlyMedia' do @@ -53,7 +52,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::PlayEarlyMedia.new( @@ -64,6 +63,16 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::PlayEarlyMedia.new( + file: "TS", + ) + instance_2 = Freeclimb::PlayEarlyMedia.new( + file: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/play_spec.rb b/spec/models/play_spec.rb index c255c1d9..400dfcbc 100644 --- a/spec/models/play_spec.rb +++ b/spec/models/play_spec.rb @@ -54,17 +54,14 @@ it 'properly initializes with values' do expect{instance = Freeclimb::Play.new( file: "TS", - -loop: 1, - + loop: 1, privacy_mode: true, - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::Play' do expect{instance = Freeclimb::Play.new( file: "TS", -loop: 1, + loop: 1, privacy_mode: true, invalid_attribute: true )}.to raise_error(ArgumentError) @@ -72,18 +69,18 @@ it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::Play.new( file: "TS", -loop: 1, + loop: 1, privacy_mode: true, invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::Play.new( file: "TS", -loop: 1, + loop: 1, privacy_mode: true, ) expect(instance.valid?).to eq(true) @@ -91,13 +88,27 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::Play.new( + file: "TS", + loop: 1, + privacy_mode: true, + ) + instance_2 = Freeclimb::Play.new( + file: "TS", + loop: 1, + privacy_mode: true, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::Play.new( file: "TS", -loop: 1, + loop: 1, privacy_mode: true, ) expect(instance.hash).to be_a_kind_of(Integer) @@ -108,7 +119,7 @@ it 'builds equivalent model from hash code' do instance_1 = Freeclimb::Play.new( file: "TS", -loop: 1, + loop: 1, privacy_mode: true, ) instance_2 = Freeclimb::Play.new @@ -119,7 +130,7 @@ describe 'test method "_deserialize"' do instance = Freeclimb::Play.new( file: "TS", -loop: 1, + loop: 1, privacy_mode: true, ) it 'deserializes the data of file' do diff --git a/spec/models/queue_list_spec.rb b/spec/models/queue_list_spec.rb index aa03a9e2..47db8e4c 100644 --- a/spec/models/queue_list_spec.rb +++ b/spec/models/queue_list_spec.rb @@ -103,65 +103,54 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::QueueList.new( -total: 1, - -start: 1, - -_end: 1, - -page: 1, - -num_pages: 1, - -page_size: 1, - + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - - queues: Freeclimb::QueueResult.new(), - + queues: Array.new(), )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::QueueList' do expect{instance = Freeclimb::QueueList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - queues: Freeclimb::QueueResult.new(), queues: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::QueueList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - queues: Freeclimb::QueueResult.new(), queues: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::QueueList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - queues: Freeclimb::QueueResult.new(), queues: Array.new(), ) expect(instance.valid?).to eq(true) @@ -169,19 +158,44 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::QueueList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + queues: Freeclimb::QueueResult.new(), + queues: [], + ) + instance_2 = Freeclimb::QueueList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + queues: Freeclimb::QueueResult.new(), + queues: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::QueueList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - queues: Freeclimb::QueueResult.new(), queues: Array.new(), ) expect(instance.hash).to be_a_kind_of(Integer) @@ -191,14 +205,13 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::QueueList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - queues: Freeclimb::QueueResult.new(), queues: Array.new(), ) instance_2 = Freeclimb::QueueList.new @@ -208,14 +221,13 @@ describe 'test method "_deserialize"' do instance = Freeclimb::QueueList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - queues: Freeclimb::QueueResult.new(), queues: Array.new(), ) it 'deserializes the data of total' do @@ -254,7 +266,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - queues: Freeclimb::QueueResult.new(), queues: Array.new(), ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -271,7 +282,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - queues: Freeclimb::QueueResult.new(), queues: Array.new(), ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -286,7 +296,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - queues: Freeclimb::QueueResult.new(), queues: Array.new(), ) instance_2 = Freeclimb::QueueList.new( @@ -297,7 +306,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - queues: Freeclimb::QueueResult.new(), queues: Array.new(), ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/queue_member_list_spec.rb b/spec/models/queue_member_list_spec.rb index b7c870bb..7de500b1 100644 --- a/spec/models/queue_member_list_spec.rb +++ b/spec/models/queue_member_list_spec.rb @@ -103,65 +103,54 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::QueueMemberList.new( -total: 1, - -start: 1, - -_end: 1, - -page: 1, - -num_pages: 1, - -page_size: 1, - + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - - queue_members: Freeclimb::QueueMember.new(), - + queue_members: Array.new(), )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::QueueMemberList' do expect{instance = Freeclimb::QueueMemberList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - queue_members: Freeclimb::QueueMember.new(), queue_members: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::QueueMemberList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - queue_members: Freeclimb::QueueMember.new(), queue_members: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::QueueMemberList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - queue_members: Freeclimb::QueueMember.new(), queue_members: Array.new(), ) expect(instance.valid?).to eq(true) @@ -169,19 +158,44 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::QueueMemberList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + queue_members: Freeclimb::QueueMember.new(), + queue_members: [], + ) + instance_2 = Freeclimb::QueueMemberList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + queue_members: Freeclimb::QueueMember.new(), + queue_members: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::QueueMemberList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - queue_members: Freeclimb::QueueMember.new(), queue_members: Array.new(), ) expect(instance.hash).to be_a_kind_of(Integer) @@ -191,14 +205,13 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::QueueMemberList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - queue_members: Freeclimb::QueueMember.new(), queue_members: Array.new(), ) instance_2 = Freeclimb::QueueMemberList.new @@ -208,14 +221,13 @@ describe 'test method "_deserialize"' do instance = Freeclimb::QueueMemberList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - queue_members: Freeclimb::QueueMember.new(), queue_members: Array.new(), ) it 'deserializes the data of total' do @@ -254,7 +266,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - queue_members: Freeclimb::QueueMember.new(), queue_members: Array.new(), ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -271,7 +282,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - queue_members: Freeclimb::QueueMember.new(), queue_members: Array.new(), ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -286,7 +296,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - queue_members: Freeclimb::QueueMember.new(), queue_members: Array.new(), ) instance_2 = Freeclimb::QueueMemberList.new( @@ -297,7 +306,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - queue_members: Freeclimb::QueueMember.new(), queue_members: Array.new(), ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/queue_member_spec.rb b/spec/models/queue_member_spec.rb index 6841a79c..ad9ffca6 100644 --- a/spec/models/queue_member_spec.rb +++ b/spec/models/queue_member_spec.rb @@ -71,23 +71,18 @@ it 'properly initializes with values' do expect{instance = Freeclimb::QueueMember.new( uri: "TS", - call_id: "TS", - -wait_time: 1, - -position: 1, - + wait_time: 1, + position: 1, date_enqueued: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::QueueMember' do expect{instance = Freeclimb::QueueMember.new( uri: "TS", call_id: "TS", -wait_time: 1, -position: 1, + wait_time: 1, + position: 1, date_enqueued: "TS", invalid_attribute: true )}.to raise_error(ArgumentError) @@ -96,21 +91,21 @@ expect{instance = Freeclimb::QueueMember.new( uri: "TS", call_id: "TS", -wait_time: 1, -position: 1, + wait_time: 1, + position: 1, date_enqueued: "TS", invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::QueueMember.new( uri: "TS", call_id: "TS", -wait_time: 1, -position: 1, + wait_time: 1, + position: 1, date_enqueued: "TS", ) expect(instance.valid?).to eq(true) @@ -118,6 +113,24 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::QueueMember.new( + uri: "TS", + call_id: "TS", + wait_time: 1, + position: 1, + date_enqueued: "TS", + ) + instance_2 = Freeclimb::QueueMember.new( + uri: "TS", + call_id: "TS", + wait_time: 1, + position: 1, + date_enqueued: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -125,8 +138,8 @@ instance = Freeclimb::QueueMember.new( uri: "TS", call_id: "TS", -wait_time: 1, -position: 1, + wait_time: 1, + position: 1, date_enqueued: "TS", ) expect(instance.hash).to be_a_kind_of(Integer) @@ -138,8 +151,8 @@ instance_1 = Freeclimb::QueueMember.new( uri: "TS", call_id: "TS", -wait_time: 1, -position: 1, + wait_time: 1, + position: 1, date_enqueued: "TS", ) instance_2 = Freeclimb::QueueMember.new @@ -151,8 +164,8 @@ instance = Freeclimb::QueueMember.new( uri: "TS", call_id: "TS", -wait_time: 1, -position: 1, + wait_time: 1, + position: 1, date_enqueued: "TS", ) it 'deserializes the data of uri' do diff --git a/spec/models/queue_request_spec.rb b/spec/models/queue_request_spec.rb index 6ffbfbfb..e3899fd4 100644 --- a/spec/models/queue_request_spec.rb +++ b/spec/models/queue_request_spec.rb @@ -47,45 +47,55 @@ it 'properly initializes with values' do expect{instance = Freeclimb::QueueRequest.new( _alias: "TS", - -max_size: 1, - + max_size: 1, )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::QueueRequest' do expect{instance = Freeclimb::QueueRequest.new( _alias: "TS", -max_size: 1, + max_size: 1, invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::QueueRequest.new( _alias: "TS", -max_size: 1, + max_size: 1, invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::QueueRequest.new( _alias: "TS", -max_size: 1, + max_size: 1, ) expect(instance.valid?).to eq(true) end end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::QueueRequest.new( + _alias: "TS", + max_size: 1, + ) + instance_2 = Freeclimb::QueueRequest.new( + _alias: "TS", + max_size: 1, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::QueueRequest.new( _alias: "TS", -max_size: 1, + max_size: 1, ) expect(instance.hash).to be_a_kind_of(Integer) end @@ -95,7 +105,7 @@ it 'builds equivalent model from hash code' do instance_1 = Freeclimb::QueueRequest.new( _alias: "TS", -max_size: 1, + max_size: 1, ) instance_2 = Freeclimb::QueueRequest.new expect(instance_2.build_from_hash(instance_1.hash)).to eq(instance_1.build_from_hash(instance_1.hash)) @@ -105,7 +115,7 @@ describe 'test method "_deserialize"' do instance = Freeclimb::QueueRequest.new( _alias: "TS", -max_size: 1, + max_size: 1, ) it 'deserializes the data of _alias' do expect(instance._deserialize("String", instance._alias)).to be_a_kind_of(String) diff --git a/spec/models/queue_result_spec.rb b/spec/models/queue_result_spec.rb index b47a5a1f..41896d3a 100644 --- a/spec/models/queue_result_spec.rb +++ b/spec/models/queue_result_spec.rb @@ -120,26 +120,15 @@ it 'properly initializes with values' do expect{instance = Freeclimb::QueueResult.new( uri: "TS", - date_created: "TS", - date_updated: "TS", - -revision: 1, - + revision: 1, account_id: "TS", - queue_id: "TS", - _alias: "TS", - -max_size: 1, - -current_size: 1, - -average_queue_removal_time: 1, - - + max_size: 1, + current_size: 1, + average_queue_removal_time: 1, subresource_uris: Object.new(), )}.not_to raise_error() end @@ -148,13 +137,13 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", queue_id: "TS", _alias: "TS", -max_size: 1, -current_size: 1, -average_queue_removal_time: 1, + max_size: 1, + current_size: 1, + average_queue_removal_time: 1, subresource_uris: Object.new(), invalid_attribute: true )}.to raise_error(ArgumentError) @@ -164,32 +153,32 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", queue_id: "TS", _alias: "TS", -max_size: 1, -current_size: 1, -average_queue_removal_time: 1, + max_size: 1, + current_size: 1, + average_queue_removal_time: 1, subresource_uris: Object.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::QueueResult.new( uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", queue_id: "TS", _alias: "TS", -max_size: 1, -current_size: 1, -average_queue_removal_time: 1, + max_size: 1, + current_size: 1, + average_queue_removal_time: 1, subresource_uris: Object.new(), ) expect(instance.valid?).to eq(true) @@ -197,6 +186,36 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::QueueResult.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + account_id: "TS", + queue_id: "TS", + _alias: "TS", + max_size: 1, + current_size: 1, + average_queue_removal_time: 1, + subresource_uris: obj, + ) + instance_2 = Freeclimb::QueueResult.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + account_id: "TS", + queue_id: "TS", + _alias: "TS", + max_size: 1, + current_size: 1, + average_queue_removal_time: 1, + subresource_uris: obj, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -205,13 +224,13 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", queue_id: "TS", _alias: "TS", -max_size: 1, -current_size: 1, -average_queue_removal_time: 1, + max_size: 1, + current_size: 1, + average_queue_removal_time: 1, subresource_uris: Object.new(), ) expect(instance.hash).to be_a_kind_of(Integer) @@ -224,13 +243,13 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", queue_id: "TS", _alias: "TS", -max_size: 1, -current_size: 1, -average_queue_removal_time: 1, + max_size: 1, + current_size: 1, + average_queue_removal_time: 1, subresource_uris: Object.new(), ) instance_2 = Freeclimb::QueueResult.new @@ -243,13 +262,13 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, account_id: "TS", queue_id: "TS", _alias: "TS", -max_size: 1, -current_size: 1, -average_queue_removal_time: 1, + max_size: 1, + current_size: 1, + average_queue_removal_time: 1, subresource_uris: Object.new(), ) it 'deserializes the data of uri' do diff --git a/spec/models/record_utterance_spec.rb b/spec/models/record_utterance_spec.rb index 76883996..f80e2391 100644 --- a/spec/models/record_utterance_spec.rb +++ b/spec/models/record_utterance_spec.rb @@ -85,27 +85,20 @@ it 'properly initializes with values' do expect{instance = Freeclimb::RecordUtterance.new( action_url: "TS", - -silence_timeout_ms: 1, - + silence_timeout_ms: 1, finish_on_key: "TS", - -max_length_sec: 1, - + max_length_sec: 1, play_beep: true, - auto_start: true, - privacy_mode: true, - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::RecordUtterance' do expect{instance = Freeclimb::RecordUtterance.new( action_url: "TS", -silence_timeout_ms: 1, + silence_timeout_ms: 1, finish_on_key: "TS", -max_length_sec: 1, + max_length_sec: 1, play_beep: true, auto_start: true, privacy_mode: true, @@ -115,9 +108,9 @@ it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::RecordUtterance.new( action_url: "TS", -silence_timeout_ms: 1, + silence_timeout_ms: 1, finish_on_key: "TS", -max_length_sec: 1, + max_length_sec: 1, play_beep: true, auto_start: true, privacy_mode: true, @@ -125,14 +118,14 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::RecordUtterance.new( action_url: "TS", -silence_timeout_ms: 1, + silence_timeout_ms: 1, finish_on_key: "TS", -max_length_sec: 1, + max_length_sec: 1, play_beep: true, auto_start: true, privacy_mode: true, @@ -142,15 +135,37 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::RecordUtterance.new( + action_url: "TS", + silence_timeout_ms: 1, + finish_on_key: "TS", + max_length_sec: 1, + play_beep: true, + auto_start: true, + privacy_mode: true, + ) + instance_2 = Freeclimb::RecordUtterance.new( + action_url: "TS", + silence_timeout_ms: 1, + finish_on_key: "TS", + max_length_sec: 1, + play_beep: true, + auto_start: true, + privacy_mode: true, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::RecordUtterance.new( action_url: "TS", -silence_timeout_ms: 1, + silence_timeout_ms: 1, finish_on_key: "TS", -max_length_sec: 1, + max_length_sec: 1, play_beep: true, auto_start: true, privacy_mode: true, @@ -163,9 +178,9 @@ it 'builds equivalent model from hash code' do instance_1 = Freeclimb::RecordUtterance.new( action_url: "TS", -silence_timeout_ms: 1, + silence_timeout_ms: 1, finish_on_key: "TS", -max_length_sec: 1, + max_length_sec: 1, play_beep: true, auto_start: true, privacy_mode: true, @@ -178,9 +193,9 @@ describe 'test method "_deserialize"' do instance = Freeclimb::RecordUtterance.new( action_url: "TS", -silence_timeout_ms: 1, + silence_timeout_ms: 1, finish_on_key: "TS", -max_length_sec: 1, + max_length_sec: 1, play_beep: true, auto_start: true, privacy_mode: true, diff --git a/spec/models/recording_list_spec.rb b/spec/models/recording_list_spec.rb index 4bbe9703..f6dd1c60 100644 --- a/spec/models/recording_list_spec.rb +++ b/spec/models/recording_list_spec.rb @@ -103,65 +103,54 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::RecordingList.new( -total: 1, - -start: 1, - -_end: 1, - -page: 1, - -num_pages: 1, - -page_size: 1, - + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - - recordings: Freeclimb::RecordingResult.new(), - + recordings: Array.new(), )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::RecordingList' do expect{instance = Freeclimb::RecordingList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - recordings: Freeclimb::RecordingResult.new(), recordings: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::RecordingList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - recordings: Freeclimb::RecordingResult.new(), recordings: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::RecordingList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - recordings: Freeclimb::RecordingResult.new(), recordings: Array.new(), ) expect(instance.valid?).to eq(true) @@ -169,19 +158,44 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::RecordingList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + recordings: Freeclimb::RecordingResult.new(), + recordings: [], + ) + instance_2 = Freeclimb::RecordingList.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + recordings: Freeclimb::RecordingResult.new(), + recordings: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::RecordingList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - recordings: Freeclimb::RecordingResult.new(), recordings: Array.new(), ) expect(instance.hash).to be_a_kind_of(Integer) @@ -191,14 +205,13 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::RecordingList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - recordings: Freeclimb::RecordingResult.new(), recordings: Array.new(), ) instance_2 = Freeclimb::RecordingList.new @@ -208,14 +221,13 @@ describe 'test method "_deserialize"' do instance = Freeclimb::RecordingList.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - recordings: Freeclimb::RecordingResult.new(), recordings: Array.new(), ) it 'deserializes the data of total' do @@ -254,7 +266,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - recordings: Freeclimb::RecordingResult.new(), recordings: Array.new(), ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -271,7 +282,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - recordings: Freeclimb::RecordingResult.new(), recordings: Array.new(), ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -286,7 +296,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - recordings: Freeclimb::RecordingResult.new(), recordings: Array.new(), ) instance_2 = Freeclimb::RecordingList.new( @@ -297,7 +306,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - recordings: Freeclimb::RecordingResult.new(), recordings: Array.new(), ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/recording_result_spec.rb b/spec/models/recording_result_spec.rb index b3341716..5429e4b2 100644 --- a/spec/models/recording_result_spec.rb +++ b/spec/models/recording_result_spec.rb @@ -99,23 +99,14 @@ it 'properly initializes with values' do expect{instance = Freeclimb::RecordingResult.new( uri: "TS", - date_created: "TS", - date_updated: "TS", - -revision: 1, - + revision: 1, recording_id: "TS", - account_id: "TS", - call_id: "TS", - -duration_sec: 1, - + duration_sec: 1, conference_id: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::RecordingResult' do @@ -123,11 +114,11 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, recording_id: "TS", account_id: "TS", call_id: "TS", -duration_sec: 1, + duration_sec: 1, conference_id: "TS", invalid_attribute: true )}.to raise_error(ArgumentError) @@ -137,28 +128,28 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, recording_id: "TS", account_id: "TS", call_id: "TS", -duration_sec: 1, + duration_sec: 1, conference_id: "TS", invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::RecordingResult.new( uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, recording_id: "TS", account_id: "TS", call_id: "TS", -duration_sec: 1, + duration_sec: 1, conference_id: "TS", ) expect(instance.valid?).to eq(true) @@ -166,6 +157,32 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::RecordingResult.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + recording_id: "TS", + account_id: "TS", + call_id: "TS", + duration_sec: 1, + conference_id: "TS", + ) + instance_2 = Freeclimb::RecordingResult.new( + uri: "TS", + date_created: "TS", + date_updated: "TS", + revision: 1, + recording_id: "TS", + account_id: "TS", + call_id: "TS", + duration_sec: 1, + conference_id: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -174,11 +191,11 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, recording_id: "TS", account_id: "TS", call_id: "TS", -duration_sec: 1, + duration_sec: 1, conference_id: "TS", ) expect(instance.hash).to be_a_kind_of(Integer) @@ -191,11 +208,11 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, recording_id: "TS", account_id: "TS", call_id: "TS", -duration_sec: 1, + duration_sec: 1, conference_id: "TS", ) instance_2 = Freeclimb::RecordingResult.new @@ -208,11 +225,11 @@ uri: "TS", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, recording_id: "TS", account_id: "TS", call_id: "TS", -duration_sec: 1, + duration_sec: 1, conference_id: "TS", ) it 'deserializes the data of uri' do diff --git a/spec/models/redirect_spec.rb b/spec/models/redirect_spec.rb index f4028b35..819f0343 100644 --- a/spec/models/redirect_spec.rb +++ b/spec/models/redirect_spec.rb @@ -37,7 +37,6 @@ it 'properly initializes with values' do expect{instance = Freeclimb::Redirect.new( action_url: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::Redirect' do @@ -53,7 +52,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::Redirect.new( @@ -64,6 +63,16 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::Redirect.new( + action_url: "TS", + ) + instance_2 = Freeclimb::Redirect.new( + action_url: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/reject_spec.rb b/spec/models/reject_spec.rb index 3932ac18..e0c24582 100644 --- a/spec/models/reject_spec.rb +++ b/spec/models/reject_spec.rb @@ -37,7 +37,6 @@ it 'properly initializes with values' do expect{instance = Freeclimb::Reject.new( reason: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::Reject' do @@ -53,7 +52,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::Reject.new( @@ -64,6 +63,16 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::Reject.new( + reason: "TS", + ) + instance_2 = Freeclimb::Reject.new( + reason: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/remove_from_conference_spec.rb b/spec/models/remove_from_conference_spec.rb index 7c1f50c6..4c17ca9b 100644 --- a/spec/models/remove_from_conference_spec.rb +++ b/spec/models/remove_from_conference_spec.rb @@ -42,7 +42,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::RemoveFromConference.new( @@ -52,6 +52,14 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::RemoveFromConference.new( + ) + instance_2 = Freeclimb::RemoveFromConference.new( + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/say_spec.rb b/spec/models/say_spec.rb index 7907b649..a7c86637 100644 --- a/spec/models/say_spec.rb +++ b/spec/models/say_spec.rb @@ -61,20 +61,16 @@ it 'properly initializes with values' do expect{instance = Freeclimb::Say.new( text: "TS", - language: "TS", - -loop: 1, - + loop: 1, privacy_mode: true, - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::Say' do expect{instance = Freeclimb::Say.new( text: "TS", language: "TS", -loop: 1, + loop: 1, privacy_mode: true, invalid_attribute: true )}.to raise_error(ArgumentError) @@ -83,19 +79,19 @@ expect{instance = Freeclimb::Say.new( text: "TS", language: "TS", -loop: 1, + loop: 1, privacy_mode: true, invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::Say.new( text: "TS", language: "TS", -loop: 1, + loop: 1, privacy_mode: true, ) expect(instance.valid?).to eq(true) @@ -103,6 +99,22 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::Say.new( + text: "TS", + language: "TS", + loop: 1, + privacy_mode: true, + ) + instance_2 = Freeclimb::Say.new( + text: "TS", + language: "TS", + loop: 1, + privacy_mode: true, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -110,7 +122,7 @@ instance = Freeclimb::Say.new( text: "TS", language: "TS", -loop: 1, + loop: 1, privacy_mode: true, ) expect(instance.hash).to be_a_kind_of(Integer) @@ -122,7 +134,7 @@ instance_1 = Freeclimb::Say.new( text: "TS", language: "TS", -loop: 1, + loop: 1, privacy_mode: true, ) instance_2 = Freeclimb::Say.new @@ -134,7 +146,7 @@ instance = Freeclimb::Say.new( text: "TS", language: "TS", -loop: 1, + loop: 1, privacy_mode: true, ) it 'deserializes the data of text' do diff --git a/spec/models/send_digits_spec.rb b/spec/models/send_digits_spec.rb index 5a45d280..e60cffd9 100644 --- a/spec/models/send_digits_spec.rb +++ b/spec/models/send_digits_spec.rb @@ -54,17 +54,14 @@ it 'properly initializes with values' do expect{instance = Freeclimb::SendDigits.new( digits: "TS", - -pause_ms: 1, - + pause_ms: 1, privacy_mode: true, - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::SendDigits' do expect{instance = Freeclimb::SendDigits.new( digits: "TS", -pause_ms: 1, + pause_ms: 1, privacy_mode: true, invalid_attribute: true )}.to raise_error(ArgumentError) @@ -72,18 +69,18 @@ it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::SendDigits.new( digits: "TS", -pause_ms: 1, + pause_ms: 1, privacy_mode: true, invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::SendDigits.new( digits: "TS", -pause_ms: 1, + pause_ms: 1, privacy_mode: true, ) expect(instance.valid?).to eq(true) @@ -91,13 +88,27 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::SendDigits.new( + digits: "TS", + pause_ms: 1, + privacy_mode: true, + ) + instance_2 = Freeclimb::SendDigits.new( + digits: "TS", + pause_ms: 1, + privacy_mode: true, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::SendDigits.new( digits: "TS", -pause_ms: 1, + pause_ms: 1, privacy_mode: true, ) expect(instance.hash).to be_a_kind_of(Integer) @@ -108,7 +119,7 @@ it 'builds equivalent model from hash code' do instance_1 = Freeclimb::SendDigits.new( digits: "TS", -pause_ms: 1, + pause_ms: 1, privacy_mode: true, ) instance_2 = Freeclimb::SendDigits.new @@ -119,7 +130,7 @@ describe 'test method "_deserialize"' do instance = Freeclimb::SendDigits.new( digits: "TS", -pause_ms: 1, + pause_ms: 1, privacy_mode: true, ) it 'deserializes the data of digits' do diff --git a/spec/models/set_listen_spec.rb b/spec/models/set_listen_spec.rb index 575d6ebf..264f8299 100644 --- a/spec/models/set_listen_spec.rb +++ b/spec/models/set_listen_spec.rb @@ -37,7 +37,6 @@ it 'properly initializes with values' do expect{instance = Freeclimb::SetListen.new( listen: true, - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::SetListen' do @@ -53,7 +52,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::SetListen.new( @@ -64,6 +63,16 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::SetListen.new( + listen: true, + ) + instance_2 = Freeclimb::SetListen.new( + listen: true, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/set_talk_spec.rb b/spec/models/set_talk_spec.rb index ee73fd8b..773d755b 100644 --- a/spec/models/set_talk_spec.rb +++ b/spec/models/set_talk_spec.rb @@ -37,7 +37,6 @@ it 'properly initializes with values' do expect{instance = Freeclimb::SetTalk.new( talk: true, - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::SetTalk' do @@ -53,7 +52,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::SetTalk.new( @@ -64,6 +63,16 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::SetTalk.new( + talk: true, + ) + instance_2 = Freeclimb::SetTalk.new( + talk: true, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/sms_spec.rb b/spec/models/sms_spec.rb index 604cafb8..32680bf2 100644 --- a/spec/models/sms_spec.rb +++ b/spec/models/sms_spec.rb @@ -58,13 +58,9 @@ it 'properly initializes with values' do expect{instance = Freeclimb::Sms.new( to: "TS", - from: "TS", - text: "TS", - notification_url: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::Sms' do @@ -86,7 +82,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::Sms.new( @@ -100,6 +96,22 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::Sms.new( + to: "TS", + from: "TS", + text: "TS", + notification_url: "TS", + ) + instance_2 = Freeclimb::Sms.new( + to: "TS", + from: "TS", + text: "TS", + notification_url: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/sms_ten_dlc_brand_spec.rb b/spec/models/sms_ten_dlc_brand_spec.rb index 15ecbb5c..21565c0d 100644 --- a/spec/models/sms_ten_dlc_brand_spec.rb +++ b/spec/models/sms_ten_dlc_brand_spec.rb @@ -490,66 +490,35 @@ it 'properly initializes with values' do expect{instance = Freeclimb::SMSTenDLCBrand.new( account_id: "TS", - - entity_type: "PRIVATE_PROFIT", csp_id: "TS", - brand_id: "TS", - first_name: "TS", - last_name: "TS", - display_name: "TS", - company_name: "TS", - ein: "TS", - ein_issuing_country: "TS", - phone: "TS", - street: "TS", - city: "TS", - state: "TS", - postal_code: "TS", - country: "TS", - email: "TS", - stock_symbol: "TS", - - stock_exchange: "NONE", ip_address: "TS", - website: "TS", - - brand_relationship: "BASIC_ACCOUNT", vertical: "TS", - alt_business_id: "TS", - - alt_business_id_type: "NONE", universal_ein: "TS", - reference_id: "TS", - - optional_attributes: Hash.new(), mock: true, - - identity_status: "SELF_DECLARED", - create_date: "2022-07-05T15:17:05Z", )}.not_to raise_error() end @@ -626,7 +595,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::SMSTenDLCBrand.new( @@ -667,6 +636,72 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::SMSTenDLCBrand.new( + account_id: "TS", + entity_type: "PRIVATE_PROFIT", + csp_id: "TS", + brand_id: "TS", + first_name: "TS", + last_name: "TS", + display_name: "TS", + company_name: "TS", + ein: "TS", + ein_issuing_country: "TS", + phone: "TS", + street: "TS", + city: "TS", + state: "TS", + postal_code: "TS", + country: "TS", + email: "TS", + stock_symbol: "TS", + stock_exchange: "NONE", + ip_address: "TS", + website: "TS", + brand_relationship: "BASIC_ACCOUNT", + vertical: "TS", + alt_business_id: "TS", + alt_business_id_type: "NONE", + universal_ein: "TS", + reference_id: "TS", + mock: true, + identity_status: "SELF_DECLARED", + ) + instance_2 = Freeclimb::SMSTenDLCBrand.new( + account_id: "TS", + entity_type: "PRIVATE_PROFIT", + csp_id: "TS", + brand_id: "TS", + first_name: "TS", + last_name: "TS", + display_name: "TS", + company_name: "TS", + ein: "TS", + ein_issuing_country: "TS", + phone: "TS", + street: "TS", + city: "TS", + state: "TS", + postal_code: "TS", + country: "TS", + email: "TS", + stock_symbol: "TS", + stock_exchange: "NONE", + ip_address: "TS", + website: "TS", + brand_relationship: "BASIC_ACCOUNT", + vertical: "TS", + alt_business_id: "TS", + alt_business_id_type: "NONE", + universal_ein: "TS", + reference_id: "TS", + mock: true, + identity_status: "SELF_DECLARED", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/sms_ten_dlc_brands_list_result_spec.rb b/spec/models/sms_ten_dlc_brands_list_result_spec.rb index ec942dba..be2b811c 100644 --- a/spec/models/sms_ten_dlc_brands_list_result_spec.rb +++ b/spec/models/sms_ten_dlc_brands_list_result_spec.rb @@ -103,65 +103,54 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::SMSTenDLCBrandsListResult.new( -total: 1, - -start: 1, - -_end: 1, - -page: 1, - -num_pages: 1, - -page_size: 1, - + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - - brands: Freeclimb::SMSTenDLCBrand.new(), - + brands: Array.new(), )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::SMSTenDLCBrandsListResult' do expect{instance = Freeclimb::SMSTenDLCBrandsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTenDLCBrand.new(), brands: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::SMSTenDLCBrandsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTenDLCBrand.new(), brands: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::SMSTenDLCBrandsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTenDLCBrand.new(), brands: Array.new(), ) expect(instance.valid?).to eq(true) @@ -169,19 +158,44 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::SMSTenDLCBrandsListResult.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + brands: Freeclimb::SMSTenDLCBrand.new(), + brands: [], + ) + instance_2 = Freeclimb::SMSTenDLCBrandsListResult.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + brands: Freeclimb::SMSTenDLCBrand.new(), + brands: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::SMSTenDLCBrandsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTenDLCBrand.new(), brands: Array.new(), ) expect(instance.hash).to be_a_kind_of(Integer) @@ -191,14 +205,13 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::SMSTenDLCBrandsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTenDLCBrand.new(), brands: Array.new(), ) instance_2 = Freeclimb::SMSTenDLCBrandsListResult.new @@ -208,14 +221,13 @@ describe 'test method "_deserialize"' do instance = Freeclimb::SMSTenDLCBrandsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTenDLCBrand.new(), brands: Array.new(), ) it 'deserializes the data of total' do @@ -254,7 +266,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTenDLCBrand.new(), brands: Array.new(), ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -271,7 +282,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTenDLCBrand.new(), brands: Array.new(), ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -286,7 +296,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTenDLCBrand.new(), brands: Array.new(), ) instance_2 = Freeclimb::SMSTenDLCBrandsListResult.new( @@ -297,7 +306,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTenDLCBrand.new(), brands: Array.new(), ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/sms_ten_dlc_campaign_spec.rb b/spec/models/sms_ten_dlc_campaign_spec.rb index b0e9d068..26b876ec 100644 --- a/spec/models/sms_ten_dlc_campaign_spec.rb +++ b/spec/models/sms_ten_dlc_campaign_spec.rb @@ -342,77 +342,40 @@ it 'properly initializes with values' do expect{instance = Freeclimb::SMSTenDLCCampaign.new( account_id: "TS", - campaign_id: "TS", - csp_id: "TS", - reseller_id: "TS", - - status: "ACTIVE", - create_date: "2022-07-05T15:17:05Z", auto_renewal: true, - - billed_date: "2022-07-05T15:17:05Z", brand_id: "TS", - usecase: "TS", - - sub_usecases: Array.new(), - description: "TS", - embedded_link: true, - embedded_phone: true, - affiliate_marketing: true, - number_pool: true, - age_gated: true, - direct_lending: true, - subscriber_optin: true, - subscriber_optout: true, - subscriber_help: true, - sample1: "TS", - sample2: "TS", - sample3: "TS", - sample4: "TS", - sample5: "TS", - message_flow: "TS", - help_message: "TS", - optin_keywords: "TS", - optout_keywords: "TS", - help_keywords: "TS", - optin_message: "TS", - optout_message: "TS", - reference_id: "TS", - mock: true, - - next_renewal_or_expiration_date: "2000-01-01", )}.not_to raise_error() end @@ -499,7 +462,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::SMSTenDLCCampaign.new( @@ -545,6 +508,80 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::SMSTenDLCCampaign.new( + account_id: "TS", + campaign_id: "TS", + csp_id: "TS", + reseller_id: "TS", + status: "ACTIVE", + auto_renewal: true, + brand_id: "TS", + usecase: "TS", + sub_usecases: [], + description: "TS", + embedded_link: true, + embedded_phone: true, + affiliate_marketing: true, + number_pool: true, + age_gated: true, + direct_lending: true, + subscriber_optin: true, + subscriber_optout: true, + subscriber_help: true, + sample1: "TS", + sample2: "TS", + sample3: "TS", + sample4: "TS", + sample5: "TS", + message_flow: "TS", + help_message: "TS", + optin_keywords: "TS", + optout_keywords: "TS", + help_keywords: "TS", + optin_message: "TS", + optout_message: "TS", + reference_id: "TS", + mock: true, + ) + instance_2 = Freeclimb::SMSTenDLCCampaign.new( + account_id: "TS", + campaign_id: "TS", + csp_id: "TS", + reseller_id: "TS", + status: "ACTIVE", + auto_renewal: true, + brand_id: "TS", + usecase: "TS", + sub_usecases: [], + description: "TS", + embedded_link: true, + embedded_phone: true, + affiliate_marketing: true, + number_pool: true, + age_gated: true, + direct_lending: true, + subscriber_optin: true, + subscriber_optout: true, + subscriber_help: true, + sample1: "TS", + sample2: "TS", + sample3: "TS", + sample4: "TS", + sample5: "TS", + message_flow: "TS", + help_message: "TS", + optin_keywords: "TS", + optout_keywords: "TS", + help_keywords: "TS", + optin_message: "TS", + optout_message: "TS", + reference_id: "TS", + mock: true, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/sms_ten_dlc_campaigns_list_result_spec.rb b/spec/models/sms_ten_dlc_campaigns_list_result_spec.rb index 3543199c..ab4805ca 100644 --- a/spec/models/sms_ten_dlc_campaigns_list_result_spec.rb +++ b/spec/models/sms_ten_dlc_campaigns_list_result_spec.rb @@ -103,65 +103,54 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::SMSTenDLCCampaignsListResult.new( -total: 1, - -start: 1, - -_end: 1, - -page: 1, - -num_pages: 1, - -page_size: 1, - + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - - campaigns: Freeclimb::SMSTenDLCCampaign.new(), - + campaigns: Array.new(), )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::SMSTenDLCCampaignsListResult' do expect{instance = Freeclimb::SMSTenDLCCampaignsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - campaigns: Freeclimb::SMSTenDLCCampaign.new(), campaigns: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::SMSTenDLCCampaignsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - campaigns: Freeclimb::SMSTenDLCCampaign.new(), campaigns: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::SMSTenDLCCampaignsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - campaigns: Freeclimb::SMSTenDLCCampaign.new(), campaigns: Array.new(), ) expect(instance.valid?).to eq(true) @@ -169,19 +158,44 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::SMSTenDLCCampaignsListResult.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + campaigns: Freeclimb::SMSTenDLCCampaign.new(), + campaigns: [], + ) + instance_2 = Freeclimb::SMSTenDLCCampaignsListResult.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + campaigns: Freeclimb::SMSTenDLCCampaign.new(), + campaigns: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::SMSTenDLCCampaignsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - campaigns: Freeclimb::SMSTenDLCCampaign.new(), campaigns: Array.new(), ) expect(instance.hash).to be_a_kind_of(Integer) @@ -191,14 +205,13 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::SMSTenDLCCampaignsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - campaigns: Freeclimb::SMSTenDLCCampaign.new(), campaigns: Array.new(), ) instance_2 = Freeclimb::SMSTenDLCCampaignsListResult.new @@ -208,14 +221,13 @@ describe 'test method "_deserialize"' do instance = Freeclimb::SMSTenDLCCampaignsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - campaigns: Freeclimb::SMSTenDLCCampaign.new(), campaigns: Array.new(), ) it 'deserializes the data of total' do @@ -254,7 +266,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - campaigns: Freeclimb::SMSTenDLCCampaign.new(), campaigns: Array.new(), ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -271,7 +282,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - campaigns: Freeclimb::SMSTenDLCCampaign.new(), campaigns: Array.new(), ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -286,7 +296,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - campaigns: Freeclimb::SMSTenDLCCampaign.new(), campaigns: Array.new(), ) instance_2 = Freeclimb::SMSTenDLCCampaignsListResult.new( @@ -297,7 +306,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - campaigns: Freeclimb::SMSTenDLCCampaign.new(), campaigns: Array.new(), ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/sms_ten_dlc_partner_campaign_brand_spec.rb b/spec/models/sms_ten_dlc_partner_campaign_brand_spec.rb index 78d92973..61edd08d 100644 --- a/spec/models/sms_ten_dlc_partner_campaign_brand_spec.rb +++ b/spec/models/sms_ten_dlc_partner_campaign_brand_spec.rb @@ -132,27 +132,16 @@ it 'properly initializes with values' do expect{instance = Freeclimb::SMSTenDLCPartnerCampaignBrand.new( account_id: "TS", - brand_id: "TS", - first_name: "TS", - last_name: "TS", - display_name: "TS", - company_name: "TS", - phone: "TS", - email: "TS", - website: "TS", - - optional_attributes: Hash.new(), -evp_vetting_score: 1, - + evp_vetting_score: 1, )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::SMSTenDLCPartnerCampaignBrand' do @@ -167,7 +156,7 @@ email: "TS", website: "TS", optional_attributes: Hash.new(), -evp_vetting_score: 1, + evp_vetting_score: 1, invalid_attribute: true )}.to raise_error(ArgumentError) end @@ -183,12 +172,12 @@ email: "TS", website: "TS", optional_attributes: Hash.new(), -evp_vetting_score: 1, + evp_vetting_score: 1, invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::SMSTenDLCPartnerCampaignBrand.new( @@ -202,13 +191,41 @@ email: "TS", website: "TS", optional_attributes: Hash.new(), -evp_vetting_score: 1, + evp_vetting_score: 1, ) expect(instance.valid?).to eq(true) end end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::SMSTenDLCPartnerCampaignBrand.new( + account_id: "TS", + brand_id: "TS", + first_name: "TS", + last_name: "TS", + display_name: "TS", + company_name: "TS", + phone: "TS", + email: "TS", + website: "TS", + evp_vetting_score: 1, + ) + instance_2 = Freeclimb::SMSTenDLCPartnerCampaignBrand.new( + account_id: "TS", + brand_id: "TS", + first_name: "TS", + last_name: "TS", + display_name: "TS", + company_name: "TS", + phone: "TS", + email: "TS", + website: "TS", + evp_vetting_score: 1, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -224,7 +241,7 @@ email: "TS", website: "TS", optional_attributes: Hash.new(), -evp_vetting_score: 1, + evp_vetting_score: 1, ) expect(instance.hash).to be_a_kind_of(Integer) end @@ -243,7 +260,7 @@ email: "TS", website: "TS", optional_attributes: Hash.new(), -evp_vetting_score: 1, + evp_vetting_score: 1, ) instance_2 = Freeclimb::SMSTenDLCPartnerCampaignBrand.new expect(instance_2.build_from_hash(instance_1.hash)).to eq(instance_1.build_from_hash(instance_1.hash)) @@ -262,7 +279,7 @@ email: "TS", website: "TS", optional_attributes: Hash.new(), -evp_vetting_score: 1, + evp_vetting_score: 1, ) it 'deserializes the data of account_id' do expect(instance._deserialize("String", instance.account_id)).to be_a_kind_of(String) diff --git a/spec/models/sms_ten_dlc_partner_campaign_spec.rb b/spec/models/sms_ten_dlc_partner_campaign_spec.rb index 750ac0d1..5e25401a 100644 --- a/spec/models/sms_ten_dlc_partner_campaign_spec.rb +++ b/spec/models/sms_ten_dlc_partner_campaign_spec.rb @@ -287,64 +287,34 @@ it 'properly initializes with values' do expect{instance = Freeclimb::SMSTenDLCPartnerCampaign.new( account_id: "TS", - campaign_id: "TS", - - status: "ACTIVE", - create_date: "2022-07-05T15:17:05Z", brand_id: "TS", - usecase: "TS", - description: "TS", - embedded_link: true, - embedded_phone: true, - affiliate_marketing: true, - number_pool: true, - age_gated: true, - direct_lending: true, - subscriber_optin: true, - subscriber_optout: true, - subscriber_help: true, - sample1: "TS", - sample2: "TS", - sample3: "TS", - sample4: "TS", - sample5: "TS", - message_flow: "TS", - help_message: "TS", - optin_keywords: "TS", - optout_keywords: "TS", - help_keywords: "TS", - optin_message: "TS", - optout_message: "TS", - brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new(), - - brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new, )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::SMSTenDLCPartnerCampaign' do @@ -377,7 +347,6 @@ help_keywords: "TS", optin_message: "TS", optout_message: "TS", - brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new(), brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new, invalid_attribute: true )}.to raise_error(ArgumentError) @@ -412,13 +381,12 @@ help_keywords: "TS", optin_message: "TS", optout_message: "TS", - brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new(), brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new, invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::SMSTenDLCPartnerCampaign.new( @@ -451,13 +419,76 @@ optin_message: "TS", optout_message: "TS", brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new(), - brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new, ) expect(instance.valid?).to eq(true) end end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::SMSTenDLCPartnerCampaign.new( + account_id: "TS", + campaign_id: "TS", + status: "ACTIVE", + brand_id: "TS", + usecase: "TS", + description: "TS", + embedded_link: true, + embedded_phone: true, + affiliate_marketing: true, + number_pool: true, + age_gated: true, + direct_lending: true, + subscriber_optin: true, + subscriber_optout: true, + subscriber_help: true, + sample1: "TS", + sample2: "TS", + sample3: "TS", + sample4: "TS", + sample5: "TS", + message_flow: "TS", + help_message: "TS", + optin_keywords: "TS", + optout_keywords: "TS", + help_keywords: "TS", + optin_message: "TS", + optout_message: "TS", + brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new(), + ) + instance_2 = Freeclimb::SMSTenDLCPartnerCampaign.new( + account_id: "TS", + campaign_id: "TS", + status: "ACTIVE", + brand_id: "TS", + usecase: "TS", + description: "TS", + embedded_link: true, + embedded_phone: true, + affiliate_marketing: true, + number_pool: true, + age_gated: true, + direct_lending: true, + subscriber_optin: true, + subscriber_optout: true, + subscriber_help: true, + sample1: "TS", + sample2: "TS", + sample3: "TS", + sample4: "TS", + sample5: "TS", + message_flow: "TS", + help_message: "TS", + optin_keywords: "TS", + optout_keywords: "TS", + help_keywords: "TS", + optin_message: "TS", + optout_message: "TS", + brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new(), + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -492,7 +523,6 @@ optin_message: "TS", optout_message: "TS", brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new(), - brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new, ) expect(instance.hash).to be_a_kind_of(Integer) end @@ -530,7 +560,6 @@ optin_message: "TS", optout_message: "TS", brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new(), - brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new, ) instance_2 = Freeclimb::SMSTenDLCPartnerCampaign.new expect(instance_2.build_from_hash(instance_1.hash)).to eq(instance_1.build_from_hash(instance_1.hash)) @@ -567,7 +596,6 @@ help_keywords: "TS", optin_message: "TS", optout_message: "TS", - brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new(), brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new, ) it 'deserializes the data of account_id' do @@ -690,7 +718,6 @@ help_keywords: "TS", optin_message: "TS", optout_message: "TS", - brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new(), brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new, ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -728,7 +755,6 @@ help_keywords: "TS", optin_message: "TS", optout_message: "TS", - brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new(), brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new, ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -764,7 +790,6 @@ help_keywords: "TS", optin_message: "TS", optout_message: "TS", - brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new(), brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new, ) instance_2 = Freeclimb::SMSTenDLCPartnerCampaign.new( @@ -796,7 +821,6 @@ help_keywords: "TS", optin_message: "TS", optout_message: "TS", - brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new(), brand: Freeclimb::SMSTenDLCPartnerCampaignBrand.new, ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/sms_ten_dlc_partner_campaigns_list_result_spec.rb b/spec/models/sms_ten_dlc_partner_campaigns_list_result_spec.rb index 4a4f89db..af899100 100644 --- a/spec/models/sms_ten_dlc_partner_campaigns_list_result_spec.rb +++ b/spec/models/sms_ten_dlc_partner_campaigns_list_result_spec.rb @@ -103,65 +103,54 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::SMSTenDLCPartnerCampaignsListResult.new( -total: 1, - -start: 1, - -_end: 1, - -page: 1, - -num_pages: 1, - -page_size: 1, - + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - - partner_campaigns: Freeclimb::SMSTenDLCPartnerCampaign.new(), - + partner_campaigns: Array.new(), )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::SMSTenDLCPartnerCampaignsListResult' do expect{instance = Freeclimb::SMSTenDLCPartnerCampaignsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - partner_campaigns: Freeclimb::SMSTenDLCPartnerCampaign.new(), partner_campaigns: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::SMSTenDLCPartnerCampaignsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - partner_campaigns: Freeclimb::SMSTenDLCPartnerCampaign.new(), partner_campaigns: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::SMSTenDLCPartnerCampaignsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - partner_campaigns: Freeclimb::SMSTenDLCPartnerCampaign.new(), partner_campaigns: Array.new(), ) expect(instance.valid?).to eq(true) @@ -169,19 +158,44 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::SMSTenDLCPartnerCampaignsListResult.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + partner_campaigns: Freeclimb::SMSTenDLCPartnerCampaign.new(), + partner_campaigns: [], + ) + instance_2 = Freeclimb::SMSTenDLCPartnerCampaignsListResult.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + partner_campaigns: Freeclimb::SMSTenDLCPartnerCampaign.new(), + partner_campaigns: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::SMSTenDLCPartnerCampaignsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - partner_campaigns: Freeclimb::SMSTenDLCPartnerCampaign.new(), partner_campaigns: Array.new(), ) expect(instance.hash).to be_a_kind_of(Integer) @@ -191,14 +205,13 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::SMSTenDLCPartnerCampaignsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - partner_campaigns: Freeclimb::SMSTenDLCPartnerCampaign.new(), partner_campaigns: Array.new(), ) instance_2 = Freeclimb::SMSTenDLCPartnerCampaignsListResult.new @@ -208,14 +221,13 @@ describe 'test method "_deserialize"' do instance = Freeclimb::SMSTenDLCPartnerCampaignsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - partner_campaigns: Freeclimb::SMSTenDLCPartnerCampaign.new(), partner_campaigns: Array.new(), ) it 'deserializes the data of total' do @@ -254,7 +266,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - partner_campaigns: Freeclimb::SMSTenDLCPartnerCampaign.new(), partner_campaigns: Array.new(), ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -271,7 +282,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - partner_campaigns: Freeclimb::SMSTenDLCPartnerCampaign.new(), partner_campaigns: Array.new(), ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -286,7 +296,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - partner_campaigns: Freeclimb::SMSTenDLCPartnerCampaign.new(), partner_campaigns: Array.new(), ) instance_2 = Freeclimb::SMSTenDLCPartnerCampaignsListResult.new( @@ -297,7 +306,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - partner_campaigns: Freeclimb::SMSTenDLCPartnerCampaign.new(), partner_campaigns: Array.new(), ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/sms_toll_free_campaign_spec.rb b/spec/models/sms_toll_free_campaign_spec.rb index cc4370de..6d36dbce 100644 --- a/spec/models/sms_toll_free_campaign_spec.rb +++ b/spec/models/sms_toll_free_campaign_spec.rb @@ -103,19 +103,12 @@ it 'properly initializes with values' do expect{instance = Freeclimb::SMSTollFreeCampaign.new( account_id: "TS", - campaign_id: "TS", - use_case: "TS", - - registration_status: "UNREGISTERED", date_created: "TS", - date_updated: "TS", - -revision: 1, - + revision: 1, )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::SMSTollFreeCampaign' do @@ -126,7 +119,7 @@ registration_status: "UNREGISTERED", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, invalid_attribute: true )}.to raise_error(ArgumentError) end @@ -138,12 +131,12 @@ registration_status: "UNREGISTERED", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::SMSTollFreeCampaign.new( @@ -153,13 +146,35 @@ registration_status: "UNREGISTERED", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, ) expect(instance.valid?).to eq(true) end end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::SMSTollFreeCampaign.new( + account_id: "TS", + campaign_id: "TS", + use_case: "TS", + registration_status: "UNREGISTERED", + date_created: "TS", + date_updated: "TS", + revision: 1, + ) + instance_2 = Freeclimb::SMSTollFreeCampaign.new( + account_id: "TS", + campaign_id: "TS", + use_case: "TS", + registration_status: "UNREGISTERED", + date_created: "TS", + date_updated: "TS", + revision: 1, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -171,7 +186,7 @@ registration_status: "UNREGISTERED", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, ) expect(instance.hash).to be_a_kind_of(Integer) end @@ -186,7 +201,7 @@ registration_status: "UNREGISTERED", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, ) instance_2 = Freeclimb::SMSTollFreeCampaign.new expect(instance_2.build_from_hash(instance_1.hash)).to eq(instance_1.build_from_hash(instance_1.hash)) @@ -201,7 +216,7 @@ registration_status: "UNREGISTERED", date_created: "TS", date_updated: "TS", -revision: 1, + revision: 1, ) it 'deserializes the data of account_id' do expect(instance._deserialize("String", instance.account_id)).to be_a_kind_of(String) diff --git a/spec/models/sms_toll_free_campaigns_list_result_spec.rb b/spec/models/sms_toll_free_campaigns_list_result_spec.rb index 3ab81b29..630c945b 100644 --- a/spec/models/sms_toll_free_campaigns_list_result_spec.rb +++ b/spec/models/sms_toll_free_campaigns_list_result_spec.rb @@ -103,65 +103,54 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::SMSTollFreeCampaignsListResult.new( -total: 1, - -start: 1, - -_end: 1, - -page: 1, - -num_pages: 1, - -page_size: 1, - + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - - brands: Freeclimb::SMSTollFreeCampaign.new(), - + brands: Array.new(), )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::SMSTollFreeCampaignsListResult' do expect{instance = Freeclimb::SMSTollFreeCampaignsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTollFreeCampaign.new(), brands: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::SMSTollFreeCampaignsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTollFreeCampaign.new(), brands: Array.new(), invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::SMSTollFreeCampaignsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTollFreeCampaign.new(), brands: Array.new(), ) expect(instance.valid?).to eq(true) @@ -169,19 +158,44 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::SMSTollFreeCampaignsListResult.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + brands: Freeclimb::SMSTollFreeCampaign.new(), + brands: [], + ) + instance_2 = Freeclimb::SMSTollFreeCampaignsListResult.new( + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, + next_page_uri: "TS", + brands: Freeclimb::SMSTollFreeCampaign.new(), + brands: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::SMSTollFreeCampaignsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTollFreeCampaign.new(), brands: Array.new(), ) expect(instance.hash).to be_a_kind_of(Integer) @@ -191,14 +205,13 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::SMSTollFreeCampaignsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTollFreeCampaign.new(), brands: Array.new(), ) instance_2 = Freeclimb::SMSTollFreeCampaignsListResult.new @@ -208,14 +221,13 @@ describe 'test method "_deserialize"' do instance = Freeclimb::SMSTollFreeCampaignsListResult.new( -total: 1, -start: 1, -_end: 1, -page: 1, -num_pages: 1, -page_size: 1, + total: 1, + start: 1, + _end: 1, + page: 1, + num_pages: 1, + page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTollFreeCampaign.new(), brands: Array.new(), ) it 'deserializes the data of total' do @@ -254,7 +266,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTollFreeCampaign.new(), brands: Array.new(), ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -271,7 +282,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTollFreeCampaign.new(), brands: Array.new(), ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -286,7 +296,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTollFreeCampaign.new(), brands: Array.new(), ) instance_2 = Freeclimb::SMSTollFreeCampaignsListResult.new( @@ -297,7 +306,6 @@ num_pages: 1, page_size: 1, next_page_uri: "TS", - brands: Freeclimb::SMSTollFreeCampaign.new(), brands: Array.new(), ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/terminate_conference_spec.rb b/spec/models/terminate_conference_spec.rb index 2d3cc73f..a57ad199 100644 --- a/spec/models/terminate_conference_spec.rb +++ b/spec/models/terminate_conference_spec.rb @@ -42,7 +42,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::TerminateConference.new( @@ -52,6 +52,14 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::TerminateConference.new( + ) + instance_2 = Freeclimb::TerminateConference.new( + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/tfn_spec.rb b/spec/models/tfn_spec.rb index db1e3abc..778b72f8 100644 --- a/spec/models/tfn_spec.rb +++ b/spec/models/tfn_spec.rb @@ -37,7 +37,6 @@ it 'properly initializes with values' do expect{instance = Freeclimb::TFN.new( campaign_id: "TS", - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::TFN' do @@ -53,7 +52,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::TFN.new( @@ -64,6 +63,16 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::TFN.new( + campaign_id: "TS", + ) + instance_2 = Freeclimb::TFN.new( + campaign_id: "TS", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/transcribe_utterance_all_of_record_spec.rb b/spec/models/transcribe_utterance_all_of_record_spec.rb index 22e23c5b..23e8b150 100644 --- a/spec/models/transcribe_utterance_all_of_record_spec.rb +++ b/spec/models/transcribe_utterance_all_of_record_spec.rb @@ -55,11 +55,8 @@ it 'properly initializes with values' do expect{instance = Freeclimb::TranscribeUtteranceAllOfRecord.new( save_recording: true, - max_length_sec: 60, - rcrd_termination_silence_time_ms: 3000, - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::TranscribeUtteranceAllOfRecord' do @@ -79,7 +76,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::TranscribeUtteranceAllOfRecord.new( @@ -92,6 +89,20 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::TranscribeUtteranceAllOfRecord.new( + save_recording: true, + max_length_sec: 60, + rcrd_termination_silence_time_ms: 3000, + ) + instance_2 = Freeclimb::TranscribeUtteranceAllOfRecord.new( + save_recording: true, + max_length_sec: 60, + rcrd_termination_silence_time_ms: 3000, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/transcribe_utterance_spec.rb b/spec/models/transcribe_utterance_spec.rb index 3bd820e2..ee38e373 100644 --- a/spec/models/transcribe_utterance_spec.rb +++ b/spec/models/transcribe_utterance_spec.rb @@ -72,26 +72,17 @@ it 'properly initializes with values' do expect{instance = Freeclimb::TranscribeUtterance.new( action_url: "TS", - play_beep: true, - record: Freeclimb::TranscribeUtteranceAllOfRecord.new(), - - record: Freeclimb::TranscribeUtteranceAllOfRecord.new, privacy_for_logging: true, - privacy_for_recording: true, - - prompts: Array.new(), - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::TranscribeUtterance' do expect{instance = Freeclimb::TranscribeUtterance.new( action_url: "TS", play_beep: true, - record: Freeclimb::TranscribeUtteranceAllOfRecord.new(), record: Freeclimb::TranscribeUtteranceAllOfRecord.new, privacy_for_logging: true, privacy_for_recording: true, @@ -103,7 +94,6 @@ expect{instance = Freeclimb::TranscribeUtterance.new( action_url: "TS", play_beep: true, - record: Freeclimb::TranscribeUtteranceAllOfRecord.new(), record: Freeclimb::TranscribeUtteranceAllOfRecord.new, privacy_for_logging: true, privacy_for_recording: true, @@ -112,14 +102,13 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::TranscribeUtterance.new( action_url: "TS", play_beep: true, record: Freeclimb::TranscribeUtteranceAllOfRecord.new(), - record: Freeclimb::TranscribeUtteranceAllOfRecord.new, privacy_for_logging: true, privacy_for_recording: true, prompts: Array.new(), @@ -129,6 +118,26 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::TranscribeUtterance.new( + action_url: "TS", + play_beep: true, + record: Freeclimb::TranscribeUtteranceAllOfRecord.new(), + privacy_for_logging: true, + privacy_for_recording: true, + prompts: [], + ) + instance_2 = Freeclimb::TranscribeUtterance.new( + action_url: "TS", + play_beep: true, + record: Freeclimb::TranscribeUtteranceAllOfRecord.new(), + privacy_for_logging: true, + privacy_for_recording: true, + prompts: [], + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do @@ -137,7 +146,6 @@ action_url: "TS", play_beep: true, record: Freeclimb::TranscribeUtteranceAllOfRecord.new(), - record: Freeclimb::TranscribeUtteranceAllOfRecord.new, privacy_for_logging: true, privacy_for_recording: true, prompts: Array.new(), @@ -152,7 +160,6 @@ action_url: "TS", play_beep: true, record: Freeclimb::TranscribeUtteranceAllOfRecord.new(), - record: Freeclimb::TranscribeUtteranceAllOfRecord.new, privacy_for_logging: true, privacy_for_recording: true, prompts: Array.new(), @@ -166,7 +173,6 @@ instance = Freeclimb::TranscribeUtterance.new( action_url: "TS", play_beep: true, - record: Freeclimb::TranscribeUtteranceAllOfRecord.new(), record: Freeclimb::TranscribeUtteranceAllOfRecord.new, privacy_for_logging: true, privacy_for_recording: true, @@ -197,7 +203,6 @@ instance = Freeclimb::TranscribeUtterance.new( action_url: "TS", play_beep: true, - record: Freeclimb::TranscribeUtteranceAllOfRecord.new(), record: Freeclimb::TranscribeUtteranceAllOfRecord.new, privacy_for_logging: true, privacy_for_recording: true, @@ -212,7 +217,6 @@ instance = Freeclimb::TranscribeUtterance.new( action_url: "TS", play_beep: true, - record: Freeclimb::TranscribeUtteranceAllOfRecord.new(), record: Freeclimb::TranscribeUtteranceAllOfRecord.new, privacy_for_logging: true, privacy_for_recording: true, @@ -225,7 +229,6 @@ instance_1 = Freeclimb::TranscribeUtterance.new( action_url: "TS", play_beep: true, - record: Freeclimb::TranscribeUtteranceAllOfRecord.new(), record: Freeclimb::TranscribeUtteranceAllOfRecord.new, privacy_for_logging: true, privacy_for_recording: true, @@ -234,7 +237,6 @@ instance_2 = Freeclimb::TranscribeUtterance.new( action_url: "TS", play_beep: true, - record: Freeclimb::TranscribeUtteranceAllOfRecord.new(), record: Freeclimb::TranscribeUtteranceAllOfRecord.new, privacy_for_logging: true, privacy_for_recording: true, diff --git a/spec/models/update_call_request_spec.rb b/spec/models/update_call_request_spec.rb index ae5b19c1..67444de8 100644 --- a/spec/models/update_call_request_spec.rb +++ b/spec/models/update_call_request_spec.rb @@ -41,31 +41,26 @@ describe 'test method "initialize"' do it 'properly initializes with values' do expect{instance = Freeclimb::UpdateCallRequest.new( - status: Freeclimb::UpdateCallRequestStatus.new(), - status: "CANCELED", )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::UpdateCallRequest' do expect{instance = Freeclimb::UpdateCallRequest.new( - status: Freeclimb::UpdateCallRequestStatus.new(), status: "CANCELED", invalid_attribute: true )}.to raise_error(ArgumentError) end it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::UpdateCallRequest.new( - status: Freeclimb::UpdateCallRequestStatus.new(), status: "CANCELED", invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::UpdateCallRequest.new( - status: Freeclimb::UpdateCallRequestStatus.new(), status: "CANCELED", ) expect(instance.valid?).to eq(true) @@ -73,12 +68,23 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::UpdateCallRequest.new( + status: Freeclimb::UpdateCallRequestStatus.new(), + status: "CANCELED", + ) + instance_2 = Freeclimb::UpdateCallRequest.new( + status: Freeclimb::UpdateCallRequestStatus.new(), + status: "CANCELED", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::UpdateCallRequest.new( - status: Freeclimb::UpdateCallRequestStatus.new(), status: "CANCELED", ) expect(instance.hash).to be_a_kind_of(Integer) @@ -88,7 +94,6 @@ describe 'test method "build_from_hash"' do it 'builds equivalent model from hash code' do instance_1 = Freeclimb::UpdateCallRequest.new( - status: Freeclimb::UpdateCallRequestStatus.new(), status: "CANCELED", ) instance_2 = Freeclimb::UpdateCallRequest.new @@ -98,7 +103,6 @@ describe 'test method "_deserialize"' do instance = Freeclimb::UpdateCallRequest.new( - status: Freeclimb::UpdateCallRequestStatus.new(), status: "CANCELED", ) end @@ -106,7 +110,6 @@ describe 'test method "to_s"' do it 'returns the string representation of the object' do instance = Freeclimb::UpdateCallRequest.new( - status: Freeclimb::UpdateCallRequestStatus.new(), status: "CANCELED", ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -116,7 +119,6 @@ describe 'test method "to_hash"' do it 'returns the object in the form of hash' do instance = Freeclimb::UpdateCallRequest.new( - status: Freeclimb::UpdateCallRequestStatus.new(), status: "CANCELED", ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -124,11 +126,9 @@ it 'creates equal hash for two equal objects' do obj = Object.new() instance_1 = Freeclimb::UpdateCallRequest.new( - status: Freeclimb::UpdateCallRequestStatus.new(), status: "CANCELED", ) instance_2 = Freeclimb::UpdateCallRequest.new( - status: Freeclimb::UpdateCallRequestStatus.new(), status: "CANCELED", ) expect(instance_1.to_hash).to eq(instance_2.to_hash) diff --git a/spec/models/update_conference_participant_request_spec.rb b/spec/models/update_conference_participant_request_spec.rb index e75c3944..1b6a13e1 100644 --- a/spec/models/update_conference_participant_request_spec.rb +++ b/spec/models/update_conference_participant_request_spec.rb @@ -44,9 +44,7 @@ it 'properly initializes with values' do expect{instance = Freeclimb::UpdateConferenceParticipantRequest.new( talk: true, - listen: true, - )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::UpdateConferenceParticipantRequest' do @@ -64,7 +62,7 @@ )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::UpdateConferenceParticipantRequest.new( @@ -76,6 +74,18 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::UpdateConferenceParticipantRequest.new( + talk: true, + listen: true, + ) + instance_2 = Freeclimb::UpdateConferenceParticipantRequest.new( + talk: true, + listen: true, + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do diff --git a/spec/models/update_conference_request_spec.rb b/spec/models/update_conference_request_spec.rb index 1cb42a52..ff85121a 100644 --- a/spec/models/update_conference_request_spec.rb +++ b/spec/models/update_conference_request_spec.rb @@ -69,21 +69,14 @@ it 'properly initializes with values' do expect{instance = Freeclimb::UpdateConferenceRequest.new( _alias: "TS", - - play_beep: Freeclimb::PlayBeep.new(), - play_beep: "ALWAYS", - status: Freeclimb::UpdateConferenceRequestStatus.new(), - status: "EMPTY", )}.not_to raise_error() end it 'fails to initialize with input argument that is not a hash in Freeclimb::UpdateConferenceRequest' do expect{instance = Freeclimb::UpdateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", - status: Freeclimb::UpdateConferenceRequestStatus.new(), status: "EMPTY", invalid_attribute: true )}.to raise_error(ArgumentError) @@ -91,22 +84,18 @@ it 'fails to initialize with invalid attribute' do expect{instance = Freeclimb::UpdateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", - status: Freeclimb::UpdateConferenceRequestStatus.new(), status: "EMPTY", invalid_attribute: true )}.to raise_error(ArgumentError) end end - + describe 'test method "valid"' do it 'checks if properties are valid' do instance = Freeclimb::UpdateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", - status: Freeclimb::UpdateConferenceRequestStatus.new(), status: "EMPTY", ) expect(instance.valid?).to eq(true) @@ -114,15 +103,31 @@ end describe 'test method "eql?"' do + it 'checks if objects are equal' do + obj = Object.new() + instance_1 = Freeclimb::UpdateConferenceRequest.new( + _alias: "TS", + play_beep: Freeclimb::PlayBeep.new(), + play_beep: "ALWAYS", + status: Freeclimb::UpdateConferenceRequestStatus.new(), + status: "EMPTY", + ) + instance_2 = Freeclimb::UpdateConferenceRequest.new( + _alias: "TS", + play_beep: Freeclimb::PlayBeep.new(), + play_beep: "ALWAYS", + status: Freeclimb::UpdateConferenceRequestStatus.new(), + status: "EMPTY", + ) + expect(instance_1.eql?(instance_2)).to eq(true) + end end describe 'test method "hash"' do it 'calculates hash code' do instance = Freeclimb::UpdateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", - status: Freeclimb::UpdateConferenceRequestStatus.new(), status: "EMPTY", ) expect(instance.hash).to be_a_kind_of(Integer) @@ -133,9 +138,7 @@ it 'builds equivalent model from hash code' do instance_1 = Freeclimb::UpdateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", - status: Freeclimb::UpdateConferenceRequestStatus.new(), status: "EMPTY", ) instance_2 = Freeclimb::UpdateConferenceRequest.new @@ -146,9 +149,7 @@ describe 'test method "_deserialize"' do instance = Freeclimb::UpdateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", - status: Freeclimb::UpdateConferenceRequestStatus.new(), status: "EMPTY", ) it 'deserializes the data of _alias' do @@ -160,9 +161,7 @@ it 'returns the string representation of the object' do instance = Freeclimb::UpdateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", - status: Freeclimb::UpdateConferenceRequestStatus.new(), status: "EMPTY", ) expect(instance.to_s).to eq(instance.to_hash.to_s) @@ -173,9 +172,7 @@ it 'returns the object in the form of hash' do instance = Freeclimb::UpdateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", - status: Freeclimb::UpdateConferenceRequestStatus.new(), status: "EMPTY", ) expect(instance.to_hash).to be_a_kind_of(Hash) @@ -184,16 +181,12 @@ obj = Object.new() instance_1 = Freeclimb::UpdateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", - status: Freeclimb::UpdateConferenceRequestStatus.new(), status: "EMPTY", ) instance_2 = Freeclimb::UpdateConferenceRequest.new( _alias: "TS", - play_beep: Freeclimb::PlayBeep.new(), play_beep: "ALWAYS", - status: Freeclimb::UpdateConferenceRequestStatus.new(), status: "EMPTY", ) expect(instance_1.to_hash).to eq(instance_2.to_hash)