loading up the forgejo repo on tangled to test page performance
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge pull request 'Update instance title in tests' (#4077) from 0ko/forgejo:tests-actual-title into forgejo

Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/4077
Reviewed-by: Earl Warren <earl-warren@noreply.codeberg.org>

+25 -25
+1 -1
tests/e2e/example.test.e2e.js
··· 9 9 test('Load Homepage', async ({page}) => { 10 10 const response = await page.goto('/'); 11 11 await expect(response?.status()).toBe(200); // Status OK 12 - await expect(page).toHaveTitle(/^Gitea: Git with a cup of tea\s*$/); 12 + await expect(page).toHaveTitle(/^Forgejo: Beyond coding. We Forge.\s*$/); 13 13 await expect(page.locator('.logo')).toHaveAttribute('src', '/assets/img/logo.svg'); 14 14 }); 15 15
+14 -14
tests/integration/repo_test.go
··· 217 217 defer tests.PrintCurrentTest(t)() 218 218 219 219 htmlTitle := GetHTMLTitle(t, nil, "/user2/repo1") 220 - assert.EqualValues(t, "user2/repo1 - Gitea: Git with a cup of tea", htmlTitle) 220 + assert.EqualValues(t, "user2/repo1 - Forgejo: Beyond coding. We Forge.", htmlTitle) 221 221 }) 222 222 t.Run("With description", func(t *testing.T) { 223 223 defer tests.PrintCurrentTest(t)() 224 224 225 225 htmlTitle := GetHTMLTitle(t, nil, "/user27/repo49") 226 - assert.EqualValues(t, "user27/repo49: A wonderful repository with more than just a README.md - Gitea: Git with a cup of tea", htmlTitle) 226 + assert.EqualValues(t, "user27/repo49: A wonderful repository with more than just a README.md - Forgejo: Beyond coding. We Forge.", htmlTitle) 227 227 }) 228 228 }) 229 229 ··· 233 233 defer tests.PrintCurrentTest(t)() 234 234 235 235 htmlTitle := GetHTMLTitle(t, nil, "/user2/repo59/src/branch/master/deep/nesting") 236 - assert.EqualValues(t, "repo59/deep/nesting at master - user2/repo59 - Gitea: Git with a cup of tea", htmlTitle) 236 + assert.EqualValues(t, "repo59/deep/nesting at master - user2/repo59 - Forgejo: Beyond coding. We Forge.", htmlTitle) 237 237 }) 238 238 t.Run("Non-default branch", func(t *testing.T) { 239 239 defer tests.PrintCurrentTest(t)() 240 240 241 241 htmlTitle := GetHTMLTitle(t, nil, "/user2/repo59/src/branch/cake-recipe/deep/nesting") 242 - assert.EqualValues(t, "repo59/deep/nesting at cake-recipe - user2/repo59 - Gitea: Git with a cup of tea", htmlTitle) 242 + assert.EqualValues(t, "repo59/deep/nesting at cake-recipe - user2/repo59 - Forgejo: Beyond coding. We Forge.", htmlTitle) 243 243 }) 244 244 t.Run("Commit", func(t *testing.T) { 245 245 defer tests.PrintCurrentTest(t)() 246 246 247 247 htmlTitle := GetHTMLTitle(t, nil, "/user2/repo59/src/commit/d8f53dfb33f6ccf4169c34970b5e747511c18beb/deep/nesting/") 248 - assert.EqualValues(t, "repo59/deep/nesting at d8f53dfb33f6ccf4169c34970b5e747511c18beb - user2/repo59 - Gitea: Git with a cup of tea", htmlTitle) 248 + assert.EqualValues(t, "repo59/deep/nesting at d8f53dfb33f6ccf4169c34970b5e747511c18beb - user2/repo59 - Forgejo: Beyond coding. We Forge.", htmlTitle) 249 249 }) 250 250 t.Run("Tag", func(t *testing.T) { 251 251 defer tests.PrintCurrentTest(t)() 252 252 253 253 htmlTitle := GetHTMLTitle(t, nil, "/user2/repo59/src/tag/v1.0/deep/nesting/") 254 - assert.EqualValues(t, "repo59/deep/nesting at v1.0 - user2/repo59 - Gitea: Git with a cup of tea", htmlTitle) 254 + assert.EqualValues(t, "repo59/deep/nesting at v1.0 - user2/repo59 - Forgejo: Beyond coding. We Forge.", htmlTitle) 255 255 }) 256 256 }) 257 257 t.Run("File", func(t *testing.T) { ··· 259 259 defer tests.PrintCurrentTest(t)() 260 260 261 261 htmlTitle := GetHTMLTitle(t, nil, "/user2/repo59/src/branch/master/deep/nesting/folder/secret_sauce_recipe.txt") 262 - assert.EqualValues(t, "repo59/deep/nesting/folder/secret_sauce_recipe.txt at master - user2/repo59 - Gitea: Git with a cup of tea", htmlTitle) 262 + assert.EqualValues(t, "repo59/deep/nesting/folder/secret_sauce_recipe.txt at master - user2/repo59 - Forgejo: Beyond coding. We Forge.", htmlTitle) 263 263 }) 264 264 t.Run("Non-default branch", func(t *testing.T) { 265 265 defer tests.PrintCurrentTest(t)() 266 266 267 267 htmlTitle := GetHTMLTitle(t, nil, "/user2/repo59/src/branch/cake-recipe/deep/nesting/folder/secret_sauce_recipe.txt") 268 - assert.EqualValues(t, "repo59/deep/nesting/folder/secret_sauce_recipe.txt at cake-recipe - user2/repo59 - Gitea: Git with a cup of tea", htmlTitle) 268 + assert.EqualValues(t, "repo59/deep/nesting/folder/secret_sauce_recipe.txt at cake-recipe - user2/repo59 - Forgejo: Beyond coding. We Forge.", htmlTitle) 269 269 }) 270 270 t.Run("Commit", func(t *testing.T) { 271 271 defer tests.PrintCurrentTest(t)() 272 272 273 273 htmlTitle := GetHTMLTitle(t, nil, "/user2/repo59/src/commit/d8f53dfb33f6ccf4169c34970b5e747511c18beb/deep/nesting/folder/secret_sauce_recipe.txt") 274 - assert.EqualValues(t, "repo59/deep/nesting/folder/secret_sauce_recipe.txt at d8f53dfb33f6ccf4169c34970b5e747511c18beb - user2/repo59 - Gitea: Git with a cup of tea", htmlTitle) 274 + assert.EqualValues(t, "repo59/deep/nesting/folder/secret_sauce_recipe.txt at d8f53dfb33f6ccf4169c34970b5e747511c18beb - user2/repo59 - Forgejo: Beyond coding. We Forge.", htmlTitle) 275 275 }) 276 276 t.Run("Tag", func(t *testing.T) { 277 277 defer tests.PrintCurrentTest(t)() 278 278 279 279 htmlTitle := GetHTMLTitle(t, nil, "/user2/repo59/src/tag/v1.0/deep/nesting/folder/secret_sauce_recipe.txt") 280 - assert.EqualValues(t, "repo59/deep/nesting/folder/secret_sauce_recipe.txt at v1.0 - user2/repo59 - Gitea: Git with a cup of tea", htmlTitle) 280 + assert.EqualValues(t, "repo59/deep/nesting/folder/secret_sauce_recipe.txt at v1.0 - user2/repo59 - Forgejo: Beyond coding. We Forge.", htmlTitle) 281 281 }) 282 282 }) 283 283 }) ··· 287 287 defer tests.PrintCurrentTest(t)() 288 288 289 289 htmlTitle := GetHTMLTitle(t, nil, "/user2/repo1/issues") 290 - assert.EqualValues(t, "Issues - user2/repo1 - Gitea: Git with a cup of tea", htmlTitle) 290 + assert.EqualValues(t, "Issues - user2/repo1 - Forgejo: Beyond coding. We Forge.", htmlTitle) 291 291 }) 292 292 t.Run("View issue page", func(t *testing.T) { 293 293 defer tests.PrintCurrentTest(t)() 294 294 295 295 htmlTitle := GetHTMLTitle(t, nil, "/user2/repo1/issues/1") 296 - assert.EqualValues(t, "#1 - issue1 - user2/repo1 - Gitea: Git with a cup of tea", htmlTitle) 296 + assert.EqualValues(t, "#1 - issue1 - user2/repo1 - Forgejo: Beyond coding. We Forge.", htmlTitle) 297 297 }) 298 298 }) 299 299 ··· 302 302 defer tests.PrintCurrentTest(t)() 303 303 304 304 htmlTitle := GetHTMLTitle(t, nil, "/user2/repo1/pulls") 305 - assert.EqualValues(t, "Pull requests - user2/repo1 - Gitea: Git with a cup of tea", htmlTitle) 305 + assert.EqualValues(t, "Pull requests - user2/repo1 - Forgejo: Beyond coding. We Forge.", htmlTitle) 306 306 }) 307 307 t.Run("View pull request", func(t *testing.T) { 308 308 defer tests.PrintCurrentTest(t)() 309 309 310 310 htmlTitle := GetHTMLTitle(t, nil, "/user2/repo1/pulls/2") 311 - assert.EqualValues(t, "#2 - issue2 - user2/repo1 - Gitea: Git with a cup of tea", htmlTitle) 311 + assert.EqualValues(t, "#2 - issue2 - user2/repo1 - Forgejo: Beyond coding. We Forge.", htmlTitle) 312 312 }) 313 313 }) 314 314 }
+4 -4
tests/integration/view_test.go
··· 189 189 func TestTitleDisplayName(t *testing.T) { 190 190 session := emptyTestSession(t) 191 191 title := GetHTMLTitle(t, session, "/") 192 - assert.Equal(t, "Gitea: Git with a cup of tea", title) 192 + assert.Equal(t, "Forgejo: Beyond coding. We Forge.", title) 193 193 } 194 194 195 195 func TestHomeDisplayName(t *testing.T) { ··· 197 197 req := NewRequest(t, "GET", "/") 198 198 resp := session.MakeRequest(t, req, http.StatusOK) 199 199 htmlDoc := NewHTMLParser(t, resp.Body) 200 - assert.Equal(t, "Gitea: Git with a cup of tea", strings.TrimSpace(htmlDoc.Find("h1.title").Text())) 200 + assert.Equal(t, "Forgejo: Beyond coding. We Forge.", strings.TrimSpace(htmlDoc.Find("h1.title").Text())) 201 201 } 202 202 203 203 func TestOpenGraphDisplayName(t *testing.T) { ··· 206 206 resp := session.MakeRequest(t, req, http.StatusOK) 207 207 htmlDoc := NewHTMLParser(t, resp.Body) 208 208 ogTitle, _ := htmlDoc.Find("meta[property='og:title']").Attr("content") 209 - assert.Equal(t, "Gitea: Git with a cup of tea", ogTitle) 209 + assert.Equal(t, "Forgejo: Beyond coding. We Forge.", ogTitle) 210 210 ogSiteName, _ := htmlDoc.Find("meta[property='og:site_name']").Attr("content") 211 - assert.Equal(t, "Gitea: Git with a cup of tea", ogSiteName) 211 + assert.Equal(t, "Forgejo: Beyond coding. We Forge.", ogSiteName) 212 212 }
+2 -2
tests/mysql.ini.tmpl
··· 1 - APP_NAME = Gitea 2 - APP_SLOGAN = Git with a cup of tea 1 + APP_NAME = Forgejo 2 + APP_SLOGAN = Beyond coding. We Forge. 3 3 RUN_MODE = prod 4 4 5 5 [database]
+2 -2
tests/pgsql.ini.tmpl
··· 1 - APP_NAME = Gitea 2 - APP_SLOGAN = Git with a cup of tea 1 + APP_NAME = Forgejo 2 + APP_SLOGAN = Beyond coding. We Forge. 3 3 RUN_MODE = prod 4 4 5 5 [database]
+2 -2
tests/sqlite.ini.tmpl
··· 1 - APP_NAME = Gitea 2 - APP_SLOGAN = Git with a cup of tea 1 + APP_NAME = Forgejo 2 + APP_SLOGAN = Beyond coding. We Forge. 3 3 RUN_MODE = prod 4 4 5 5 [database]