2016-11-05 09:53:36 +03:00
|
|
|
Feature: git-hub compatibility
|
|
|
|
Scenario: If alias named branch exists, it should not be expanded.
|
|
|
|
Given I am in "git://github.com/rtomayko/ronn.git" git repo
|
|
|
|
And the default branch for "origin" is "master"
|
|
|
|
When I successfully run `git config --global alias.branch "branch -a"`
|
|
|
|
When I run `hub branch`
|
|
|
|
Then the stdout should contain exactly "* master\n"
|
2018-07-07 13:27:46 +03:00
|
|
|
|
|
|
|
Scenario: List commands
|
|
|
|
When I successfully run `hub --list-cmds=others`
|
2018-07-07 14:35:00 +03:00
|
|
|
Then the stdout should contain exactly:
|
|
|
|
"""
|
|
|
|
add
|
|
|
|
branch
|
|
|
|
commit
|
|
|
|
alias
|
2019-01-23 01:23:56 +03:00
|
|
|
api
|
2018-07-07 14:35:00 +03:00
|
|
|
browse
|
|
|
|
ci-status
|
|
|
|
compare
|
|
|
|
create
|
|
|
|
delete
|
|
|
|
fork
|
2019-09-14 05:02:53 +03:00
|
|
|
gist
|
2018-07-07 14:35:00 +03:00
|
|
|
issue
|
|
|
|
pr
|
|
|
|
pull-request
|
|
|
|
release
|
|
|
|
sync\n
|
|
|
|
"""
|
2018-07-07 13:38:04 +03:00
|
|
|
|
|
|
|
Scenario: Doesn't sabotage --exec-path
|
|
|
|
When I successfully run `hub --exec-path`
|
|
|
|
Then the output should not contain "These GitHub commands"
|
2019-03-29 01:55:24 +03:00
|
|
|
|
|
|
|
Scenario: Shows help with --git-dir
|
|
|
|
When I run `hub --git-dir=.git`
|
|
|
|
Then the exit status should be 1
|
|
|
|
And the output should contain "usage: git "
|