cleanup: doh.powerdns.org is not working anymore (#924)
While there, `.../internal/sessionresolver` => `.../sessionresolver` See https://github.com/ooni/probe/issues/2255
This commit is contained in:
		
							parent
							
								
									ec73ae20b4
								
							
						
					
					
						commit
						1153850aca
					
				| @ -24,7 +24,7 @@ import ( | ||||
| // create the underlying Dialer and/or HTTP transport, if needed. The URL | ||||
| // argument describes the kind of client that we want to make: | ||||
| // | ||||
| // - if the URL is `doh://powerdns`, `doh://google` or `doh://cloudflare` or the URL | ||||
| // - if the URL is `doh://google` or `doh://cloudflare` or the URL | ||||
| // starts with `https://`, then we create a DoH client. | ||||
| // | ||||
| // - if the URL is `` or `system:///`, then we create a system client, | ||||
| @ -49,8 +49,6 @@ func NewDNSClientWithOverrides(config Config, URL, hostOverride, SNIOverride, | ||||
| 	// We should split this function in smaller and testable units | ||||
| 	// TODO(https://github.com/ooni/probe/issues/2121#issuecomment-1147424810) | ||||
| 	switch URL { | ||||
| 	case "doh://powerdns": | ||||
| 		URL = "https://doh.powerdns.org/" | ||||
| 	case "doh://google": | ||||
| 		URL = "https://dns.google/dns-query" | ||||
| 	case "doh://cloudflare": | ||||
|  | ||||
| @ -29,22 +29,6 @@ func TestNewDNSClientUnsupportedScheme(t *testing.T) { | ||||
| 	} | ||||
| } | ||||
| 
 | ||||
| func TestNewDNSClientPowerdnsDoH(t *testing.T) { | ||||
| 	dnsclient, err := NewDNSClient( | ||||
| 		Config{}, "doh://powerdns") | ||||
| 	if err != nil { | ||||
| 		t.Fatal(err) | ||||
| 	} | ||||
| 	r, ok := dnsclient.(*netxlite.SerialResolver) | ||||
| 	if !ok { | ||||
| 		t.Fatal("not the resolver we expected") | ||||
| 	} | ||||
| 	if _, ok := r.Transport().(*netxlite.DNSOverHTTPSTransport); !ok { | ||||
| 		t.Fatal("not the transport we expected") | ||||
| 	} | ||||
| 	dnsclient.CloseIdleConnections() | ||||
| } | ||||
| 
 | ||||
| func TestNewDNSClientGoogleDoH(t *testing.T) { | ||||
| 	dnsclient, err := NewDNSClient( | ||||
| 		Config{}, "doh://google") | ||||
|  | ||||
| @ -13,8 +13,8 @@ import ( | ||||
| 	"github.com/ooni/probe-cli/v3/internal/atomicx" | ||||
| 	"github.com/ooni/probe-cli/v3/internal/bytecounter" | ||||
| 	"github.com/ooni/probe-cli/v3/internal/engine/geolocate" | ||||
| 	"github.com/ooni/probe-cli/v3/internal/engine/internal/sessionresolver" | ||||
| 	"github.com/ooni/probe-cli/v3/internal/engine/probeservices" | ||||
| 	"github.com/ooni/probe-cli/v3/internal/engine/sessionresolver" | ||||
| 	"github.com/ooni/probe-cli/v3/internal/kvstore" | ||||
| 	"github.com/ooni/probe-cli/v3/internal/model" | ||||
| 	"github.com/ooni/probe-cli/v3/internal/netxlite" | ||||
|  | ||||
| @ -4,7 +4,7 @@ import ( | ||||
| 	"context" | ||||
| 	"testing" | ||||
| 
 | ||||
| 	"github.com/ooni/probe-cli/v3/internal/engine/internal/sessionresolver" | ||||
| 	"github.com/ooni/probe-cli/v3/internal/engine/sessionresolver" | ||||
| 	"github.com/ooni/probe-cli/v3/internal/kvstore" | ||||
| ) | ||||
| 
 | ||||
| @ -35,8 +35,6 @@ var allmakers = []*resolvermaker{{ | ||||
| 	url: "http3://dns.google/dns-query", | ||||
| }, { | ||||
| 	url: "https://dns.quad9.net/dns-query", | ||||
| }, { | ||||
| 	url: "https://doh.powerdns.org/", | ||||
| }, { | ||||
| 	url: systemResolverURL, | ||||
| }, { | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user