@@ -55,7 +55,7 @@ func TestCreateFileOnProtectedBranch(t *testing.T) {
5555 // Check if master branch has been locked successfully
5656 flashCookie := session .GetCookie (gitea_context .CookieNameFlash )
5757 assert .NotNil (t , flashCookie )
58- assert .EqualValues (t , "success%3DBranch%2Bprotection%2Bfor%2Brule%2B%2527master%2527 %2Bhas%2Bbeen%2Bupdated." , flashCookie .Value )
58+ assert .EqualValues (t , "success%3DBranch%2Bprotection%2Bfor%2Brule%2B%2522master%2522 %2Bhas%2Bbeen%2Bupdated." , flashCookie .Value )
5959
6060 // Request editor page
6161 req = NewRequest (t , "GET" , "/user2/repo1/_new/master/" )
@@ -76,7 +76,7 @@ func TestCreateFileOnProtectedBranch(t *testing.T) {
7676
7777 resp = session .MakeRequest (t , req , http .StatusOK )
7878 // Check body for error message
79- assert .Contains (t , resp .Body .String (), "Cannot commit to protected branch ' ;master' ;." )
79+ assert .Contains (t , resp .Body .String (), "Cannot commit to protected branch " ;master" ;." )
8080
8181 // remove the protected branch
8282 csrf = GetCSRF (t , session , "/user2/repo1/settings/branches" )
@@ -95,7 +95,7 @@ func TestCreateFileOnProtectedBranch(t *testing.T) {
9595 // Check if master branch has been locked successfully
9696 flashCookie = session .GetCookie (gitea_context .CookieNameFlash )
9797 assert .NotNil (t , flashCookie )
98- assert .EqualValues (t , "error%3DRemoving%2Bbranch%2Bprotection%2Brule%2B%25271%2527 %2Bfailed." , flashCookie .Value )
98+ assert .EqualValues (t , "error%3DRemoving%2Bbranch%2Bprotection%2Brule%2B%25221%2522 %2Bfailed." , flashCookie .Value )
9999 })
100100}
101101
0 commit comments