mirror of
https://github.com/openSUSE/osc.git
synced 2024-11-10 22:56:15 +01:00
Merge pull request #1302 from dmach/fix-buildhistory-limit-type
Fix 'buildhistory' command by setting the type of the '--limit' option to int
This commit is contained in:
commit
c9c3dd62c0
@ -11,6 +11,11 @@ Scenario: Run `osc buildist <project>/<package> <repository>/<arch>`
|
|||||||
Then the exit code is 0
|
Then the exit code is 0
|
||||||
|
|
||||||
|
|
||||||
|
Scenario: Run `osc buildist <project>/<package> <repository>/<arch> --limit`
|
||||||
|
When I execute osc with args "buildhist test:factory/test-pkgA standard/x86_64 --limit=1"
|
||||||
|
Then the exit code is 0
|
||||||
|
|
||||||
|
|
||||||
Scenario: Run `osc buildist <repository>/<arch>` from a package checkout
|
Scenario: Run `osc buildist <repository>/<arch>` from a package checkout
|
||||||
Given I execute osc with args "co test:factory/test-pkgA"
|
Given I execute osc with args "co test:factory/test-pkgA"
|
||||||
And I set working directory to "{context.osc.temp}/test:factory/test-pkgA"
|
And I set working directory to "{context.osc.temp}/test:factory/test-pkgA"
|
||||||
|
@ -20,7 +20,7 @@ class BuildHistory:
|
|||||||
self.package = package
|
self.package = package
|
||||||
self.repository = repository
|
self.repository = repository
|
||||||
self.arch = arch
|
self.arch = arch
|
||||||
self._limit = limit
|
self._limit = int(limit)
|
||||||
self.entries = self._get_entries()
|
self.entries = self._get_entries()
|
||||||
|
|
||||||
def _get_entries(self):
|
def _get_entries(self):
|
||||||
|
@ -7381,7 +7381,7 @@ Please submit there instead, or use --nodevelproject to force direct submission.
|
|||||||
|
|
||||||
@cmdln.option('', '--csv', action='store_true',
|
@cmdln.option('', '--csv', action='store_true',
|
||||||
help='generate output in CSV (separated by |)')
|
help='generate output in CSV (separated by |)')
|
||||||
@cmdln.option('-l', '--limit', metavar='limit',
|
@cmdln.option('-l', '--limit', metavar='limit', type=int, default=0,
|
||||||
help='for setting the number of results')
|
help='for setting the number of results')
|
||||||
@cmdln.option('-M', '--multibuild-package', metavar='FLAVOR',
|
@cmdln.option('-M', '--multibuild-package', metavar='FLAVOR',
|
||||||
help=HELP_MULTIBUILD_ONE)
|
help=HELP_MULTIBUILD_ONE)
|
||||||
|
Loading…
Reference in New Issue
Block a user