diff --git a/esti/lakectl_local_test.go b/esti/lakectl_local_test.go index 2ec84438516..e0f9a85f6ba 100644 --- a/esti/lakectl_local_test.go +++ b/esti/lakectl_local_test.go @@ -551,6 +551,11 @@ func TestLakectlLocal_commitProtetedBranch(t *testing.T) { str := runCmd(t, Lakectl()+" branch-protect list lakefs://"+repoName+"/ ", false, false, vars) fmt.Println("itamar testing", str) // Commit changes to branch + runCmd(t, Lakectl()+" commit lakefs://"+vars["REPO"]+"/"+vars["BRANCH"]+" --allow-empty-message -m \" \"", false, false, vars) + + RunCmdAndVerifyFailureContainsText(t, Lakectl()+" fs upload -s files/ro_1k lakefs://"+vars["REPO"]+"/"+vars["BRANCH"]+"/"+"fail_file.txt", false, "cannot write to protected branch", vars) + RunCmdAndVerifyContainsText(t, Lakectl()+" local list", false, repoName+"/"+vars["BRANCH"], vars) + RunCmdAndVerifyFailureContainsText(t, Lakectl()+" local commit -m test "+dataDir, false, "cannot write to protected branch", vars) //runCmd(t, Lakectl()+" branch-protect delete lakefs://"+repoName+"/ \"*\"", false, false, vars)