mirror of
https://github.com/podman-container-tools/podman.git
synced 2026-08-21 15:57:54 +00:00
The InstalledProviders and SupportedProviders functions were only used in their own tests and were otherwise dead code. Removing them entirely cleans up the API surface. Signed-off-by: Aryanbhargava18 <aryanbhargava644@gmail.com>
26 lines
572 B
Go
26 lines
572 B
Go
package provider
|
|
|
|
import (
|
|
"runtime"
|
|
"testing"
|
|
|
|
"github.com/stretchr/testify/assert"
|
|
"go.podman.io/podman/v6/pkg/machine/define"
|
|
)
|
|
|
|
func TestHasPermsForProvider(t *testing.T) {
|
|
provider, err := Get()
|
|
assert.NoError(t, err)
|
|
assert.True(t, HasPermsForProvider(provider.VMType()))
|
|
}
|
|
|
|
func TestHasBadPerms(t *testing.T) {
|
|
switch runtime.GOOS {
|
|
case "darwin":
|
|
assert.False(t, HasPermsForProvider(define.QemuVirt))
|
|
case "windows":
|
|
assert.False(t, HasPermsForProvider(define.QemuVirt))
|
|
case "linux":
|
|
assert.False(t, HasPermsForProvider(define.AppleHvVirt))
|
|
}
|
|
}
|