def test_nonempty_subdir_to_empty(self):
        source_subdir = os.path.join(self.source_dir, 'mysubdir')

        subdir = os.path.join(self.source_dir, 'mysubdir')
        os.mkdir(subdir)
        tt.touch(os.path.join(subdir, 'foo.csv'))

        self.cmd = """%(pgm)s %(source_dir)s       \
                              %(dest_dir)s         \
                         --match-on-name-only      \
                         --log-level debug         \
                         -r                        \
                   """ % {'pgm': PGM,
                          'source_dir': self.source_dir,
                          'dest_dir':   self.dest_dir}
        print '\n command: %s' % self.cmd

        r = envoy.run(self.cmd)
        self.get_outputs(r)

        print 'dest_dir: %s' % self.dest_dir
        print os.listdir(self.dest_dir)
        print 'dest sub dir: %s' % os.path.join(self.dest_dir, 'mysubdir')
        print 'dest sub contents: '
        #print os.listdir(os.path.join(self.dest_dir, 'mysubdir'))
        print 'is a file? %s' % os.path.isfile(os.path.join(self.dest_dir, 'mysubdir'))

        assert r.status_code      == 0
        assert 'mysubdir' in os.listdir(self.dest_dir)
        assert not os.path.exists(self.source_dir)
        assert 'foo.csv'  in os.listdir(os.path.join(self.dest_dir, 'mysubdir'))
Get the current assigned prefix for this PDDriver from the PD agent.
dataset/ETHPy150Open kenfar/DataGristle/scripts/tests/test_gristle_dir_merger_cmd.py/TestEmpties.test_nonempty_subdir_to_empty--crossover with--dataset/ETHPy150Open openstack/neutron/neutron/agent/linux/pd_driver.py/PDDriverBase.get_prefix