mirror of
https://github.com/volatiletech/authboss.git
synced 2025-02-09 13:47:09 +02:00
Fix some tests
This commit is contained in:
parent
0eff53792f
commit
f071b741da
@ -25,7 +25,7 @@ func TestErrorHandler(t *testing.T) {
|
||||
|
||||
handler.ServeHTTP(nil, httptest.NewRequest("GET", "/target", nil))
|
||||
|
||||
if !strings.Contains(b.String(), "error at /target: error occurred") {
|
||||
if !strings.Contains(b.String(), "error from (192.0.2.1:1234) /target: error occurred") {
|
||||
t.Error("output was wrong:", b.String())
|
||||
}
|
||||
}
|
||||
|
@ -92,7 +92,7 @@ func (r *Register) Post(w http.ResponseWriter, req *http.Request) error {
|
||||
storer := authboss.EnsureCanCreate(r.Config.Storage.Server)
|
||||
user := authboss.MustBeAuthable(storer.New(req.Context()))
|
||||
|
||||
pass, err := bcrypt.GenerateFromPassword([]byte(password), r.Config.Modules.RegisterBCryptCost)
|
||||
pass, err := bcrypt.GenerateFromPassword([]byte(password), r.Config.Modules.BCryptCost)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user