Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
3a95681a
X
Xts Acts
项目概览
OpenHarmony
/
Xts Acts
1 年多 前同步成功
通知
9
Star
22
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
X
Xts Acts
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
3a95681a
编写于
11月 01, 2022
作者:
W
wu
1
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
modify request direction for API test
Signed-off-by:
N
wu
<
wuzhimin8@huawei.com
>
上级
01f45a01
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
20 addition
and
20 deletion
+20
-20
usb/usb_standard/src/main/js/test/UsbDevicePipeJsunit.test.js
...usb_standard/src/main/js/test/UsbDevicePipeJsunit.test.js
+10
-10
usb/usb_standard/src/main/js/test/UsbDevicePipeJsunitEx.test.js
...b_standard/src/main/js/test/UsbDevicePipeJsunitEx.test.js
+1
-1
usb/usb_standard/src/main/js/test/UsbDevicePipeJsunit_A.test.js
...b_standard/src/main/js/test/UsbDevicePipeJsunit_A.test.js
+9
-9
未找到文件。
usb/usb_standard/src/main/js/test/UsbDevicePipeJsunit.test.js
浏览文件 @
3a95681a
...
...
@@ -77,7 +77,7 @@ describe('UsbDevicePipeJsFunctionsTest', function () {
if
(
endpoint
.
direction
==
usb
.
USB_REQUEST_DIR_TO_DEVICE
)
{
testParam
.
maxOutSize
=
endpoint
.
maxPacketSize
;
testParam
.
outEndpoint
=
endpoint
;
}
else
if
(
endpoint
.
direction
==
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
<<
7
)
)
{
}
else
if
(
endpoint
.
direction
==
usb
.
USB_REQUEST_DIR_FROM_DEVICE
)
{
testParam
.
maxInSize
=
endpoint
.
maxPacketSize
;
testParam
.
inEndpoint
=
endpoint
}
...
...
@@ -437,7 +437,7 @@ describe('UsbDevicePipeJsFunctionsTest', function () {
}
var
timeout
=
5000
;
var
controlParam
=
getTransferParam
(
6
,
usb
.
USB_REQUEST_TARGET_DEVICE
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
<<
7
)
var
controlParam
=
getTransferParam
(
6
,
usb
.
USB_REQUEST_TARGET_DEVICE
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
)
|
(
usb
.
USB_REQUEST_TYPE_STANDARD
<<
5
)
|
(
usb
.
USB_REQUEST_TARGET_DEVICE
&
0x1f
),
(
2
<<
8
),
0
)
callControlTransfer
(
testParam
.
pip
,
controlParam
,
timeout
,
'
SUB_USB_JS_0540 GetDescriptor
'
)
})
...
...
@@ -461,7 +461,7 @@ describe('UsbDevicePipeJsFunctionsTest', function () {
}
var
timeout
=
5000
;
var
controlParam
=
getTransferParam
(
0
,
usb
.
USB_REQUEST_TARGET_DEVICE
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
<<
7
)
var
controlParam
=
getTransferParam
(
0
,
usb
.
USB_REQUEST_TARGET_DEVICE
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
)
|
(
usb
.
USB_REQUEST_TYPE_STANDARD
<<
5
)
|
(
usb
.
USB_REQUEST_TARGET_DEVICE
&
0x1f
),
0
,
0
)
callControlTransfer
(
testParam
.
pip
,
controlParam
,
timeout
,
'
SUB_USB_JS_0550 GetStatus
'
)
})
...
...
@@ -485,7 +485,7 @@ describe('UsbDevicePipeJsFunctionsTest', function () {
}
var
timeout
=
5000
;
var
controlParam
=
getTransferParam
(
8
,
usb
.
USB_REQUEST_TARGET_DEVICE
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
<<
7
)
var
controlParam
=
getTransferParam
(
8
,
usb
.
USB_REQUEST_TARGET_DEVICE
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
)
|
(
usb
.
USB_REQUEST_TYPE_STANDARD
<<
5
)
|
(
usb
.
USB_REQUEST_TARGET_DEVICE
&
0x1f
),
0
,
0
)
callControlTransfer
(
testParam
.
pip
,
controlParam
,
timeout
,
'
SUB_USB_JS_0560 GetConfiguration
'
)
})
...
...
@@ -509,7 +509,7 @@ describe('UsbDevicePipeJsFunctionsTest', function () {
}
var
timeout
=
5000
;
var
controlParam
=
getTransferParam
(
10
,
usb
.
USB_REQUEST_TARGET_INTERFACE
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
<<
7
)
var
controlParam
=
getTransferParam
(
10
,
usb
.
USB_REQUEST_TARGET_INTERFACE
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
)
|
(
usb
.
USB_REQUEST_TYPE_STANDARD
<<
5
)
|
(
usb
.
USB_REQUEST_TARGET_INTERFACE
&
0x1f
),
0
,
1
)
callControlTransfer
(
testParam
.
pip
,
controlParam
,
timeout
,
'
SUB_USB_JS_0570 GetInterface
'
)
})
...
...
@@ -533,7 +533,7 @@ describe('UsbDevicePipeJsFunctionsTest', function () {
}
var
timeout
=
5000
;
var
controlParam
=
getTransferParam
(
1
,
usb
.
USB_REQUEST_TARGET_DEVICE
,
(
usb
.
USB_REQUEST_DIR_TO_DEVICE
<<
7
)
var
controlParam
=
getTransferParam
(
1
,
usb
.
USB_REQUEST_TARGET_DEVICE
,
(
usb
.
USB_REQUEST_DIR_TO_DEVICE
)
|
(
usb
.
USB_REQUEST_TYPE_STANDARD
<<
5
)
|
(
usb
.
USB_REQUEST_TARGET_DEVICE
&
0x1f
),
0
,
0
)
callControlTransfer
(
testParam
.
pip
,
controlParam
,
timeout
,
'
SUB_USB_JS_0580 ClearFeature
'
)
})
...
...
@@ -557,7 +557,7 @@ describe('UsbDevicePipeJsFunctionsTest', function () {
}
var
timeout
=
5000
;
var
controlParam
=
getTransferParam
(
255
,
usb
.
USB_REQUEST_TARGET_INTERFACE
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
<<
7
)
var
controlParam
=
getTransferParam
(
255
,
usb
.
USB_REQUEST_TARGET_INTERFACE
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
)
|
(
usb
.
USB_REQUEST_TYPE_STANDARD
<<
5
)
|
(
usb
.
USB_REQUEST_TARGET_INTERFACE
&
0x1f
),
(
2
<<
8
),
0
)
callControlTransfer
(
testParam
.
pip
,
controlParam
,
timeout
,
'
SUB_USB_JS_0590 ClearFeature
'
)
})
...
...
@@ -581,7 +581,7 @@ describe('UsbDevicePipeJsFunctionsTest', function () {
}
var
timeout
=
5000
;
var
controlParam
=
getTransferParam
(
255
,
usb
.
USB_REQUEST_TARGET_ENDPOINT
,
(
usb
.
USB_REQUEST_DIR_TO_DEVICE
<<
7
)
var
controlParam
=
getTransferParam
(
255
,
usb
.
USB_REQUEST_TARGET_ENDPOINT
,
(
usb
.
USB_REQUEST_DIR_TO_DEVICE
)
|
(
usb
.
USB_REQUEST_TYPE_CLASS
<<
5
)
|
(
usb
.
USB_REQUEST_TARGET_ENDPOINT
&
0x1f
),
(
2
<<
8
),
0
)
callControlTransfer
(
testParam
.
pip
,
controlParam
,
timeout
,
'
SUB_USB_JS_0600 ClearFeature
'
)
})
...
...
@@ -605,7 +605,7 @@ describe('UsbDevicePipeJsFunctionsTest', function () {
}
var
timeout
=
5000
;
var
controlParam
=
getTransferParam
(
255
,
usb
.
USB_REQUEST_TARGET_OTHER
,
(
usb
.
USB_REQUEST_DIR_TO_DEVICE
<<
7
)
var
controlParam
=
getTransferParam
(
255
,
usb
.
USB_REQUEST_TARGET_OTHER
,
(
usb
.
USB_REQUEST_DIR_TO_DEVICE
)
|
(
usb
.
USB_REQUEST_TYPE_VENDOR
<<
5
)
|
(
usb
.
USB_REQUEST_TARGET_OTHER
&
0x1f
),
(
2
<<
8
),
0
)
callControlTransfer
(
testParam
.
pip
,
controlParam
,
timeout
,
'
SUB_USB_JS_0610 ClearFeature
'
)
})
...
...
@@ -629,7 +629,7 @@ describe('UsbDevicePipeJsFunctionsTest', function () {
}
var
timeout
=
5000
;
var
controlParam
=
getTransferParam
(
255
,
usb
.
USB_REQUEST_TARGET_OTHER
,
(
usb
.
USB_REQUEST_DIR_TO_DEVICE
<<
7
)
var
controlParam
=
getTransferParam
(
255
,
usb
.
USB_REQUEST_TARGET_OTHER
,
(
usb
.
USB_REQUEST_DIR_TO_DEVICE
)
|
(
usb
.
USB_REQUEST_TYPE_CLASS
<<
5
)
|
(
usb
.
USB_REQUEST_TARGET_OTHER
&
0x1f
),
0
,
0
)
callControlTransfer
(
testParam
.
pip
,
controlParam
,
timeout
,
'
SUB_USB_JS_0620 ClearFeature
'
)
})
...
...
usb/usb_standard/src/main/js/test/UsbDevicePipeJsunitEx.test.js
浏览文件 @
3a95681a
...
...
@@ -77,7 +77,7 @@ describe('UsbDevicePipeJsFunctionsTestEx', function () {
if
(
endpoint
.
direction
==
usb
.
USB_REQUEST_DIR_TO_DEVICE
)
{
testParam
.
outEndpoint
=
endpoint
;
testParam
.
maxOutSize
=
endpoint
.
maxPacketSize
;
}
else
if
(
endpoint
.
direction
==
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
<<
7
)
)
{
}
else
if
(
endpoint
.
direction
==
usb
.
USB_REQUEST_DIR_FROM_DEVICE
)
{
testParam
.
inEndpoint
=
endpoint
testParam
.
maxInSize
=
endpoint
.
maxPacketSize
;
}
...
...
usb/usb_standard/src/main/js/test/UsbDevicePipeJsunit_A.test.js
浏览文件 @
3a95681a
...
...
@@ -452,7 +452,7 @@ describe('UsbDevicePipeJsFunctionsTestA', function () {
}
var
timeout
=
5000
;
var
controlParam
=
getTransferParam
(
6
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
<<
7
)
var
controlParam
=
getTransferParam
(
6
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
)
|
(
usb
.
USB_REQUEST_TYPE_STANDARD
<<
5
)
|
(
usb
.
USB_REQUEST_TARGET_DEVICE
&
0x1f
),
(
2
<<
8
),
0
)
callControlTransfer
(
testParam
.
pip
,
controlParam
,
timeout
,
'
SUB_USB_JS_0540 GetDescriptor
'
)
})
...
...
@@ -476,7 +476,7 @@ describe('UsbDevicePipeJsFunctionsTestA', function () {
}
var
timeout
=
5000
;
var
controlParam
=
getTransferParam
(
0
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
<<
7
)
var
controlParam
=
getTransferParam
(
0
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
)
|
(
usb
.
USB_REQUEST_TYPE_STANDARD
<<
5
)
|
(
usb
.
USB_REQUEST_TARGET_DEVICE
&
0x1f
),
0
,
0
)
callControlTransfer
(
testParam
.
pip
,
controlParam
,
timeout
,
'
SUB_USB_JS_0550 GetStatus
'
)
})
...
...
@@ -500,7 +500,7 @@ describe('UsbDevicePipeJsFunctionsTestA', function () {
}
var
timeout
=
5000
;
var
controlParam
=
getTransferParam
(
8
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
<<
7
)
var
controlParam
=
getTransferParam
(
8
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
)
|
(
usb
.
USB_REQUEST_TYPE_STANDARD
<<
5
)
|
(
usb
.
USB_REQUEST_TARGET_DEVICE
&
0x1f
),
0
,
0
)
callControlTransfer
(
testParam
.
pip
,
controlParam
,
timeout
,
'
SUB_USB_JS_0560 GetConfiguration
'
)
})
...
...
@@ -524,7 +524,7 @@ describe('UsbDevicePipeJsFunctionsTestA', function () {
}
var
timeout
=
5000
;
var
controlParam
=
getTransferParam
(
10
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
<<
7
)
var
controlParam
=
getTransferParam
(
10
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
)
|
(
usb
.
USB_REQUEST_TYPE_STANDARD
<<
5
)
|
(
usb
.
USB_REQUEST_TARGET_INTERFACE
&
0x1f
),
0
,
1
)
callControlTransfer
(
testParam
.
pip
,
controlParam
,
timeout
,
'
SUB_USB_JS_0570 GetInterface
'
)
})
...
...
@@ -548,7 +548,7 @@ describe('UsbDevicePipeJsFunctionsTestA', function () {
}
var
timeout
=
5000
;
var
controlParam
=
getTransferParam
(
1
,
(
usb
.
USB_REQUEST_DIR_TO_DEVICE
<<
7
)
var
controlParam
=
getTransferParam
(
1
,
(
usb
.
USB_REQUEST_DIR_TO_DEVICE
)
|
(
usb
.
USB_REQUEST_TYPE_STANDARD
<<
5
)
|
(
usb
.
USB_REQUEST_TARGET_DEVICE
&
0x1f
),
0
,
0
)
callControlTransfer
(
testParam
.
pip
,
controlParam
,
timeout
,
'
SUB_USB_JS_0580 ClearFeature
'
)
})
...
...
@@ -572,7 +572,7 @@ describe('UsbDevicePipeJsFunctionsTestA', function () {
}
var
timeout
=
5000
;
var
controlParam
=
getTransferParam
(
255
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
<<
7
)
var
controlParam
=
getTransferParam
(
255
,
(
usb
.
USB_REQUEST_DIR_FROM_DEVICE
)
|
(
usb
.
USB_REQUEST_TYPE_STANDARD
<<
5
)
|
(
usb
.
USB_REQUEST_TARGET_INTERFACE
&
0x1f
),
(
2
<<
8
),
0
)
callControlTransfer
(
testParam
.
pip
,
controlParam
,
timeout
,
'
SUB_USB_JS_0590 ClearFeature
'
)
})
...
...
@@ -596,7 +596,7 @@ describe('UsbDevicePipeJsFunctionsTestA', function () {
}
var
timeout
=
5000
;
var
controlParam
=
getTransferParam
(
255
,
(
usb
.
USB_REQUEST_DIR_TO_DEVICE
<<
7
)
var
controlParam
=
getTransferParam
(
255
,
(
usb
.
USB_REQUEST_DIR_TO_DEVICE
)
|
(
usb
.
USB_REQUEST_TYPE_CLASS
<<
5
)
|
(
usb
.
USB_REQUEST_TARGET_ENDPOINT
&
0x1f
),
(
2
<<
8
),
0
)
callControlTransfer
(
testParam
.
pip
,
controlParam
,
timeout
,
'
SUB_USB_JS_0600 ClearFeature
'
)
})
...
...
@@ -620,7 +620,7 @@ describe('UsbDevicePipeJsFunctionsTestA', function () {
}
var
timeout
=
5000
;
var
controlParam
=
getTransferParam
(
255
,
(
usb
.
USB_REQUEST_DIR_TO_DEVICE
<<
7
)
var
controlParam
=
getTransferParam
(
255
,
(
usb
.
USB_REQUEST_DIR_TO_DEVICE
)
|
(
usb
.
USB_REQUEST_TYPE_VENDOR
<<
5
)
|
(
usb
.
USB_REQUEST_TARGET_OTHER
&
0x1f
),
(
2
<<
8
),
0
)
callControlTransfer
(
testParam
.
pip
,
controlParam
,
timeout
,
'
SUB_USB_JS_0610 ClearFeature
'
)
})
...
...
@@ -644,7 +644,7 @@ describe('UsbDevicePipeJsFunctionsTestA', function () {
}
var
timeout
=
5000
;
var
controlParam
=
getTransferParam
(
255
,
(
usb
.
USB_REQUEST_DIR_TO_DEVICE
<<
7
)
var
controlParam
=
getTransferParam
(
255
,
(
usb
.
USB_REQUEST_DIR_TO_DEVICE
)
|
(
usb
.
USB_REQUEST_TYPE_CLASS
<<
5
)
|
(
usb
.
USB_REQUEST_TARGET_OTHER
&
0x1f
),
0
,
0
)
callControlTransfer
(
testParam
.
pip
,
controlParam
,
timeout
,
'
SUB_USB_JS_0620 ClearFeature
'
)
})
...
...
鸿蒙社区
@harmonycommunity
mentioned in commit
5b9ae5a7
·
11月 04, 2022
mentioned in commit
5b9ae5a7
mentioned in commit 5b9ae5a7086a41d96baf0a75b521bdeb32706381
开关提交列表
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录