DisableAutoScale() public static method

public static DisableAutoScale ( BatchController controller, BatchAccountContext context, string poolId ) : void
controller BatchController
context BatchAccountContext
poolId string
return void
示例#1
0
        public void TestEvaluateAutoScaleByPipeline()
        {
            BatchController     controller = BatchController.NewInstance;
            BatchAccountContext context    = null;

            controller.RunPsTestWorkflow(
                () => { return(new string[] { string.Format("Test-EvaluateAutoScale '{0}' '{1}' '1'", commonAccountName, testPoolId) }); },
                () =>
            {
                context = ScenarioTestHelpers.GetBatchAccountContextWithKeys(controller, commonAccountName);
                ScenarioTestHelpers.EnableAutoScale(controller, context, testPoolId);
                ScenarioTestHelpers.WaitForSteadyPoolAllocation(controller, context, testPoolId);
            },
                () =>
            {
                ScenarioTestHelpers.DisableAutoScale(controller, context, testPoolId);
            },
                TestUtilities.GetCallingClass(),
                TestUtilities.GetCurrentMethodName());
        }
示例#2
0
        public void TestEnableAutoScaleById()
        {
            BatchController     controller = BatchController.NewInstance;
            BatchAccountContext context    = null;

            controller.RunPsTestWorkflow(
                () => { return(new string[] { string.Format("Test-EnableAutoScale '{0}' '0'", testPoolId) }); },
                () =>
            {
                context = new ScenarioTestContext();
                ScenarioTestHelpers.WaitForSteadyPoolAllocation(controller, context, testPoolId);
                ScenarioTestHelpers.DisableAutoScale(controller, context, testPoolId);
                ScenarioTestHelpers.WaitForSteadyPoolAllocation(controller, context, testPoolId);
            },
                () =>
            {
                ScenarioTestHelpers.DisableAutoScale(controller, context, testPoolId);
            },
                TestUtilities.GetCallingClass(),
                TestUtilities.GetCurrentMethodName());
        }