summaryrefslogtreecommitdiff
path: root/internal/container/container_test.go
blob: 210409d4dd01767f6c29d5a8a66be377e831b541 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
package container_test

import (
	"testing"
	"time"

	"github.com/roadrunner-server/roadrunner/v2/internal/container"

	endure "github.com/roadrunner-server/endure/pkg/container"
	"github.com/stretchr/testify/assert"
)

func TestNewContainer(t *testing.T) { // there is no legal way to test container options
	c, err := container.NewContainer(container.Config{})
	c2, err2 := container.NewContainer(container.Config{
		GracePeriod: time.Second,
		PrintGraph:  true,
		LogLevel:    endure.WarnLevel,
	})

	assert.NoError(t, err)
	assert.NotNil(t, c)

	assert.NoError(t, err2)
	assert.NotNil(t, c2)
}