Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-15-SP1:Update
salt.20523
support-for-btrfs-and-xfs-in-parted-and-mkfs.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File support-for-btrfs-and-xfs-in-parted-and-mkfs.patch of Package salt.20523
From be69780e4cb3047e8024fb87fdf2e15f049db154 Mon Sep 17 00:00:00 2001 From: Jochen Breuer <jbreuer@suse.de> Date: Fri, 10 Jan 2020 17:18:14 +0100 Subject: [PATCH] Support for Btrfs and XFS in parted and mkfs --- salt/modules/parted_partition.py | 8 ++------ tests/unit/modules/test_parted_partition.py | 5 ----- 2 files changed, 2 insertions(+), 11 deletions(-) diff --git a/salt/modules/parted_partition.py b/salt/modules/parted_partition.py index 9f321a822c..015d4cbc29 100644 --- a/salt/modules/parted_partition.py +++ b/salt/modules/parted_partition.py @@ -16,14 +16,11 @@ reference the man page for ``sfdisk(8)``. """ import logging - -# Import python libs import os import re import stat import string -# Import Salt libs import salt.utils.path import salt.utils.platform from salt.exceptions import CommandExecutionError @@ -412,12 +409,11 @@ def _is_fstype(fs_type): :param fs_type: file system type :return: True if fs_type is supported in this module, False otherwise """ - return fs_type in ( + return fs_type in { "btrfs", "ext2", "ext3", "ext4", - "fat", "fat32", "fat16", "linux-swap", @@ -429,7 +425,7 @@ def _is_fstype(fs_type): "ntfs", "ufs", "xfs", - ) + } def mkfs(device, fs_type): diff --git a/tests/unit/modules/test_parted_partition.py b/tests/unit/modules/test_parted_partition.py index 3fff6acee8..073d29ba38 100644 --- a/tests/unit/modules/test_parted_partition.py +++ b/tests/unit/modules/test_parted_partition.py @@ -6,14 +6,9 @@ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ """ -# Import Python libs import salt.modules.parted_partition as parted - -# Import Salt libs from salt.exceptions import CommandExecutionError - -# Import Salt Testing libs from tests.support.mixins import LoaderModuleMockMixin from tests.support.mock import MagicMock, patch from tests.support.unit import TestCase -- 2.29.2
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor