From 140edbbceefdeff41ab8ae90bb2b95e68788b3bb Mon Sep 17 00:00:00 2001 From: Nils Winkler Date: Thu, 11 Jan 2018 08:18:42 +0100 Subject: [PATCH] Fixed test names to match existing tests Also removed some duplicated tests that were introduced during a previous merge. --- test/git-open.bats | 29 ++++++++--------------------- 1 file changed, 8 insertions(+), 21 deletions(-) diff --git a/test/git-open.bats b/test/git-open.bats index 0f750d2..b726f5d 100755 --- a/test/git-open.bats +++ b/test/git-open.bats @@ -214,22 +214,6 @@ setup() { refute_output --partial "@" } -@test "bitbucket server" { - # https://github.com/paulirish/git-open/pull/15 - git remote set-url origin "https://user@bitbucket.example.com/scm/ppp/test-repo.git" - run ../git-open - assert_output "https://bitbucket.example.com/projects/ppp/repos/test-repo" -} - -@test "bitbucket server branch" { - # https://github.com/paulirish/git-open/pull/15 - git remote set-url origin "https://user@bitbucket.example.com/scm/ppp/test-repo.git" - git checkout -B "bb-server" - run ../git-open - assert_output "https://bitbucket.example.com/projects/ppp/repos/test-repo/browse?at=bb-server" -} - - @test "bitbucket: Bitbucket Server" { # https://github.com/paulirish/git-open/issues/77#issuecomment-309044010 git remote set-url origin "https://user@mybb.domain.com/scm/ppp/rrr.git" @@ -270,19 +254,23 @@ setup() { } -@test "bitbucket server with different root context" { +@test "bitbucket: Bitbucket Server with different root context" { # https://github.com/paulirish/git-open/pull/15 git remote set-url origin "https://user@bitbucket.example.com/git/scm/ppp/test-repo.git" run ../git-open - assert_output "https://bitbucket.example.com/git/projects/ppp/repos/test-repo" + assert_output "https://bitbucket.example.com/git/projects/ppp/repos/test-repo" || + assert_output "https://bitbucket.example.com/git/projects/ppp/repos/test-repo/?at=master" || + assert_output "https://bitbucket.example.com/git/projects/ppp/repos/test-repo/?at=refs%2Fheads%2Fmaster" } -@test "bitbucket server with different root context with multiple parts" { +@test "bitbucket: Bitbucket Server with different root context with multiple parts" { # https://github.com/paulirish/git-open/pull/15 git remote set-url origin "https://user@bitbucket.example.com/really/long/root/context/scm/ppp/test-repo.git" run ../git-open - assert_output "https://bitbucket.example.com/really/long/root/context/projects/ppp/repos/test-repo" + assert_output "https://bitbucket.example.com/really/long/root/context/projects/ppp/repos/test-repo" || + assert_output "https://bitbucket.example.com/really/long/root/context/projects/ppp/repos/test-repo/?at=master" || + assert_output "https://bitbucket.example.com/really/long/root/context/projects/ppp/repos/test-repo/?at=refs%2Fheads%2Fmaster" } @@ -294,7 +282,6 @@ setup() { assert_output "https://mybb.domain.com/root/context/projects/~first.last/repos/rrr/browse?at=develop" || assert_output "https://mybb.domain.com/root/context/projects/~first.last/repos/rrr/browse?at=refs%2Fheads%2Fdevelop" || assert_output "https://mybb.domain.com/root/context/projects/~first.last/repos/rrr/browse?at=refs/heads/develop" - }