test_filesystemgroup.py 文件源码

python
阅读 19 收藏 0 点赞 0 评论 0

项目:maas 作者: maas 项目源码 文件源码
def test_create_raid_0_with_one_element_fails(self):
        node = factory.make_Node()
        block_device = factory.make_PhysicalBlockDevice(node=node)
        uuid = str(uuid4())
        with ExpectedException(
                ValidationError,
                re.escape(
                    "{'__all__': ['RAID level 0 must have at least 2 raid "
                    "devices and no spares.']}")):
            RAID.objects.create_raid(
                name='md0',
                level=FILESYSTEM_GROUP_TYPE.RAID_0,
                uuid=uuid,
                block_devices=[block_device],
                partitions=[],
                spare_devices=[],
                spare_partitions=[])
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号