mirror of
https://github.com/buger/goreplay.git
synced 2024-04-21 12:32:02 +00:00
25 lines
387 B
Go
25 lines
387 B
Go
package main
|
|
|
|
import (
|
|
"testing"
|
|
)
|
|
|
|
func TestHTTPMethods(t *testing.T) {
|
|
methods := HTTPMethods{}
|
|
|
|
methods.Set("lower")
|
|
methods.Set("UPPER")
|
|
|
|
if !methods.Contains([]byte("LOWER")) {
|
|
t.Error("Does not contain LOWER")
|
|
}
|
|
|
|
if !methods.Contains([]byte("UPPER")) {
|
|
t.Error("Does not contain UPPER")
|
|
}
|
|
|
|
if methods.Contains([]byte("ABSENT")) {
|
|
t.Error("Does contain ABSENT")
|
|
}
|
|
}
|