var statusOk …
func statusOkWithOverrides(overrides ...autoscalingv2.HorizontalPodAutoscalerCondition) []autoscalingv2.HorizontalPodAutoscalerCondition { … }
func alwaysReady() bool { … }
type fakeResource …
type testCase …
func (tc *testCase) computeCPUCurrent() { … }
func init() { … }
func (tc *testCase) prepareTestClient(t *testing.T) (*fake.Clientset, *metricsfake.Clientset, *cmfake.FakeCustomMetricsClient, *emfake.FakeExternalMetricsClient, *scalefake.FakeScaleClient) { … }
func findCpuUtilization(metricStatus []autoscalingv2.MetricStatus) (utilization *int32) { … }
func (tc *testCase) verifyResults(t *testing.T, m *mockMonitor) { … }
func (tc *testCase) verifyRecordedMetric(t *testing.T, m *mockMonitor) { … }
func (tc *testCase) setupController(t *testing.T) (*HorizontalController, informers.SharedInformerFactory) { … }
func hotCPUCreationTime() metav1.Time { … }
func coolCPUCreationTime() metav1.Time { … }
func (tc *testCase) runTestWithController(t *testing.T, hpaController *HorizontalController, informerFactory informers.SharedInformerFactory) { … }
func (tc *testCase) runTest(t *testing.T) { … }
type mockMonitor …
func newMockMonitor() *mockMonitor { … }
func (m *mockMonitor) ObserveReconciliationResult(action monitor.ActionLabel, err monitor.ErrorLabel, _ time.Duration) { … }
func (m *mockMonitor) ObserveMetricComputationResult(action monitor.ActionLabel, err monitor.ErrorLabel, duration time.Duration, metricType autoscalingv2.MetricSourceType) { … }
func (m *mockMonitor) waitUntilRecorded(t *testing.T) { … }
func TestScaleUp(t *testing.T) { … }
func TestScaleUpContainer(t *testing.T) { … }
func TestScaleUpUnreadyLessScale(t *testing.T) { … }
func TestScaleUpHotCpuLessScale(t *testing.T) { … }
func TestScaleUpUnreadyNoScale(t *testing.T) { … }
func TestScaleUpHotCpuNoScale(t *testing.T) { … }
func TestScaleUpIgnoresFailedPods(t *testing.T) { … }
func TestScaleUpIgnoresDeletionPods(t *testing.T) { … }
func TestScaleUpDeployment(t *testing.T) { … }
func TestScaleUpReplicaSet(t *testing.T) { … }
func TestScaleUpCM(t *testing.T) { … }
func TestScaleUpCMUnreadyAndHotCpuNoLessScale(t *testing.T) { … }
func TestScaleUpCMUnreadyandCpuHot(t *testing.T) { … }
func TestScaleUpHotCpuNoScaleWouldScaleDown(t *testing.T) { … }
func TestScaleUpCMObject(t *testing.T) { … }
func TestScaleUpFromZeroCMObject(t *testing.T) { … }
func TestScaleUpFromZeroIgnoresToleranceCMObject(t *testing.T) { … }
func TestScaleUpPerPodCMObject(t *testing.T) { … }
func TestScaleUpCMExternal(t *testing.T) { … }
func TestScaleUpPerPodCMExternal(t *testing.T) { … }
func TestScaleDown(t *testing.T) { … }
func TestScaleDownContainerResource(t *testing.T) { … }
func TestScaleDownWithScalingRules(t *testing.T) { … }
func TestScaleUpOneMetricInvalid(t *testing.T) { … }
func TestScaleUpFromZeroOneMetricInvalid(t *testing.T) { … }
func TestScaleUpBothMetricsEmpty(t *testing.T) { … }
func TestScaleDownStabilizeInitialSize(t *testing.T) { … }
func TestScaleDownCM(t *testing.T) { … }
func TestScaleDownCMObject(t *testing.T) { … }
func TestScaleDownToZeroCMObject(t *testing.T) { … }
func TestScaleDownPerPodCMObject(t *testing.T) { … }
func TestScaleDownCMExternal(t *testing.T) { … }
func TestScaleDownToZeroCMExternal(t *testing.T) { … }
func TestScaleDownPerPodCMExternal(t *testing.T) { … }
func TestScaleDownIncludeUnreadyPods(t *testing.T) { … }
func TestScaleDownIgnoreHotCpuPods(t *testing.T) { … }
func TestScaleDownIgnoresFailedPods(t *testing.T) { … }
func TestScaleDownIgnoresDeletionPods(t *testing.T) { … }
func TestTolerance(t *testing.T) { … }
func TestToleranceCM(t *testing.T) { … }
func TestToleranceCMObject(t *testing.T) { … }
func TestToleranceCMExternal(t *testing.T) { … }
func TestTolerancePerPodCMObject(t *testing.T) { … }
func TestTolerancePerPodCMExternal(t *testing.T) { … }
func TestMinReplicas(t *testing.T) { … }
func TestZeroMinReplicasDesiredZero(t *testing.T) { … }
func TestMinReplicasDesiredZero(t *testing.T) { … }
func TestZeroReplicas(t *testing.T) { … }
func TestTooFewReplicas(t *testing.T) { … }
func TestTooManyReplicas(t *testing.T) { … }
func TestMaxReplicas(t *testing.T) { … }
func TestSuperfluousMetrics(t *testing.T) { … }
func TestMissingMetrics(t *testing.T) { … }
func TestEmptyMetrics(t *testing.T) { … }
func TestEmptyCPURequest(t *testing.T) { … }
func TestEventCreated(t *testing.T) { … }
func TestEventNotCreated(t *testing.T) { … }
func TestMissingReports(t *testing.T) { … }
func TestUpscaleCap(t *testing.T) { … }
func TestUpscaleCapGreaterThanMaxReplicas(t *testing.T) { … }
func TestMoreReplicasThanSpecNoScale(t *testing.T) { … }
func TestConditionInvalidSelectorMissing(t *testing.T) { … }
func TestConditionInvalidSelectorUnparsable(t *testing.T) { … }
func TestConditionNoAmbiguousSelectorWhenNoSelectorOverlapBetweenHPAs(t *testing.T) { … }
func TestConditionAmbiguousSelectorWhenFullSelectorOverlapBetweenHPAs(t *testing.T) { … }
func TestConditionAmbiguousSelectorWhenPartialSelectorOverlapBetweenHPAs(t *testing.T) { … }
func TestConditionFailedGetMetrics(t *testing.T) { … }
func TestConditionInvalidSourceType(t *testing.T) { … }
func TestConditionFailedGetScale(t *testing.T) { … }
func TestConditionFailedUpdateScale(t *testing.T) { … }
func TestNoBackoffUpscaleCM(t *testing.T) { … }
func TestNoBackoffUpscaleCMNoBackoffCpu(t *testing.T) { … }
func TestStabilizeDownscale(t *testing.T) { … }
func TestComputedToleranceAlgImplementation(t *testing.T) { … }
func TestScaleUpRCImmediately(t *testing.T) { … }
func TestScaleDownRCImmediately(t *testing.T) { … }
func TestAvoidUnnecessaryUpdates(t *testing.T) { … }
func TestConvertDesiredReplicasWithRules(t *testing.T) { … }
func TestCalculateScaleUpLimitWithScalingRules(t *testing.T) { … }
func TestCalculateScaleDownLimitWithBehaviors(t *testing.T) { … }
func generateScalingRules(pods, podsPeriod, percent, percentPeriod, stabilizationWindow int32) *autoscalingv2.HPAScalingRules { … }
func generateEventsUniformDistribution(rawEvents []int, periodSeconds int) []timestampedScaleEvent { … }
func TestNormalizeDesiredReplicas(t *testing.T) { … }
func TestScalingWithRules(t *testing.T) { … }
func TestStoreScaleEvents(t *testing.T) { … }
func TestNormalizeDesiredReplicasWithBehavior(t *testing.T) { … }
func TestScaleUpOneMetricEmpty(t *testing.T) { … }
func TestNoScaleDownOneMetricInvalid(t *testing.T) { … }
func TestNoScaleDownOneMetricEmpty(t *testing.T) { … }
func TestMultipleHPAs(t *testing.T) { … }