예제 #1
0
    def tearDown(self):
        if self.s3ffs:
            self.s3ffs.stop()
        MS3Server.stop()

        shutil.rmtree(self.local, True)
        shutil.rmtree(self.remote, True)
예제 #2
0
파일: test_setup.py 프로젝트: Nimain/riofs
    def tearDown(self):
        if self.s3ffs:
            self.s3ffs.stop()
        MS3Server.stop()

        shutil.rmtree(self.local, True)
        shutil.rmtree(self.remote, True)
예제 #3
0
 def setUp(self):
     self.datadir = get_data_dir('buckets')
     MS3Server.start(datadir=self.datadir)
     self.s3 = S3Connection('X',
                            'Y',
                            is_secure=False,
                            host='localhost',
                            port=9010,
                            calling_format=OrdinaryCallingFormat())
예제 #4
0
    def tearDown(self):
        if self.s1:
            self.s1.stop()
        if self.s2:
            self.s2.stop()
        MS3Server.stop()

        shutil.rmtree(self.l1, True)
        shutil.rmtree(self.l2, True)
        shutil.rmtree(self.remote, True)
예제 #5
0
파일: test_setup.py 프로젝트: Nimain/riofs
    def setUp(self):
        self.local = tempfile.mkdtemp()
        self.remote = tempfile.mkdtemp()
        self.bucket = "test"
        os.mkdir(os.path.join(self.remote, self.bucket))
        self.s3ffs = None

        # In case there occurs an exception during setUp(), unittest
        # doesn't call tearDown(), hence we need to make sure we don't
        # leave any server processes running.
        try:
            MS3Server.start(datadir=self.remote)
            self.s3ffs = s3ffsServer(self.bucket, mountpoint=self.local).start()
        except Exception:
            self.tearDown()
            raise
예제 #6
0
    def setUp(self):
        self.local = tempfile.mkdtemp()
        self.remote = tempfile.mkdtemp()
        self.bucket = "test"
        os.mkdir(os.path.join(self.remote, self.bucket))
        self.s3ffs = None

        # In case there occurs an exception during setUp(), unittest
        # doesn't call tearDown(), hence we need to make sure we don't
        # leave any server processes running.
        try:
            MS3Server.start(datadir=self.remote)
            self.s3ffs = s3ffsServer(self.bucket,
                                     mountpoint=self.local).start()
        except Exception:
            self.tearDown()
            raise
예제 #7
0
 def tearDown(self):
     self.s3.close()
     MS3Server.stop()
     cleanup(self.datadir)
예제 #8
0
 def tearDown(self):
     self.s3.close()
     MS3Server.stop()
     cleanup(self.datadir)
예제 #9
0
 def setUp(self):
     self.datadir = get_data_dir('buckets')
     MS3Server.start(datadir=self.datadir)
     self.s3 = S3Connection('X', 'Y', is_secure=False,
                            host='localhost', port=9010,
                            calling_format=OrdinaryCallingFormat())