1
0
Fork 0
mirror of https://codeberg.org/forgejo/forgejo.git synced 2024-11-22 08:42:32 -05:00
forgejo/models/unittest
Antonin Delpeuch 01b0ead664
[GITEA] Enable mocked HTTP responses for GitLab migration test
Fix gitlab migration unit test

Closes #1837.

The differences in dates can be explained by commit e19b9653ea, which
changed the order in which "created_date" and "updated_date" are
considered.

(cherry picked from commit b0bba20aa4)

Mock HTTP requests in GitLab migration test

This introduces a new utility which can be added to other tests
making HTTP calls to a live service, to cache the responses of this
service in the repository.

(cherry picked from commit 52053b1389)

Enable mocked HTTP responses for GitLab migration test

(cherry picked from commit 19cefc4de2)

Simplify HTTP mocking utility in unit tests

Follow-up to https://codeberg.org/forgejo/forgejo/pulls/1841

(cherry picked from commit ca517c8bb4)
(cherry picked from commit b227e0dd6b)
(cherry picked from commit 6cc9d06556)
(cherry picked from commit f0746e648d)
(cherry picked from commit 414193341b)
(cherry picked from commit 6e93df3bbb)
(cherry picked from commit db0dbab552)
(cherry picked from commit 8f9c9c63fb)

(cherry picked from commit e74e262030)
(cherry picked from commit 2e0933edcf)
(cherry picked from commit 65060c6961)
2024-02-05 16:09:41 +01:00
..
consistency.go Replace assert.Fail with assert.FailNow (#27578) 2023-10-11 11:02:24 +00:00
fixtures.go [TESTS] tests.AddFixtures helper loads additional per-test fixtures 2024-02-05 14:44:33 +01:00
fscopy.go Use ErrInvalidArgument in packages (#22268) 2022-12-31 12:49:37 +01:00
mock_http.go [GITEA] Enable mocked HTTP responses for GitLab migration test 2024-02-05 16:09:41 +01:00
reflection.go Replace interface{} with any (#25686) 2023-07-04 18:36:08 +00:00
testdb.go [TESTS] tests.AddFixtures helper loads additional per-test fixtures 2024-02-05 14:44:33 +01:00
unit_tests.go Upgrade xorm (#27673) 2023-10-19 10:25:57 +00:00