~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/blackbox/test_export.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2011-06-15 13:00:55 UTC
  • mfrom: (5973.1.1 integration)
  • Revision ID: pqm@pqm.ubuntu.com-20110615130055-anv7vid86fsmrj17
Bug #795557,
        allow exporting a subdir when also exporting the timestamps.
        (Szilveszter Farkas)

Show diffs side-by-side

added added

removed removed

Lines of Context:
387
387
        har_st = os.stat('t/har')
388
388
        self.assertEquals(315532800, har_st.st_mtime)
389
389
 
 
390
    def test_dir_export_partial_tree_per_file_timestamps(self):
 
391
        tree = self.example_branch()
 
392
        self.build_tree(['branch/subdir/', 'branch/subdir/foo.txt'])
 
393
        tree.smart_add(['branch'])
 
394
        # Earliest allowable date on FAT32 filesystems is 1980-01-01
 
395
        tree.commit('setup', timestamp=315532800)
 
396
        self.run_bzr('export --per-file-timestamps tpart branch/subdir')
 
397
        foo_st = os.stat('tpart/foo.txt')
 
398
        self.assertEquals(315532800, foo_st.st_mtime)
 
399
 
390
400
    def test_export_directory(self):
391
401
        """Test --directory option"""
392
402
        self.example_branch()