Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBenjamin Saller <bcsaller@objectrealms.net>2007-08-01 02:26:53 (GMT)
committer Benjamin Saller <bcsaller@objectrealms.net>2007-08-01 02:26:53 (GMT)
commit45391ed941b59c5e2fd0706c6ba05ecf06b7a0e8 (patch)
treec7105dc863e0fceb05f98211b8aada3d506a8ebd
parent5e2cd8f6f49601514de7b50c7e32ad8a0228b176 (diff)
added an additional test of update
-rw-r--r--tests/mountpoints.txt17
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/mountpoints.txt b/tests/mountpoints.txt
index dbbf033..695e7d2 100644
--- a/tests/mountpoints.txt
+++ b/tests/mountpoints.txt
@@ -172,6 +172,23 @@ The file was properly created in the expected place.
>>> assert os.path.exists('/tmp/store3/one.txt')
+Now let's update that file.
+
+>>> fn = ds.get_filename(u1)
+>>> fp = open(fn, 'w')
+>>> print >>fp, "This is new content"
+>>> fp.close()
+
+>>> ds.update(pen_copy, props, fn)
+>>> ds.complete_indexing()
+
+and verify it worked.
+
+>>> result, count = ds.find(dict(query="new content"))
+>>> assert count == 1
+>>> assert result[0]['uid'] == pen_copy
+
+
We also need to be sure that delete commands work on inplace
mounts. We will delete the object from the datastore and then verify