1
0
mirror of https://github.com/fluencelabs/tendermint synced 2025-07-10 18:11:40 +00:00
Files
autofile
cli
clist
common
LICENSE
array.go
async.go
bit_array.go
bit_array_test.go
byteslice.go
cmap.go
cmap_test.go
colors.go
date.go
date_test.go
errors.go
heap.go
http.go
http_test.go
int.go
int_test.go
io.go
math.go
net.go
net_test.go
os.go
os_test.go
random.go
repeat_timer.go
service.go
service_test.go
string.go
string_test.go
throttle_timer.go
word.go
db
events
flowrate
log
logger
merkle
pubsub
test
version
.editorconfig
.gitignore
CHANGELOG.md
CODEOWNERS
Makefile
circle.yml
glide.lock
glide.yaml
merge.sh
test.sh
tendermint/common/string_test.go

15 lines
339 B
Go

package common
import (
"testing"
"github.com/stretchr/testify/assert"
)
func TestStringInSlice(t *testing.T) {
assert.True(t, StringInSlice("a", []string{"a", "b", "c"}))
assert.False(t, StringInSlice("d", []string{"a", "b", "c"}))
assert.True(t, StringInSlice("", []string{""}))
assert.False(t, StringInSlice("", []string{}))
}