# Path: PyGitUp/utils.py
# def find(seq, test):
# def uniq(seq):
# def execute(cmd, cwd=None):
# def decode(s):


from PyGitUp import utils


def test_find():
    assert utils.find([1, 2, 3], lambda i: i == 3) == 3
    assert utils.find([1, 2, 3], lambda i: i == 4) is None


def test_uniq():
    assert utils.uniq([1, 1, 1, 2, 3]) == [1, 2, 3]

# Path: PyGitUp/utils.py
# def find(seq, test):
# def uniq(seq):
# def execute(cmd, cwd=None):
# def decode(s):


# Path: PyGitUp/tests/test_utils.py
from PyGitUp import utils



def test_find():
    assert utils.find([1, 2, 3], lambda i: i == 3) == 3
    assert utils.find([1, 2, 3], lambda i: i == 4) is None


def test_uniq():
    assert utils.uniq([1, 1, 1, 2, 3]) == [1, 2, 3]

    assert utils.uniq([1]) == [1]