lib/protoparser/influx: make sure that escaped whitespace can be put in measurement, tag names and field names

This commit is contained in:
Aliaksandr Valialkin 2021-02-16 13:58:19 +02:00
parent d788876a7a
commit 7869d38043

View File

@ -344,15 +344,15 @@ func TestRowsUnmarshalSuccess(t *testing.T) {
})
// Escape chars
f(`fo\,bar\=baz,x\=\b=\\a\,\=\q\ \\\a\=\,=4.34`, &Rows{
f(`fo\,bar\=b\ az,x\=\ b=\\a\,\=\q\ \\\a\ b\=\,=4.34`, &Rows{
Rows: []Row{{
Measurement: `fo,bar=baz`,
Measurement: `fo,bar=b az`,
Tags: []Tag{{
Key: `x=\b`,
Key: `x= b`,
Value: `\a,=\q `,
}},
Fields: []Field{{
Key: `\\a=,`,
Key: `\\a b=,`,
Value: 4.34,
}},
}},