1.1 --- a/tests/test_handle.py Tue Feb 09 15:01:40 2016 +0100
1.2 +++ b/tests/test_handle.py Tue Feb 09 15:17:50 2016 +0100
1.3 @@ -3,7 +3,7 @@
1.4 """
1.5 A handler to help with testing.
1.6
1.7 -Copyright (C) 2014, 2015 Paul Boddie <paul@boddie.org.uk>
1.8 +Copyright (C) 2014, 2015, 2016 Paul Boddie <paul@boddie.org.uk>
1.9
1.10 This program is free software; you can redistribute it and/or modify it under
1.11 the terms of the GNU General Public License as published by the Free Software
1.12 @@ -94,13 +94,13 @@
1.13
1.14 if __name__ == "__main__":
1.15 try:
1.16 - action, store_dir, preferences_dir, user = sys.argv[1:5]
1.17 + action, store_dir, journal_dir, preferences_dir, user = sys.argv[1:6]
1.18 if action == "counter":
1.19 - start, end = sys.argv[5:7]
1.20 - i = 7
1.21 + start, end = sys.argv[6:8]
1.22 + i = 8
1.23 else:
1.24 start, end = None, None
1.25 - i = 5
1.26 + i = 6
1.27 uid, recurrenceid = (sys.argv[i:i+2] + [None] * 2)[:2]
1.28 except ValueError:
1.29 print >>sys.stderr, """\
1.30 @@ -121,6 +121,7 @@
1.31 sys.exit(1)
1.32
1.33 store = imip_store.FileStore(store_dir)
1.34 + journal = imip_store.FileJournal(journal_dir)
1.35
1.36 if uid is not None:
1.37 fragment = store.get_event(user, uid, recurrenceid)
1.38 @@ -132,7 +133,7 @@
1.39 fragment = parse_object(sys.stdin, "utf-8")
1.40
1.41 obj = Object(fragment)
1.42 - handler = TestClient(obj, user, Messenger(), store, None, preferences_dir)
1.43 + handler = TestClient(obj, user, Messenger(), store, None, journal, preferences_dir)
1.44 response = handler.handle_request(action, start, end)
1.45
1.46 if response: