2021-08-23 13:14:53 +00:00
|
|
|
//go:build windows
|
2017-03-10 17:39:22 +00:00
|
|
|
|
2018-02-05 21:05:59 +00:00
|
|
|
package runconfig // import "github.com/docker/docker/runconfig"
|
2017-03-10 17:39:22 +00:00
|
|
|
|
|
|
|
import (
|
|
|
|
"testing"
|
|
|
|
|
|
|
|
"github.com/docker/docker/api/types/container"
|
|
|
|
)
|
|
|
|
|
|
|
|
func TestValidatePrivileged(t *testing.T) {
|
2017-05-21 17:50:55 +00:00
|
|
|
expected := "Windows does not support privileged mode"
|
2017-03-10 17:39:22 +00:00
|
|
|
err := validatePrivileged(&container.HostConfig{Privileged: true})
|
|
|
|
if err == nil || err.Error() != expected {
|
|
|
|
t.Fatalf("Expected %s", expected)
|
|
|
|
}
|
|
|
|
}
|