swaps the corso go module from github.com/ alcionai/corso to github.com/alcionai/corso/src to align with the location of the go.mod and go.sum files inside the repo. All other changes in the repository update the package imports to the new module path.
29 lines
561 B
Go
29 lines
561 B
Go
package common_test
|
|
|
|
import (
|
|
"testing"
|
|
|
|
"github.com/stretchr/testify/assert"
|
|
"github.com/stretchr/testify/suite"
|
|
|
|
"github.com/alcionai/corso/src/internal/common"
|
|
)
|
|
|
|
type CommonSlicesSuite struct {
|
|
suite.Suite
|
|
}
|
|
|
|
func TestCommonSlicesSuite(t *testing.T) {
|
|
suite.Run(t, new(CommonSlicesSuite))
|
|
}
|
|
|
|
func (suite *CommonSlicesSuite) TestContainsString() {
|
|
t := suite.T()
|
|
target := "fnords"
|
|
good := []string{"fnords"}
|
|
bad := []string{"foo", "bar"}
|
|
|
|
assert.True(t, common.ContainsString(good, target))
|
|
assert.False(t, common.ContainsString(bad, target))
|
|
}
|