Updating components to use v1beta3
This commit is contained in:
@@ -30,7 +30,7 @@ import (
|
||||
)
|
||||
|
||||
// Version is the string that represents the current external default version.
|
||||
const Version = "v1beta1"
|
||||
const Version = "v1beta3"
|
||||
|
||||
// OldestVersion is the string that represents the oldest server version supported,
|
||||
// for client code that wants to hardcode the lowest common denominator.
|
||||
@@ -46,7 +46,7 @@ var Versions = []string{"v1beta1", "v1beta2", "v1beta3"}
|
||||
// the latest supported version. Use this Codec when writing to
|
||||
// disk, a data store that is not dynamically versioned, or in tests.
|
||||
// This codec can decode any object that Kubernetes is aware of.
|
||||
var Codec = v1beta1.Codec
|
||||
var Codec = v1beta3.Codec
|
||||
|
||||
// accessor is the shared static metadata accessor for the API.
|
||||
var accessor = meta.NewAccessor()
|
||||
|
@@ -72,10 +72,11 @@ func TestInterfacesFor(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestRESTMapper(t *testing.T) {
|
||||
if v, k, err := RESTMapper.VersionAndKindForResource("replicationControllers"); err != nil || v != Version || k != "ReplicationController" {
|
||||
// TODO: This test does not seem right. The version returned here depends on the order in which API versions were registered. This will just return the API version that was registered first. Fix this.
|
||||
if v, k, err := RESTMapper.VersionAndKindForResource("replicationControllers"); err != nil || v != "v1beta1" || k != "ReplicationController" {
|
||||
t.Errorf("unexpected version mapping: %s %s %v", v, k, err)
|
||||
}
|
||||
if v, k, err := RESTMapper.VersionAndKindForResource("replicationcontrollers"); err != nil || v != Version || k != "ReplicationController" {
|
||||
if v, k, err := RESTMapper.VersionAndKindForResource("replicationcontrollers"); err != nil || v != "v1beta1" || k != "ReplicationController" {
|
||||
t.Errorf("unexpected version mapping: %s %s %v", v, k, err)
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user