Skip to content

Commit f8f7e48

Browse files
committedMay 23, 2024
Update toml-test
1 parent 9a80667 commit f8f7e48

File tree

6 files changed

+33
-0
lines changed

6 files changed

+33
-0
lines changed
 
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# Hour must be 00-24
2+
d = 1985-06-18 17:04:07+25:00
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Minute must be 00-59; we allow 60 too because some people do write offsets of
2+
# 60 minutes
3+
d = 1985-06-18 17:04:07+12:61
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,4 @@
11
space = 1987-07-05 17:45:00Z
2+
3+
# ABNF is case-insensitive, both "Z" and "z" must be supported.
24
lower = 1987-07-05t17:45:00z
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{
2+
"s1": {"type": "string", "value": "§"},
3+
"s2": {"type": "string", "value": "§"},
4+
"s3": {"type": "string", "value": "§"},
5+
"s4": {"type": "string", "value": "§"},
6+
"s5": {"type": "string", "value": "§"},
7+
"s6": {"type": "string", "value": "§"},
8+
"s7": {"type": "string", "value": "§"}
9+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# Start first line with a multibyte character.
2+
#
3+
# https://github.com/marzer/tomlplusplus/issues/190
4+
s1 = "§"
5+
s2 = '§'
6+
s3 = """\
7+
§"""
8+
s4 = """
9+
§"""
10+
s5 = """§"""
11+
s6 = '''
12+
§'''
13+
s7 = '''§'''

‎toml_test.go

+4
Original file line numberDiff line numberDiff line change
@@ -313,6 +313,10 @@ func runTomlTest(t *testing.T, includeNext bool, wantFail ...string) {
313313
Parser: parser{},
314314
RunTests: runTests,
315315
SkipTests: []string{
316+
// Will be fixed in Go 1.23: https://github.com/BurntSushi/toml/issues/407
317+
"invalid/datetime/offset-overflow-hour",
318+
"invalid/datetime/offset-overflow-minute",
319+
316320
// These tests are fine, just doesn't deal well with empty output.
317321
"valid/comment/noeol",
318322
"valid/comment/nonascii",

0 commit comments

Comments
 (0)