Commits

Stefan Schwarzer committed 73ad91d

Updated year numbers in copyright notices according to changes
in the corresponding `svn log <file>` commands.

  • Participants
  • Parent commits 6b3dd85

Comments (0)

Files changed (9)

File _test_base.py

-# Copyright (C) 2003, Stefan Schwarzer
+# Copyright (C) 2003-2004, Stefan Schwarzer
 # All rights reserved.
 #
 # Redistribution and use in source and binary forms, with or without

File _test_ftp_path.py

-# Copyright (C) 2003-2004, Stefan Schwarzer
+# Copyright (C) 2003-2007, Stefan Schwarzer
 # All rights reserved.
 #
 # Redistribution and use in source and binary forms, with or without

File _test_ftputil.py

-# Copyright (C) 2002-2006, Stefan Schwarzer
+# Copyright (C) 2002-2008, Stefan Schwarzer
 # All rights reserved.
 #
 # Redistribution and use in source and binary forms, with or without

File _test_real_ftp.py

 #  and client use the same timezone
 EXPECTED_TIME_SHIFT = utc_local_time_shift()
 
+# helper class for cleaning up directories and files made
+#  during a test
+class Cleaner(object):
+    def __init__(self, host):
+        # the test class (probably `RealFTPTest`) and the helper
+        #  class share the same `FTPHost` object
+        self._host = host
+        self._ftp_items = []
+
+    def mkdir(self, directory):
+        self._host.mkdir(directory)
+        self._ftp_items.append(('d', self._host.path.abspath(directory)))
+
+    def open(self, path, mode="r"):
+        # "r" is the default mode of `FTPHost.file`
+        f = self._host.open(path, mode)
+        self._ftp_items.append(('f', self._host.path.abspath(path)))
 
 class RealFTPTest(unittest.TestCase):
     def setUp(self):

File ftp_error.py

-# Copyright (C) 2003-2006, Stefan Schwarzer <sschwarzer@sschwarzer.net>
+# Copyright (C) 2003-2007, Stefan Schwarzer <sschwarzer@sschwarzer.net>
 # All rights reserved.
 #
 # Redistribution and use in source and binary forms, with or without
-# Copyright (C) 2003-2006, Stefan Schwarzer <sschwarzer@sschwarzer.net>
+# Copyright (C) 2003-2008, Stefan Schwarzer <sschwarzer@sschwarzer.net>
 # All rights reserved.
 #
 # Redistribution and use in source and binary forms, with or without
-# Copyright (C) 2002-2006, Stefan Schwarzer
+# Copyright (C) 2002-2008, Stefan Schwarzer
 # All rights reserved.
 #
 # Redistribution and use in source and binary forms, with or without
-# Copyright (C) 2002-2007, Stefan Schwarzer <sschwarzer@sschwarzer.net>
+# Copyright (C) 2002-2008, Stefan Schwarzer <sschwarzer@sschwarzer.net>
 # All rights reserved.
 #
 # Redistribution and use in source and binary forms, with or without

File ftputil_version.py

-# Copyright (C) 2006, Stefan Schwarzer
+# Copyright (C) 2006-2008, Stefan Schwarzer
 # All rights reserved.
 #
 # Redistribution and use in source and binary forms, with or without