Mercurial > libervia-pubsub
changeset 138:635e433810ef
Actually test whether the item was indeed stored.
author | Ralph Meijer <ralphm@ik.nu> |
---|---|
date | Mon, 25 Apr 2005 13:02:37 +0000 |
parents | aca904a41a43 |
children | 8f6956b9a688 |
files | idavoll/test/test_storage.py |
diffstat | 1 files changed, 10 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/idavoll/test/test_storage.py Mon Apr 25 12:58:59 2005 +0000 +++ b/idavoll/test/test_storage.py Mon Apr 25 13:02:37 2005 +0000 @@ -221,7 +221,16 @@ return d def testStoreItems(self): - return self.node.store_items([ITEM_NEW], PUBLISHER) + def cb1(void): + return self.node.get_items_by_id(['new']) + + def cb2(result): + assertEqual(result[0], unicode(ITEM_NEW.toXml(), 'utf-8')) + + d = self.node.store_items([ITEM_NEW], PUBLISHER) + d.addCallback(cb1) + d.addCallback(cb2) + return d def testStoreUpdatedItems(self): def cb1(void):