8000 add: ssl test · mattrobenolt/influxdb-python@0511387 · GitHub
[go: up one dir, main page]

Skip to content 8000

Commit 0511387

Browse files
committed
add: ssl test
1 parent dbbb41a commit 0511387

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

tests/influxdb/client_test.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,14 @@ def check_method(*args, **kwargs):
3636

3737

3838
class TestInfluxDBClient(object):
39+
40+
def test_scheme(self):
41+
cli = InfluxDBClient('host', 8086, 'username', 'password', 'database')
42+
assert cli._baseurl == 'http://host:8086'
43+
44+
cli = InfluxDBClient('host', 8086, 'username', 'password', 'database', ssl=True)
45+
assert cli._baseurl == 'https://host:8086'
46+
3947
def test_switch_db(self):
4048
cli = InfluxDBClient('host', 8086, 'username', 'password', 'database')
4149
cli.switch_db('another_database')

0 commit comments

Comments
 (0)
0