Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TestFormats failed on Go1.17 #337

Open
zhsj opened this issue Oct 23, 2021 · 1 comment · May be fixed by #339
Open

TestFormats failed on Go1.17 #337

zhsj opened this issue Oct 23, 2021 · 1 comment · May be fixed by #339

Comments

@zhsj
Copy link

zhsj commented Oct 23, 2021

$ go test -v -run TestFormats
=== RUN   TestFormats
/tmp/t/gojsonschema/testdata/draft4/optional/format.json
    validation of date-time strings
    validation of URIs
    validation of e-mail addresses
    validation of IP addresses
    validation of IPv6 addresses
    validation of host names
/tmp/t/gojsonschema/testdata/draft6/optional/format.json
    validation of date-time strings
    validation of URIs
    validation of URI References
    format: uri-template
    validation of e-mail addresses
    validation of IP addresses
    validation of IPv6 addresses
    validation of host names
    validation of JSON-pointers (JSON String Representation)
/tmp/t/gojsonschema/testdata/draft7/optional/format/date-time.json
    validation of date-time strings
/tmp/t/gojsonschema/testdata/draft7/optional/format/date.json
    validation of date strings
/tmp/t/gojsonschema/testdata/draft7/optional/format/email.json
    validation of e-mail addresses
/tmp/t/gojsonschema/testdata/draft7/optional/format/hostname.json
    validation of host names
/tmp/t/gojsonschema/testdata/draft7/optional/format/idn-email.json
    validation of an internationalized e-mail addresses
/tmp/t/gojsonschema/testdata/draft7/optional/format/idn-hostname.json
    validation of internationalized host names
/tmp/t/gojsonschema/testdata/draft7/optional/format/ipv4.json
    validation of IP addresses
/tmp/t/gojsonschema/testdata/draft7/optional/format/ipv6.json
    validation of IPv6 addresses
/tmp/t/gojsonschema/testdata/draft7/optional/format/iri-reference.json
    validation of IRI References
/tmp/t/gojsonschema/testdata/draft7/optional/format/iri.json
    validation of IRIs
/tmp/t/gojsonschema/testdata/draft7/optional/format/json-pointer.json
    validation of JSON-pointers (JSON String Representation)
/tmp/t/gojsonschema/testdata/draft7/optional/format/regex.json
    validation of regular expressions
/tmp/t/gojsonschema/testdata/draft7/optional/format/relative-json-pointer.json
    validation of Relative JSON Pointers (RJP)
/tmp/t/gojsonschema/testdata/draft7/optional/format/time.json
    validation of time strings
    jsonschema_test.go:102: Test failed : /tmp/t/gojsonschema/testdata/draft7/optional/format/time.json
        validation of time strings.
        only RFC3339 not all of ISO 8601 are valid.
        expects: false, given true
        Schema: {"format":"time"}
        Data: "01:01:01,1111"
/tmp/t/gojsonschema/testdata/draft7/optional/format/uri-reference.json
    validation of URI References
/tmp/t/gojsonschema/testdata/draft7/optional/format/uri-template.json
    format: uri-template
/tmp/t/gojsonschema/testdata/draft7/optional/format/uri.json
    validation of URIs
--- FAIL: TestFormats (0.02s)
FAIL
exit status 1
FAIL    github.com/xeipuuv/gojsonschema 0.022s
@zhsj zhsj linked a pull request Nov 10, 2021 that will close this issue
@zhsj
Copy link
Author

zhsj commented Nov 10, 2021

https://golang.org/doc/go1.17#time

The package now accepts comma "," as a separator for fractional seconds when parsing and formatting time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant