def setUp(self):
        super(BrickLvmTestCase, self).setUp()
        self.volume_group_name = 'fake-vg'

        # Stub processutils.execute for static methods
        self.mock_object(priv_rootwrap, 'execute', self.fake_execute)
        self.vg = brick.LVM(self.volume_group_name,
                            'sudo',
                            create_vg=False,
                            physical_volumes=None,
                            lvm_type='default',
                            executor=self.fake_execute)
Exemple #2
0
    def setUp(self):
        super(BrickLvmTestCase, self).setUp()
        if not hasattr(self, 'configuration'):
            self.configuration = mock.Mock()
            self.configuration.lvm_suppress_fd_warnings = False
        self.volume_group_name = 'fake-vg'

        # Stub processutils.execute for static methods
        self.mock_object(priv_rootwrap, 'execute', self.fake_execute)
        self.vg = brick.LVM(
            self.volume_group_name,
            'sudo',
            create_vg=False,
            physical_volumes=None,
            lvm_type='default',
            executor=self.fake_execute,
            suppress_fd_warn=self.configuration.lvm_suppress_fd_warnings)