mirror of
https://github.com/openSUSE/osc.git
synced 2025-12-02 17:07:10 +01:00
Implement 'git-obs repo list' command
This commit is contained in:
70
behave/features/git-repo-list.feature
Normal file
70
behave/features/git-repo-list.feature
Normal file
@@ -0,0 +1,70 @@
|
||||
Feature: `git-obs repo list` command
|
||||
|
||||
|
||||
Background:
|
||||
Given I set working directory to "{context.osc.temp}"
|
||||
|
||||
|
||||
@destructive
|
||||
Scenario: List repos owned by an organization
|
||||
When I execute git-obs with args "repo list --org=pool"
|
||||
Then the exit code is 0
|
||||
And stdout is
|
||||
"""
|
||||
pool/test-GitPkgA
|
||||
"""
|
||||
And stderr is
|
||||
"""
|
||||
Using the following Gitea settings:
|
||||
* Config path: {context.git_obs.config}
|
||||
* Login (name of the entry in the config file): admin
|
||||
* URL: http://localhost:{context.podman.container.ports[gitea_http]}
|
||||
* User: Admin
|
||||
|
||||
|
||||
Total repos: 1
|
||||
"""
|
||||
|
||||
@destructive
|
||||
Scenario: List repos owned by a user
|
||||
Given I execute git-obs with args "repo fork pool/test-GitPkgA"
|
||||
When I execute git-obs with args "repo list --user=Admin"
|
||||
Then the exit code is 0
|
||||
And stdout is
|
||||
"""
|
||||
Admin/test-GitPkgA
|
||||
"""
|
||||
And stderr is
|
||||
"""
|
||||
Using the following Gitea settings:
|
||||
* Config path: {context.git_obs.config}
|
||||
* Login (name of the entry in the config file): admin
|
||||
* URL: http://localhost:{context.podman.container.ports[gitea_http]}
|
||||
* User: Admin
|
||||
|
||||
|
||||
Total repos: 1
|
||||
"""
|
||||
|
||||
|
||||
@destructive
|
||||
Scenario: List repos owned by a user and an organization
|
||||
Given I execute git-obs with args "repo fork pool/test-GitPkgA"
|
||||
When I execute git-obs with args "repo list --user=Admin --org=pool"
|
||||
Then the exit code is 0
|
||||
And stdout is
|
||||
"""
|
||||
pool/test-GitPkgA
|
||||
Admin/test-GitPkgA
|
||||
"""
|
||||
And stderr is
|
||||
"""
|
||||
Using the following Gitea settings:
|
||||
* Config path: {context.git_obs.config}
|
||||
* Login (name of the entry in the config file): admin
|
||||
* URL: http://localhost:{context.podman.container.ports[gitea_http]}
|
||||
* User: Admin
|
||||
|
||||
|
||||
Total repos: 2
|
||||
"""
|
||||
Reference in New Issue
Block a user