Sha256: 6ae6f507d8c6db3ab1b14fe1e53aded902040d8925cb6b5a5719c7640ae9b8a0
Contents?: true
Size: 974 Bytes
Versions: 3
Compression:
Stored size: 974 Bytes
Contents
# frozen_string_literal: true require 'spec_helper' RSpec.describe 'email sync' do describe 'unsubscribes' do it 'responds with unsubscribed emails', vcr: true do response = api.email_unsubscribes(start_date: '2020-06-17', end_date: '2020-06-18') emails = JSON.parse(response.body)['emails'] expect(emails.size).to eq(1) expect(emails.first['email']).to eq('example@123.com') end it 'responds with empty array when no unsubscribes', vcr: true do response = api.email_unsubscribes(start_date: '2019-02-20', end_date: '2019-02-25') emails = JSON.parse(response.body)['emails'] expect(emails.size).to eq(0) end end describe 'hard_bounces' do it 'responds with empty array when no hard bounces', vcr: true do response = api.email_hard_bounces(start_date: '2019-02-20', end_date: '2019-02-25') emails = JSON.parse(response.body)['emails'] expect(emails.size).to eq(0) end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
braze_ruby-0.4.2 | spec/integrations/email_sync_spec.rb |
braze_ruby-0.4.1 | spec/integrations/email_sync_spec.rb |
braze_ruby-0.4.0 | spec/integrations/email_sync_spec.rb |