From 0fa76302bc7df041d5346708c1f4935b49b01307 Mon Sep 17 00:00:00 2001 From: zhouke Date: Tue, 7 Mar 2023 14:17:52 +0800 Subject: [PATCH] =?UTF-8?q?js-apis-uitest.md=20=E4=BF=AE=E6=94=B9.Signed-o?= =?UTF-8?q?ff-by:=20.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: zhouke --- .../reference/apis/js-apis-UiTest.md | 30 +++++++++---------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/zh-cn/application-dev/reference/apis/js-apis-UiTest.md b/zh-cn/application-dev/reference/apis/js-apis-UiTest.md index f04ccc898c..97ec1fc917 100644 --- a/zh-cn/application-dev/reference/apis/js-apis-UiTest.md +++ b/zh-cn/application-dev/reference/apis/js-apis-UiTest.md @@ -1,4 +1,4 @@ -# @ohos.UiTest (UiTest) +# @ohos.UiTest UiTest提供模拟UI操作的能力,供开发者在测试场景使用,主要支持如点击、双击、长按、滑动等UI操作能力。 @@ -20,7 +20,7 @@ UiTest提供模拟UI操作的能力,供开发者在测试场景使用,主要 ## 导入模块 ```js -import {UiComponent, UiDriver, Component, Driver, UiWindow, ON, BY, MatchPattern, DisplayRotation, ResizeDirection, WindowMode, PointerMatrix} from '@ohos.uitest'; +import {UiComponent, UiDriver, Component, Driver, UiWindow, ON, BY, MatchPattern, DisplayRotation, ResizeDirection, WindowMode, PointerMatrix} from '@ohos.UiTest'; ``` ## MatchPattern @@ -2093,7 +2093,7 @@ fling(from: Point, to: Point, stepLen: number, speed: number): Promise\ ```js async function demo() { let driver = Driver.create(); - await driver.fling({X: 500, Y: 480},{X: 450, Y: 480},5,600); + await driver.fling({x: 500, Y: 480},{x: 450, Y: 480},5,600); } ``` @@ -2132,12 +2132,12 @@ injectMultiPointerAction(pointers: PointerMatrix, speed?: number): Promise\