1
0
mirror of https://github.com/goreleaser/goreleaser.git synced 2025-01-22 04:08:49 +02:00
goreleaser/internal/pipeline/pipeline_test.go

21 lines
363 B
Go
Raw Normal View History

2017-08-20 16:35:46 -03:00
package pipeline
import (
2017-09-12 00:22:02 -03:00
"errors"
2017-08-20 16:35:46 -03:00
"testing"
"github.com/stretchr/testify/assert"
)
func TestSkipPipe(t *testing.T) {
var reason = "this is a test"
var err = Skip(reason)
assert.Error(t, err)
assert.Equal(t, reason, err.Error())
2017-08-20 16:35:46 -03:00
}
2017-09-12 00:22:02 -03:00
func TestIsSkip(t *testing.T) {
assert.True(t, IsSkip(Skip("whatever")))
assert.False(t, IsSkip(errors.New("nope")))
2017-09-12 00:22:02 -03:00
}