From: Alfredo Deza Date: Tue, 18 Sep 2018 18:07:06 +0000 (-0400) Subject: ceph-volume tests.lvm verify that it is reported when --journal is not used with... X-Git-Tag: v14.0.1~219^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=ae657d2fe012b0e78959ead9d8d3baa1095a31ff;p=ceph-ci.git ceph-volume tests.lvm verify that it is reported when --journal is not used with --filestore Signed-off-by: Alfredo Deza --- diff --git a/src/ceph-volume/ceph_volume/tests/devices/lvm/test_prepare.py b/src/ceph-volume/ceph_volume/tests/devices/lvm/test_prepare.py index bc2486cf694..ab0115e959b 100644 --- a/src/ceph-volume/ceph_volume/tests/devices/lvm/test_prepare.py +++ b/src/ceph-volume/ceph_volume/tests/devices/lvm/test_prepare.py @@ -74,6 +74,13 @@ class TestPrepare(object): expected = 'Cannot use --block.db (bluestore) with --journal (filestore)' assert expected in stdout + def test_journal_is_required_with_filestore(self, is_root, monkeypatch): + monkeypatch.setattr('os.path.exists', lambda x: True) + with pytest.raises(SystemExit) as error: + lvm.prepare.Prepare(argv=['--filestore', '--data', '/dev/sdfoo']).main() + expected = '--journal is required when using --filestore' + assert expected in str(error) + class TestGetJournalLV(object):