Skip to content

Commit

Permalink
Add ssl config test
Browse files Browse the repository at this point in the history
  • Loading branch information
cknv committed Aug 27, 2019
1 parent 388ca42 commit e5125bf
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions tests/test_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,3 +65,11 @@ def test_socket_bind():
config.load()

assert isinstance(config.bind_socket(), socket.socket)


def test_ssl_config(certfile_and_keyfile):
certfile, keyfile = certfile_and_keyfile
config = Config(app=asgi_app, ssl_certfile=certfile.name, ssl_keyfile=keyfile.name)
config.load()

assert bool(config.is_ssl) is True

0 comments on commit e5125bf

Please sign in to comment.