1
0
mirror of https://github.com/StackExchange/dnscontrol.git synced 2024-05-11 05:55:12 +00:00

Rename provider handles to *Provider (#914)

This commit is contained in:
Tom Limoncelli
2020-10-26 09:25:30 -04:00
committed by GitHub
parent 29c7ff3a05
commit ca30c9c34f
43 changed files with 318 additions and 318 deletions

View File

@@ -27,7 +27,7 @@ func makeRCmeta(meta map[string]string) *models.RecordConfig {
}
func TestPreprocess_BoolValidation(t *testing.T) {
cf := &cloudflareAPI{}
cf := &cloudflareProvider{}
domain := newDomainConfig()
domain.Records = append(domain.Records, makeRCmeta(map[string]string{metaProxy: "on"}))
@@ -49,7 +49,7 @@ func TestPreprocess_BoolValidation(t *testing.T) {
}
func TestPreprocess_BoolValidation_Fails(t *testing.T) {
cf := &cloudflareAPI{}
cf := &cloudflareProvider{}
domain := newDomainConfig()
domain.Records = append(domain.Records, &models.RecordConfig{Metadata: map[string]string{metaProxy: "true"}})
err := cf.preprocessConfig(domain)
@@ -59,7 +59,7 @@ func TestPreprocess_BoolValidation_Fails(t *testing.T) {
}
func TestPreprocess_DefaultProxy(t *testing.T) {
cf := &cloudflareAPI{}
cf := &cloudflareProvider{}
domain := newDomainConfig()
domain.Metadata[metaProxyDefault] = "full"
domain.Records = append(domain.Records, makeRCmeta(map[string]string{metaProxy: "on"}))
@@ -78,7 +78,7 @@ func TestPreprocess_DefaultProxy(t *testing.T) {
}
func TestPreprocess_DefaultProxy_Validation(t *testing.T) {
cf := &cloudflareAPI{}
cf := &cloudflareProvider{}
domain := newDomainConfig()
domain.Metadata[metaProxyDefault] = "true"
err := cf.preprocessConfig(domain)
@@ -100,7 +100,7 @@ func TestIpRewriting(t *testing.T) {
// inside range and proxied
{"1.2.3.4", "255.255.255.4", "full"},
}
cf := &cloudflareAPI{}
cf := &cloudflareProvider{}
domain := newDomainConfig()
cf.ipConversions = []transform.IPConversion{{
Low: net.ParseIP("1.2.3.0"),