spec/rest/whitelabel/domains_spec.rb in sendgrid4r-1.3.0 vs spec/rest/whitelabel/domains_spec.rb in sendgrid4r-1.4.0

- old
+ new

@@ -116,13 +116,10 @@ expect(@domain1.legacy).to eq(false) expect(@domain1.valid).to eq(false) expect(@domain1.dns.mail_cname).to be_a( SendGrid4r::REST::Whitelabel::Domains::Record ) - expect(@domain1.dns.spf).to be_a( - SendGrid4r::REST::Whitelabel::Domains::Record - ) expect(@domain1.dns.dkim1).to be_a( SendGrid4r::REST::Whitelabel::Domains::Record ) expect(@domain1.dns.dkim2).to be_a( SendGrid4r::REST::Whitelabel::Domains::Record @@ -144,13 +141,10 @@ SendGrid4r::REST::Whitelabel::Domains::Record ) expect(@domain2.dns.subdomain_spf).to be_a( SendGrid4r::REST::Whitelabel::Domains::Record ) - expect(@domain2.dns.domain_spf).to be_a( - SendGrid4r::REST::Whitelabel::Domains::Record - ) expect(@domain2.dns.dkim).to be_a( SendGrid4r::REST::Whitelabel::Domains::Record ) rescue RestClient::ExceptionWithResponse => e puts e.inspect @@ -173,13 +167,10 @@ expect(domain1.legacy).to eq(false) expect(domain1.valid).to eq(false) expect(domain1.dns.mail_cname).to be_a( SendGrid4r::REST::Whitelabel::Domains::Record ) - expect(domain1.dns.spf).to be_a( - SendGrid4r::REST::Whitelabel::Domains::Record - ) expect(domain1.dns.dkim1).to be_a( SendGrid4r::REST::Whitelabel::Domains::Record ) expect(domain1.dns.dkim2).to be_a( SendGrid4r::REST::Whitelabel::Domains::Record @@ -200,13 +191,10 @@ SendGrid4r::REST::Whitelabel::Domains::Record ) expect(domain2.dns.subdomain_spf).to be_a( SendGrid4r::REST::Whitelabel::Domains::Record ) - expect(domain2.dns.domain_spf).to be_a( - SendGrid4r::REST::Whitelabel::Domains::Record - ) expect(domain2.dns.dkim).to be_a( SendGrid4r::REST::Whitelabel::Domains::Record ) rescue RestClient::ExceptionWithResponse => e puts e.inspect @@ -290,13 +278,10 @@ false ) expect(result1.validation_results.dkim2.valid).to be( false ) - expect(result1.validation_results.spf.valid).to be( - false - ) result2 = @client.validate_wl_domain(id: @domain2.id) expect(result2).to be_a( SendGrid4r::REST::Whitelabel::Domains::Result ) expect(result2.valid).to be(false) @@ -304,13 +289,10 @@ false ) expect(result2.validation_results.subdomain_spf.valid).to be( false ) - expect(result2.validation_results.domain_spf.valid).to be( - false - ) expect(result2.validation_results.dkim.valid).to be( false ) rescue RestClient::ExceptionWithResponse => e puts e.inspect @@ -380,16 +362,10 @@ '"host": "mail.example.com",'\ '"type": "cname",'\ '"data": "u7.wl.sendgrid.net",'\ '"valid": true'\ '},'\ - '"spf": {'\ - '"host": "example.com",'\ - '"type": "txt",'\ - '"data": "v=spf1 include:u7.wl.sendgrid.net -all",'\ - '"valid": true'\ - '},'\ '"dkim1": {'\ '"host": "s1._domainkey.example.com",'\ '"type": "cname",'\ '"data": "s1._domainkey.u7.wl.sendgrid.net",'\ '"valid": true'\ @@ -430,16 +406,10 @@ '"valid": false,'\ '"type": "txt",'\ '"host": "mail2.example.com",'\ '"data": "v=spf1 include:sendgrid.net ~all"'\ '},'\ - '"domain_spf": {'\ - '"valid": false,'\ - '"type": "txt",'\ - '"host": "example.com",'\ - '"data": "v=spf1 include:mail2.example.com -all"'\ - '},'\ '"dkim": {'\ '"valid": false,'\ '"type": "txt",'\ '"host": "m1._domainkey.example.com",'\ '"data": "k=rsa; t=s; p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQ"'\ @@ -465,14 +435,10 @@ '"reason": null'\ '},'\ '"dkim2": {'\ '"valid": true,'\ '"reason": null'\ - '},'\ - '"spf": {'\ - '"valid": true,'\ - '"reason": null'\ '}'\ '}'\ '}' ) end @@ -571,19 +537,10 @@ ) expect(actual.dns.mail_cname.host).to eq('mail.example.com') expect(actual.dns.mail_cname.type).to eq('cname') expect(actual.dns.mail_cname.data).to eq('u7.wl.sendgrid.net') expect(actual.dns.mail_cname.valid).to eq(true) - expect(actual.dns.spf).to be_a( - SendGrid4r::REST::Whitelabel::Domains::Record - ) - expect(actual.dns.spf.host).to eq('example.com') - expect(actual.dns.spf.type).to eq('txt') - expect(actual.dns.spf.data).to eq( - 'v=spf1 include:u7.wl.sendgrid.net -all' - ) - expect(actual.dns.spf.valid).to eq(true) expect(actual.dns.dkim1).to be_a( SendGrid4r::REST::Whitelabel::Domains::Record ) expect(actual.dns.dkim1.host).to eq('s1._domainkey.example.com') expect(actual.dns.dkim1.type).to eq('cname') @@ -627,19 +584,10 @@ expect(actual.dns.subdomain_spf.type).to eq('txt') expect(actual.dns.subdomain_spf.data).to eq( 'v=spf1 include:sendgrid.net ~all' ) expect(actual.dns.subdomain_spf.valid).to eq(false) - expect(actual.dns.domain_spf).to be_a( - SendGrid4r::REST::Whitelabel::Domains::Record - ) - expect(actual.dns.domain_spf.host).to eq('example.com') - expect(actual.dns.domain_spf.type).to eq('txt') - expect(actual.dns.domain_spf.data).to eq( - 'v=spf1 include:mail2.example.com -all' - ) - expect(actual.dns.domain_spf.valid).to eq(false) expect(actual.dns.dkim).to be_a( SendGrid4r::REST::Whitelabel::Domains::Record ) expect(actual.dns.dkim.host).to eq('m1._domainkey.example.com') expect(actual.dns.dkim.type).to eq('txt') @@ -665,13 +613,8 @@ expect(actual.validation_results.dkim2).to be_a( SendGrid4r::REST::Whitelabel::Domains::ValidationResult ) expect(actual.validation_results.dkim2.valid).to be(true) expect(actual.validation_results.dkim2.reason).to be(nil) - expect(actual.validation_results.spf).to be_a( - SendGrid4r::REST::Whitelabel::Domains::ValidationResult - ) - expect(actual.validation_results.spf.valid).to be(true) - expect(actual.validation_results.spf.reason).to be(nil) end end end