We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c101386 commit 64d03beCopy full SHA for 64d03be
influxdb/tests/test_line_protocol.py
@@ -1,4 +1,5 @@
1
# -*- coding: utf-8 -*-
2
+from __future__ import unicode_literals
3
4
import sys
5
if sys.version_info < (2, 7):
@@ -55,3 +56,23 @@ def test_string_val_newline(self):
55
56
line_protocol.make_lines(data),
57
'm1 multi_line="line1\\nline1\\nline3"\n'
58
)
59
+
60
+ def test_make_lines_unicode(self):
61
+ data = {
62
+ "tags": {
63
+ "unicode_tag": "\'Привет!\'" # Hello! in Russian
64
+ },
65
+ "points": [
66
+ {
67
+ "measurement": "test",
68
+ "fields": {
69
+ "unicode_val": "Привет!", # Hello! in Russian
70
+ }
71
72
+ ]
73
74
75
+ self.assertEqual(
76
+ line_protocol.make_lines(data),
77
+ 'test,unicode_tag=\'Привет!\' unicode_val="Привет!"\n'
78
+ )
0 commit comments