Skip to content

Commit 4585a13

Browse files
author
Ivan Kovalkovskyi
committed
Add tests for _escape_tag_value func
1 parent 051da0c commit 4585a13

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

influxdb/tests/test_line_protocol.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ def test_make_lines(self):
2222
"tags": {
2323
"empty_tag": "",
2424
"none_tag": None,
25+
"backslash_tag": "C:\\",
2526
"integer_tag": 2,
2627
"string_tag": "hello"
2728
},
@@ -39,9 +40,10 @@ def test_make_lines(self):
3940
]
4041
}
4142

43+
print(line_protocol.make_lines(data))
4244
self.assertEqual(
4345
line_protocol.make_lines(data),
44-
'test,integer_tag=2,string_tag=hello '
46+
'test,backslash_tag=C:\\\\ ,integer_tag=2,string_tag=hello '
4547
'bool_val=True,float_val=1.1,int_val=1i,string_val="hello!"\n'
4648
)
4749

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy