Skip to content

Commit

Permalink
fix delete contexts
Browse files Browse the repository at this point in the history
  • Loading branch information
feloy committed Jan 2, 2019
1 parent 210b592 commit 4868074
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions test/kubectx.bats
Expand Up @@ -123,9 +123,9 @@ load common
run ${COMMAND}
echo "$output"
[ "$status" -eq 0 ]
[[ ! "$output" = *"user1@cluster1"* ]]
[[ "$output" = *"new-context"* ]]
[[ "$output" = *"user2@cluster1"* ]]
[[ ! "$output" = *"user1@cluster1"* ]]
}

@test "rename current context" {
Expand All @@ -142,9 +142,9 @@ load common
run ${COMMAND}
echo "$output"
[ "$status" -eq 0 ]
[[ ! "$output" = *"user2@cluster1"* ]]
[[ "$output" = *"user1@cluster1"* ]]
[[ "$output" = *"new-context"* ]]
[[ ! "$output" = *"user2@cluster1"* ]]
}

@test "delete context" {
Expand All @@ -157,6 +157,7 @@ load common
run ${COMMAND}
echo "$output"
[ "$status" -eq 0 ]
[[ ! "$output" = "user1@cluster1" ]]
[[ "$output" = "user2@cluster1" ]]
}

Expand All @@ -174,8 +175,8 @@ load common
run ${COMMAND}
echo "$output"
[ "$status" -eq 0 ]
[[ "$output" = "user1@cluster1" ]]
[[ ! "$output" = "user2@cluster1" ]]
[[ "$output" = "user1@cluster1" ]]
}

@test "delete non existent context" {
Expand Down

0 comments on commit 4868074

Please sign in to comment.