grim/convey
Clone
Summary
Browse
Changes
Graph
Add a script/shell command that can run scripts on the host machine
redux
2021-12-20, Gary Kramlich
f9638cf514da
Add a script/shell command that can run scripts on the host machine
package
podman
import
(
"testing"
"github.com/stretchr/testify/assert"
"keep.imfreedom.org/grim/convey/yaml"
)
func
TestPushString
(
t
*
testing
.
T
)
{
p
:=
&
Push
{
Tags
:
yaml
.
StringOrSlice
{
"foo"
},
}
assert
.
NoError
(
t
,
p
.
Valid
())
}
func
TestPushSlice
(
t
*
testing
.
T
)
{
p
:=
&
Push
{
Tags
:
[]
string
{
"foo"
,
"bar"
},
}
assert
.
NoError
(
t
,
p
.
Valid
())
}
func
TestPushTagsRequired
(
t
*
testing
.
T
)
{
p
:=
&
Push
{}
assert
.
ErrorIs
(
t
,
p
.
Valid
(),
ErrNoTags
)
}