diff options
Diffstat (limited to 'test/test_app.py')
-rw-r--r-- | test/test_app.py | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/test/test_app.py b/test/test_app.py index e0060e82..721b36d7 100644 --- a/test/test_app.py +++ b/test/test_app.py @@ -14,6 +14,18 @@ class uApplication(libpry.AutoTree): a.remove_anchor("/oink", "400") assert a.get_anchors() == [("/foo", "200")] + def test_logs(self): + a = app.PathodApp(staticdir=None) + a.LOGBUF = 3 + a.add_log({}) + assert a.log[0]["id"] == 0 + a.add_log({}) + a.add_log({}) + assert a.log[0]["id"] == 2 + a.add_log({}) + assert len(a.log) == 3 + assert a.log[0]["id"] == 3 + assert a.log[-1]["id"] == 1 class uPages(libpry.AutoTree): def dummy_page(self, path): |