summaryrefslogtreecommitdiffstats
path: root/modules/test/utils.go
blob: ed1628ab473c33e158ebd32afcde3e0d1f6507a4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// Copyright 2017 The Gitea Authors. All rights reserved.
// Use of this source code is governed by a MIT-style
// license that can be found in the LICENSE file.

package test

import (
	"net/http"
)

// RedirectURL returns the redirect URL of a http response.
func RedirectURL(resp http.ResponseWriter) string {
	return resp.Header().Get("Location")
}