conduit r1806 - in trunk: . conduit/platform test/python-tests



Author: jstowers
Date: Mon Jan 19 12:47:09 2009
New Revision: 1806
URL: http://svn.gnome.org/viewvc/conduit?rev=1806&view=rev

Log:
2009-01-20  John Stowers  <john stowers gmail com>

	* conduit/platform/FileGio.py: Remove old bug link
	* test/python-tests/TestCoreTempFile.py: Add force_new_filename test



Modified:
   trunk/ChangeLog
   trunk/conduit/platform/FileGio.py
   trunk/test/python-tests/TestCoreTempFile.py

Modified: trunk/conduit/platform/FileGio.py
==============================================================================
--- trunk/conduit/platform/FileGio.py	(original)
+++ trunk/conduit/platform/FileGio.py	Mon Jan 19 12:47:09 2009
@@ -262,7 +262,6 @@
             d.make_directory_and_parents()
 
         #Copy the file
-        #http://bugzilla.gnome.org/show_bug.cgi?id=546601
         try:        
             ok = self._source.copy(
                         destination=self._dest,

Modified: trunk/test/python-tests/TestCoreTempFile.py
==============================================================================
--- trunk/test/python-tests/TestCoreTempFile.py	(original)
+++ trunk/test/python-tests/TestCoreTempFile.py	Mon Jan 19 12:47:09 2009
@@ -12,7 +12,7 @@
 ok("Created tempdir %s" % tmpdir, True)
 
 contents = Utils.random_string()
-name = Utils.random_string()
+name = Utils.random_string()+".foo"
 tmpFile = File.TempFile(contents)
 
 tmpFile.force_new_filename(name)
@@ -26,6 +26,9 @@
 ok("File contents = %s" % contents, f.get_contents_as_text() == contents)
 mtime = f.get_mtime()
 
+f = File.File(newPath)
+ok("File name ok", f.get_filename() == name)
+
 #make some 'real' files to play with
 testDir = os.path.join(os.environ['TEST_DIRECTORY'],"TempFile")
 if not os.path.exists(testDir):



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]