author | Nigel Tao
<nigeltao@golang.org> 2016-04-07 01:57:48 UTC |
committer | Nigel Tao
<nigeltao@golang.org> 2016-04-07 02:09:14 UTC |
parent | af4fee9d05b66edc24197d189e6118f8ebce8c2b |
webdav/webdav.go | +0 | -21 |
webdav/xml_test.go | +0 | -4 |
diff --git a/webdav/webdav.go b/webdav/webdav.go index df6ef45..65952d7 100644 --- a/webdav/webdav.go +++ b/webdav/webdav.go @@ -9,35 +9,14 @@ import ( "errors" "fmt" "io" - "log" "net/http" "net/url" "os" "path" - "runtime" "strings" "time" ) -// Package webdav's XML output requires the standard library's encoding/xml -// package version 1.5 or greater. Otherwise, it will produce malformed XML. -// -// As of May 2015, the Go stable release is version 1.4, so we print a message -// to let users know that this golang.org/x/etc package won't work yet. -// -// This package also won't work with Go 1.3 and earlier, but making this -// runtime version check catch all the earlier versions too, and not just -// "1.4.x", isn't worth the complexity. -// -// TODO: delete this check at some point after Go 1.5 is released. -var go1Dot4 = strings.HasPrefix(runtime.Version(), "go1.4.") - -func init() { - if go1Dot4 { - log.Println("package webdav requires Go version 1.5 or greater") - } -} - type Handler struct { // Prefix is the URL path prefix to strip from WebDAV resource paths. Prefix string diff --git a/webdav/xml_test.go b/webdav/xml_test.go index bc5641f..f38504e 100644 --- a/webdav/xml_test.go +++ b/webdav/xml_test.go @@ -348,10 +348,6 @@ func TestReadPropfind(t *testing.T) { } func TestMultistatusWriter(t *testing.T) { - if go1Dot4 { - t.Skip("TestMultistatusWriter requires Go version 1.5 or greater") - } - ///The "section x.y.z" test cases come from section x.y.z of the spec at // http://www.webdav.org/specs/rfc4918.html testCases := []struct {