Commit Graph

15 Commits (694441fec5036bf2e5ee6a261b40ada2bfc76d61)

Author SHA1 Message Date
KN4CK3R 3f280f89e7
Update HTTP status codes to modern codes ()
* 2xx/3xx/4xx/5xx -> http.Status...
* http.StatusFound -> http.StatusTemporaryRedirect
* http.StatusMovedPermanently -> http.StatusPermanentRedirect
Lunny Xiao a666829a37
Move user related model into models/user ()
* Move user related model into models/user

* Fix lint for windows

* Fix windows lint

* Fix windows lint

* Move some tests in models

* Merge
Gusted c98dd7a3e0
Remove unnecessary variable assignments ()
* Remove unnecessary variable assignments

As title

* enable ineffassign

Co-authored-by: zeripath <art27@cantab.net>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
wxiaoguang 81926d61db
Decouple unit test, remove intermediate `unittestbridge` package ()
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Lunny Xiao a4bfef265d
Move db related basic functions to models/db ()
* Move db related basic functions to models/db

* Fix lint

* Fix lint

* Fix test

* Fix lint

* Fix lint

* revert unnecessary change

* Fix test

* Fix wrong replace string

* Use *Context

* Correct committer spelling and fix wrong replaced words

Co-authored-by: zeripath <art27@cantab.net>
zeripath 055f6d2296 Fix "data race" in testlogger ()
* Fix data race in testlogger

* Update git_helper_for_declarative_test.go
Ethan Koenig e59adcde65 Use httptest in integration tests ()
Lauris BH 1ec4dc6c1d Fix so that user can still fork his own repository to owned organizations ()
* Fix so that user can still fork his own repository to his organizations

* Fix to only use owned organizations

* Add integration test for forking own repository to owned organization
Ethan Koenig f1adaef458 Less verbose integration tests ()
* Helper functions for intergration test boilerplate
Ethan Koenig f64c232953 Improve integration test helper functions ()
Set request headers in helper functions, and new helper for requests with string-formatted URLs
Bo-Yi Wu 90f9bb12c6 fix golint error and rename func for suggestion. ()
Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
Ethan Koenig ce9b86082c Consolidate boilerplate in integration tests ()
Mura Li 01322af2e8 Add integration test for pull-request merge ()
Ethan Koenig 61716bd8f7 Display URLs in integration test logs ()
Mura Li 30a831698e Add integration test for repository forking