summaryrefslogtreecommitdiff
path: root/test/t/test_slapt_get.py
blob: 626dde9e1998ff6465bb55378964aa9de3f4e46d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
import pytest


@pytest.mark.bashcomp(cmd="slapt-get")
class TestSlaptGet:
    @pytest.mark.complete("slapt-get -", require_cmd=True)
    def test_1(self, completion):
        assert completion

    @pytest.mark.complete("slapt-get --up", require_cmd=True)
    def test_2(self, completion):
        assert completion == "--update --upgrade".split()

    @pytest.mark.complete("slapt-get -c non-existent-file --install ")
    def test_3(self, completion):
        assert not completion