Merge pull request #4465 from Akirtovskis/4458-git-sync-clone-in-progress
Add git:unlock command
This commit is contained in:
30
tests/unit/git_6.bats
Normal file
30
tests/unit/git_6.bats
Normal file
@@ -0,0 +1,30 @@
|
||||
#!/usr/bin/env bats
|
||||
|
||||
load test_helper
|
||||
|
||||
setup() {
|
||||
global_setup
|
||||
touch /home/dokku/.ssh/known_hosts
|
||||
chown dokku:dokku /home/dokku/.ssh/known_hosts
|
||||
mkdir -p "$DOKKU_LIB_ROOT/data/git/$TEST_APP"
|
||||
chown dokku:dokku "$DOKKU_LIB_ROOT/data/git/$TEST_APP"
|
||||
}
|
||||
|
||||
teardown() {
|
||||
rm -f /home/dokku/.ssh/id_rsa.pub || true
|
||||
global_teardown
|
||||
}
|
||||
|
||||
@test "(git) git:unlock [success]" {
|
||||
run /bin/bash -c "dokku git:unlock $TEST_APP --force"
|
||||
echo "output: $output"
|
||||
echo "status: $status"
|
||||
assert_success
|
||||
}
|
||||
|
||||
@test "(git) git:unlock [missing arg]" {
|
||||
run /bin/bash -c "dokku git:unlock"
|
||||
echo "output: $output"
|
||||
echo "status: $status"
|
||||
assert_failure
|
||||
}
|
||||
Reference in New Issue
Block a user