PlaybackSettings.DelayBetweenActions 속성

동작 간 지연 시간(밀리초)을 가져오거나 설정합니다.

네임스페이스:  Microsoft.VisualStudio.TestTools.UITesting
어셈블리:  Microsoft.VisualStudio.TestTools.UITesting(Microsoft.VisualStudio.TestTools.UITesting.dll)

구문

‘선언
Public Property DelayBetweenActions As Integer
    Get
    Set
public int DelayBetweenActions { get; set; }
public:
property int DelayBetweenActions {
    int get ();
    void set (int value);
}
member DelayBetweenActions : int with get, set
function get DelayBetweenActions () : int
function set DelayBetweenActions (value : int)

속성 값

형식: System.Int32
동작 간 지연 시간(밀리초)입니다.

예제

public void ModifiedSimpleAppTest()
        {
            #region Variable Declarations
            WpfButton uIStartButton = this.UIMainWindowWindow.UIStartButton;
            WpfCheckBox uICheckBoxCheckBox = this.UIMainWindowWindow.UICheckBoxCheckBox;
            WpfButton uICloseButton = this.UIMainWindowWindow.UIMainWindowTitleBar.UICloseButton;
            #endregion

            // Launch '%VisualStudioDir%\Projects\AddTwoNumbers\AddTwoNumbers\bin\Debug\AddTwoNumbers.exe'
            ApplicationUnderTest uIMainWindowWindow = ApplicationUnderTest.Launch(this.SimpleAppTestParams.UIMainWindowWindowExePath, this.SimpleAppTestParams.UIMainWindowWindowAlternateExePath);

            // Set delay between actions to 1 second. Add this code before any mouse, keyboard and SetProperty actions.
            Playback.PlaybackSettings.DelayBetweenActions = 1000;

            // Click 'Start' button
            Mouse.Click(uIStartButton, new Point(27, 10));

            uICheckBoxCheckBox.WaitForControlEnabled();
            
            // Select 'CheckBox' check box
            uICheckBoxCheckBox.Checked = this.SimpleAppTestParams.UICheckBoxCheckBoxChecked;

            // Click 'Close' button
            Mouse.Click(uICloseButton, new Point(15, 10));
        }

.NET Framework 보안

  • 직접 실행 호출자의 경우 완전히 신뢰합니다. 이 멤버는 부분적으로 신뢰할 수 있는 코드에서 사용할 수 없습니다. 자세한 내용은 부분 신뢰 코드에서 라이브러리 사용을 참조하십시오.

참고 항목

참조

PlaybackSettings 클래스

Microsoft.VisualStudio.TestTools.UITesting 네임스페이스