summaryrefslogtreecommitdiff
path: root/errors_test.go
blob: d7b2feb4a5bfd0e15188d436f9dd12f9ca61ae59 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
package roadrunner

import (
	"github.com/stretchr/testify/assert"
	"testing"
	"github.com/go-errors/errors"
)

func Test_JobError_Error(t *testing.T) {
	e := JobError([]byte("error"))
	assert.Equal(t, "error", e.Error())
}

func Test_WorkerError_Error(t *testing.T) {
	e := WorkerError{Worker: nil, Caused: errors.New("error")}
	assert.Equal(t, "error", e.Error())
}