Convert mock provider to async provider

This commit is contained in:
Sargun Dhillon
2019-05-17 17:15:20 -07:00
parent d0c0d90451
commit dd71a884b3
3 changed files with 160 additions and 82 deletions

View File

@@ -0,0 +1,17 @@
package mock
import (
"testing"
"github.com/virtual-kubelet/virtual-kubelet/vkubelet"
"github.com/virtual-kubelet/virtual-kubelet/providers"
"gotest.tools/assert"
)
// We can guarantee the right interfaces are implemented inside of by putting casts in place. We must do the verification
// that a given type *does not* implement a given interface in this test.
func TestMockLegacyInterface(t *testing.T) {
var mlp providers.Provider = &MockLegacyProvider{}
_, ok := mlp.(vkubelet.PodNotifier)
assert.Assert(t, !ok)
}