update cli tests
This commit is contained in:
parent
ac3f76a4de
commit
c02eb739aa
30 changed files with 667 additions and 695 deletions
|
|
@ -1,21 +1,18 @@
|
|||
from __future__ import absolute_import
|
||||
import unittest
|
||||
|
||||
from . import loadcli
|
||||
from six.moves import range
|
||||
|
||||
cli = loadcli.cli
|
||||
|
||||
from koji_cli.lib import _unique_path
|
||||
|
||||
class TestUniquePath(unittest.TestCase):
|
||||
|
||||
def test_unique_path(self):
|
||||
for i in range(1000):
|
||||
self.assertNotEqual(
|
||||
cli._unique_path('prefix'),
|
||||
cli._unique_path('prefix'))
|
||||
_unique_path('prefix'),
|
||||
_unique_path('prefix'))
|
||||
self.assertRegexpMatches(
|
||||
cli._unique_path('prefix'),
|
||||
_unique_path('prefix'),
|
||||
'^prefix/\d{10}\.\d{1,7}\.[a-zA-Z]{8}$')
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue