|
|
@@ -111,6 +111,11 @@ class TestBlockingServer(object): |
|
|
|
self.db.close() |
|
|
|
|
|
|
|
def test_blocking_server(self): |
|
|
|
# Server should fail if the database doesn't have a "_thread_safe" |
|
|
|
# property. |
|
|
|
with assert_raises(KeyError): |
|
|
|
nilmdb.Server(object()) |
|
|
|
|
|
|
|
# Start web app on a custom port |
|
|
|
self.server = nilmdb.Server(self.db, host = "127.0.0.1", |
|
|
|
port = 12380, stoppable = True) |
|
|
|