mirror of
https://git.centos.org/centos/centpkg.git
synced 2025-02-23 16:22:55 +00:00
21 lines
543 B
Python
21 lines
543 B
Python
import unittest
|
|
|
|
from centpkg import utils
|
|
|
|
|
|
class TestGetRepoName(unittest.TestCase):
|
|
def test_rpms_org(self):
|
|
assert utils.get_repo_name('rpms/time') == 'rpms/time'
|
|
|
|
def test_gitlab_fork(self):
|
|
assert utils.get_repo_name('someuser/time') == 'rpms/time'
|
|
|
|
def test_centpkg_fork(self):
|
|
assert utils.get_repo_name('someuser/centos_rpms_binutils') == 'rpms/binutils'
|
|
|
|
def test_ssh_fork(self):
|
|
assert utils.get_repo_name('git@gitlab.com:nickc2/binutils') == 'rpms/binutils'
|
|
|
|
|
|
if __name__ == '__main__':
|
|
unittest.main()
|