Correctly do swagger validation with experimental.
Before we tried both groups, first api then experimental. If experimental failed, the error message would be discarded and the message for api would be shown. This commit changes this behavior so that we detect which api group we should be using and only show the error for that group.
This commit is contained in:
@@ -140,16 +140,18 @@ func startMasterOrDie(masterConfig *master.Config) (*master.Master, *httptest.Se
|
||||
}
|
||||
|
||||
masterConfig = &master.Config{
|
||||
DatabaseStorage: etcdStorage,
|
||||
ExpDatabaseStorage: expEtcdStorage,
|
||||
KubeletClient: client.FakeKubeletClient{},
|
||||
EnableLogsSupport: false,
|
||||
EnableProfiling: true,
|
||||
EnableUISupport: false,
|
||||
APIPrefix: "/api",
|
||||
APIGroupPrefix: "/apis",
|
||||
Authorizer: apiserver.NewAlwaysAllowAuthorizer(),
|
||||
AdmissionControl: admit.NewAlwaysAdmit(),
|
||||
DatabaseStorage: etcdStorage,
|
||||
ExpDatabaseStorage: expEtcdStorage,
|
||||
KubeletClient: client.FakeKubeletClient{},
|
||||
EnableExp: true,
|
||||
EnableLogsSupport: false,
|
||||
EnableProfiling: true,
|
||||
EnableSwaggerSupport: true,
|
||||
EnableUISupport: false,
|
||||
APIPrefix: "/api",
|
||||
APIGroupPrefix: "/apis",
|
||||
Authorizer: apiserver.NewAlwaysAllowAuthorizer(),
|
||||
AdmissionControl: admit.NewAlwaysAdmit(),
|
||||
}
|
||||
} else {
|
||||
etcdStorage = masterConfig.DatabaseStorage
|
||||
|
Reference in New Issue
Block a user