зеркало из https://github.com/microsoft/docker.git
20 строки
341 B
Go
20 строки
341 B
Go
package api
|
|
|
|
import (
|
|
"testing"
|
|
)
|
|
|
|
func TestJsonContentType(t *testing.T) {
|
|
if !MatchesContentType("application/json", "application/json") {
|
|
t.Fail()
|
|
}
|
|
|
|
if !MatchesContentType("application/json; charset=utf-8", "application/json") {
|
|
t.Fail()
|
|
}
|
|
|
|
if MatchesContentType("dockerapplication/json", "application/json") {
|
|
t.Fail()
|
|
}
|
|
}
|