Gusted
4c67023c7e
tests: improve actvititypub integration test code
...
- Make use of `test.MockVariableValue` to override variables for the
duration of the test.
- Don't needlessly call `onGiteaRun`, its only needed when a HTTP server
needs to be called by the code.
- When `onGiteaRun` is used, make use of the passed parameters, such as
the passed `*testing.T` variable and `*url.URL` (this also avoids
needing to serve the routers in the test code again).
- Use `(*url.URL).JoinPath` to craft new URLs.
- Don't override `setting.AppURL` & `setting.Database.LogSQL` when its
does not affect the test.
- Add empty fixture files for `FederatedUser` & `FederationHost` so they
are truncated and do not persist between tests.
2024-11-01 22:39:49 +01:00
TheFox0x7
4de909747b
Add testifylint to lint checks ( #4535 )
...
go-require lint is ignored for now
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/4535
Reviewed-by: Gusted <gusted@noreply.codeberg.org>
Co-authored-by: TheFox0x7 <thefox0x7@gmail.com>
Co-committed-by: TheFox0x7 <thefox0x7@gmail.com>
2024-07-30 19:41:10 +00:00
Earl Warren
563b7f8345
[UPGRADE] run sanity checks before the database is upgraded
...
https://codeberg.org/forgejo/forgejo/pulls/1543
(cherry picked from commit fbb71f464b
)
(cherry picked from commit 650f849c84
)
(cherry picked from commit 25e0d33dfe
)
(cherry picked from commit 222b70e504
)
(cherry picked from commit 4be04627a7
)
(cherry picked from commit 64fcb25de3
)
(cherry picked from commit 740943d6b0
)
(cherry picked from commit 3c096abf11
)
(cherry picked from commit da04dcb099
)
(cherry picked from commit b881d83f1c
)
(cherry picked from commit 7e7492b996
)
(cherry picked from commit 869edd3b0a
)
(cherry picked from commit d96fbda274
)
(cherry picked from commit 09c00cbd00
)
(cherry picked from commit 10a1bf8122
)
(cherry picked from commit 2eb223c0f6
)
(cherry picked from commit 1eaba14638
)
2024-02-05 14:44:33 +01:00
Earl Warren
f6ba73de4c
[UPGRADE] add sanity checks for [storage*]
...
Refs: https://forgejo.org/2023-08-release-v1-20-3-0/
(cherry picked from commit a266dd0ce3
)
(cherry picked from commit b9eb5eccd8
)
(cherry picked from commit 7fc2028ede
)
(cherry picked from commit 0c988e6120
)
(cherry picked from commit 7ba05e8c2b
)
(cherry picked from commit 2ed5068abe
)
(cherry picked from commit 353913a26d
)
(cherry picked from commit 4e63a01a8b
)
(cherry picked from commit 99f612aed3
)
(cherry picked from commit b4fe189cae
)
(cherry picked from commit bd35e3b7bc
)
(cherry picked from commit f59d9f7088
)
(cherry picked from commit 0b2a93e044
)
(cherry picked from commit 8c5d8bfea0
)
(cherry picked from commit 2817ce027c
)
(cherry picked from commit 162056cbcf
)
(cherry picked from commit 07152a0ba6
)
(cherry picked from commit 72e3777915
)
(cherry picked from commit 3b1ebd95b9
)
(cherry picked from commit 14fc4f3fac
)
(cherry picked from commit 9052c86e8c
)
(cherry picked from commit 16f1cc21ea
)
(cherry picked from commit 0fef12f5d8
)
(cherry picked from commit d187381f73
)
(cherry picked from commit 9dda715111
)
2024-02-05 14:44:33 +01:00
Earl Warren
160ae5ee23
[UPGRADE] run sanity checks before the database is upgraded
...
(cherry picked from commit 69741e4e66
)
(cherry picked from commit 2a3c7b09cb
)
(cherry picked from commit a1554c1168
)
(cherry picked from commit edae2c6d2d
)
(cherry picked from commit 49737cf009
)
(cherry picked from commit ec53704c34
)
(cherry picked from commit 7a1c5c0f32
)
(cherry picked from commit e658c20c0f
)
(cherry picked from commit baf575468f
)
(cherry picked from commit 40cb14eff4
)
(cherry picked from commit 25ab4d0713
)
(cherry picked from commit 5a29005215
)
(cherry picked from commit fef1260e99
)
(cherry picked from commit eadbbb1afe
)
(cherry picked from commit db22d61eb4
)
(cherry picked from commit 9d3b0be39a
)
(cherry picked from commit b3fa3c1292
)
(cherry picked from commit c8300d4fe2
)
(cherry picked from commit 8ba6a4c9db
)
(cherry picked from commit 8b8df652c1
)
(cherry picked from commit fc8fa050c6
)
(cherry picked from commit bcf3faf698
)
(cherry picked from commit 514a631aa6
)
(cherry picked from commit 529c7a09f7
)
(cherry picked from commit 0d093d76e2
)
2024-02-05 14:44:33 +01:00