gitea/models/unittest
Lunny Xiao 6410c34b7f
Refactor ref type ()
Major changes:

1. do not sync ".keep" file during tests
2. fix incorrect route handler and empty repo handling (backported as  with tests)
3. do not use `RepoRef`: most of the calls are abuses.
4. Use `git.RefType` instead of a new type definition `RepoRefType` on `context`.

---------

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
..
consistency.go Replace assert.Fail with assert.FailNow ()
fixtures.go Refactor fixture loading for testing ()
fixtures_loader.go Refactor fixture loading for testing ()
fixtures_test.go Refactor fixture loading for testing ()
fscopy.go Refactor ref type ()
reflection.go Refactor tests ()
testdb.go Make git clone URL could use current signed-in user ()
unit_tests.go Refactor tests ()