Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
1e2763cb
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看板
提交
1e2763cb
编写于
1月 04, 2021
作者:
J
jiyong
提交者:
Gitee
1月 04, 2021
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
hal解耦
上级
51490f0b
变更
2
显示空白变更内容
内联
并排
Showing
2 changed file
with
19 addition
and
23 deletion
+19
-23
iot_hardware_lite/wifiiot_hal/src/wifiiot_gpio_func_test.c
iot_hardware_lite/wifiiot_hal/src/wifiiot_gpio_func_test.c
+17
-19
iot_hardware_lite/wifiiot_hal/src/wifiiot_sdio_func_test.c
iot_hardware_lite/wifiiot_hal/src/wifiiot_sdio_func_test.c
+2
-4
未找到文件。
iot_hardware_lite/wifiiot_hal/src/wifiiot_gpio_func_test.c
浏览文件 @
1e2763cb
...
...
@@ -18,8 +18,6 @@
#include <los_base.h>
#include <securec.h>
#include "hctest.h"
#include "hi_task.h"
#include "hi_time.h"
#include "samgr_lite.h"
#include "wifiiot_errno.h"
...
...
@@ -612,7 +610,7 @@ LITE_TEST_CASE(WifiIotGpioFuncTestSuite, testWifiIotGPIO020, LEVEL1)
void
IOT_IsrFunc
(
char
*
arg
)
{
int
gpioInNum
=
(
int
ptr_t
)
arg
;
int
gpioInNum
=
(
int
)
arg
;
unsigned
int
ret
=
GpioUnregisterIsrFunc
(
gpioInNum
);
TEST_ASSERT_EQUAL_INT
(
0
,
ret
);
printf
(
"GpioIsrFunc callback successfully
\n
"
);
...
...
@@ -638,7 +636,7 @@ LITE_TEST_CASE(WifiIotGpioFuncTestSuite, testWifiIotGPIO021, LEVEL1)
TEST_ASSERT_EQUAL_INT
(
0
,
ret
);
ret
=
GpioRegisterIsrFunc
(
gpioInNum
,
WIFI_IOT_INT_TYPE_LEVEL
,
WIFI_IOT_GPIO_EDGE_FALL_LEVEL_LOW
,
IOT_IsrFunc
,
(
char
*
)
(
intptr_t
)
gpioInNum
);
WIFI_IOT_GPIO_EDGE_FALL_LEVEL_LOW
,
IOT_IsrFunc
,
(
char
*
)
gpioInNum
);
if
(
!
(
ret
==
0
||
((
ret
>=
WIFI_IOT_ERR_GPIO_INVALID_PARAMETER
)
&&
(
ret
<=
WIFI_IOT_ERR_GPIO_NOT_SUPPORT
))))
{
TEST_FAIL
();
...
...
@@ -668,7 +666,7 @@ LITE_TEST_CASE(WifiIotGpioFuncTestSuite, testWifiIotGPIO022, LEVEL1)
TEST_ASSERT_EQUAL_INT
(
0
,
ret
);
ret
=
GpioRegisterIsrFunc
(
gpioInNum
,
WIFI_IOT_INT_TYPE_LEVEL
,
WIFI_IOT_GPIO_EDGE_FALL_LEVEL_LOW
,
IOT_IsrFunc
,
(
char
*
)
(
intptr_t
)
gpioInNum
);
WIFI_IOT_GPIO_EDGE_FALL_LEVEL_LOW
,
IOT_IsrFunc
,
(
char
*
)
gpioInNum
);
if
(
!
(
ret
==
0
||
((
ret
>=
WIFI_IOT_ERR_GPIO_INVALID_PARAMETER
)
&&
(
ret
<=
WIFI_IOT_ERR_GPIO_NOT_SUPPORT
))))
{
TEST_FAIL
();
...
...
@@ -698,7 +696,7 @@ LITE_TEST_CASE(WifiIotGpioFuncTestSuite, testWifiIotGPIO023, LEVEL1)
TEST_ASSERT_EQUAL_INT
(
0
,
ret
);
ret
=
GpioRegisterIsrFunc
(
gpioInNum
,
WIFI_IOT_INT_TYPE_LEVEL
,
WIFI_IOT_GPIO_EDGE_FALL_LEVEL_LOW
,
IOT_IsrFunc
,
(
char
*
)
(
intptr_t
)
gpioInNum
);
WIFI_IOT_GPIO_EDGE_FALL_LEVEL_LOW
,
IOT_IsrFunc
,
(
char
*
)
gpioInNum
);
if
(
!
(
ret
==
0
||
((
ret
>=
WIFI_IOT_ERR_GPIO_INVALID_PARAMETER
)
&&
(
ret
<=
WIFI_IOT_ERR_GPIO_NOT_SUPPORT
))))
{
TEST_FAIL
();
...
...
@@ -728,7 +726,7 @@ LITE_TEST_CASE(WifiIotGpioFuncTestSuite, testWifiIotGPIO024, LEVEL1)
TEST_ASSERT_EQUAL_INT
(
0
,
ret
);
ret
=
GpioRegisterIsrFunc
(
gpioInNum
,
WIFI_IOT_INT_TYPE_LEVEL
,
WIFI_IOT_GPIO_EDGE_FALL_LEVEL_LOW
,
IOT_IsrFunc
,
(
char
*
)
(
intptr_t
)
gpioInNum
);
WIFI_IOT_GPIO_EDGE_FALL_LEVEL_LOW
,
IOT_IsrFunc
,
(
char
*
)
gpioInNum
);
if
(
!
(
ret
==
0
||
((
ret
>=
WIFI_IOT_ERR_GPIO_INVALID_PARAMETER
)
&&
(
ret
<=
WIFI_IOT_ERR_GPIO_NOT_SUPPORT
))))
{
TEST_FAIL
();
...
...
@@ -761,7 +759,7 @@ LITE_TEST_CASE(WifiIotGpioFuncTestSuite, testWifiIotGPIO025, LEVEL1)
TEST_ASSERT_EQUAL_INT
(
0
,
ret
);
ret
=
GpioRegisterIsrFunc
(
gpioInNum
,
WIFI_IOT_INT_TYPE_LEVEL
,
WIFI_IOT_GPIO_EDGE_RISE_LEVEL_HIGH
,
IOT_IsrFunc
,
(
char
*
)
(
intptr_t
)
gpioInNum
);
WIFI_IOT_GPIO_EDGE_RISE_LEVEL_HIGH
,
IOT_IsrFunc
,
(
char
*
)
gpioInNum
);
if
(
!
(
ret
==
0
||
((
ret
>=
WIFI_IOT_ERR_GPIO_INVALID_PARAMETER
)
&&
(
ret
<=
WIFI_IOT_ERR_GPIO_NOT_SUPPORT
))))
{
TEST_FAIL
();
...
...
@@ -791,7 +789,7 @@ LITE_TEST_CASE(WifiIotGpioFuncTestSuite, testWifiIotGPIO026, LEVEL1)
TEST_ASSERT_EQUAL_INT
(
0
,
ret
);
ret
=
GpioRegisterIsrFunc
(
gpioInNum
,
WIFI_IOT_INT_TYPE_LEVEL
,
WIFI_IOT_GPIO_EDGE_RISE_LEVEL_HIGH
,
IOT_IsrFunc
,
(
char
*
)
(
intptr_t
)
gpioInNum
);
WIFI_IOT_GPIO_EDGE_RISE_LEVEL_HIGH
,
IOT_IsrFunc
,
(
char
*
)
gpioInNum
);
if
(
!
(
ret
==
0
||
((
ret
>=
WIFI_IOT_ERR_GPIO_INVALID_PARAMETER
)
&&
(
ret
<=
WIFI_IOT_ERR_GPIO_NOT_SUPPORT
))))
{
TEST_FAIL
();
...
...
@@ -821,7 +819,7 @@ LITE_TEST_CASE(WifiIotGpioFuncTestSuite, testWifiIotGPIO027, LEVEL1)
TEST_ASSERT_EQUAL_INT
(
0
,
ret
);
ret
=
GpioRegisterIsrFunc
(
gpioInNum
,
WIFI_IOT_INT_TYPE_LEVEL
,
WIFI_IOT_GPIO_EDGE_RISE_LEVEL_HIGH
,
IOT_IsrFunc
,
(
char
*
)
(
intptr_t
)
gpioInNum
);
WIFI_IOT_GPIO_EDGE_RISE_LEVEL_HIGH
,
IOT_IsrFunc
,
(
char
*
)
gpioInNum
);
if
(
!
(
ret
==
0
||
((
ret
>=
WIFI_IOT_ERR_GPIO_INVALID_PARAMETER
)
&&
(
ret
<=
WIFI_IOT_ERR_GPIO_NOT_SUPPORT
))))
{
TEST_FAIL
();
...
...
@@ -851,7 +849,7 @@ LITE_TEST_CASE(WifiIotGpioFuncTestSuite, testWifiIotGPIO028, LEVEL1)
TEST_ASSERT_EQUAL_INT
(
0
,
ret
);
ret
=
GpioRegisterIsrFunc
(
gpioInNum
,
WIFI_IOT_INT_TYPE_LEVEL
,
WIFI_IOT_GPIO_EDGE_RISE_LEVEL_HIGH
,
IOT_IsrFunc
,
(
char
*
)
(
intptr_t
)
gpioInNum
);
WIFI_IOT_GPIO_EDGE_RISE_LEVEL_HIGH
,
IOT_IsrFunc
,
(
char
*
)
gpioInNum
);
if
(
!
(
ret
==
0
||
((
ret
>=
WIFI_IOT_ERR_GPIO_INVALID_PARAMETER
)
&&
(
ret
<=
WIFI_IOT_ERR_GPIO_NOT_SUPPORT
))))
{
TEST_FAIL
();
...
...
@@ -884,7 +882,7 @@ LITE_TEST_CASE(WifiIotGpioFuncTestSuite, testWifiIotGPIO029, LEVEL1)
TEST_ASSERT_EQUAL_INT
(
0
,
ret
);
ret
=
GpioRegisterIsrFunc
(
gpioInNum
,
WIFI_IOT_INT_TYPE_EDGE
,
WIFI_IOT_GPIO_EDGE_FALL_LEVEL_LOW
,
IOT_IsrFunc
,
(
char
*
)
(
intptr_t
)
gpioInNum
);
WIFI_IOT_GPIO_EDGE_FALL_LEVEL_LOW
,
IOT_IsrFunc
,
(
char
*
)
gpioInNum
);
if
(
!
(
ret
==
0
||
((
ret
>=
WIFI_IOT_ERR_GPIO_INVALID_PARAMETER
)
&&
(
ret
<=
WIFI_IOT_ERR_GPIO_NOT_SUPPORT
))))
{
TEST_FAIL
();
...
...
@@ -914,7 +912,7 @@ LITE_TEST_CASE(WifiIotGpioFuncTestSuite, testWifiIotGPIO030, LEVEL1)
TEST_ASSERT_EQUAL_INT
(
0
,
ret
);
ret
=
GpioRegisterIsrFunc
(
gpioInNum
,
WIFI_IOT_INT_TYPE_EDGE
,
WIFI_IOT_GPIO_EDGE_FALL_LEVEL_LOW
,
IOT_IsrFunc
,
(
char
*
)
(
intptr_t
)
gpioInNum
);
WIFI_IOT_GPIO_EDGE_FALL_LEVEL_LOW
,
IOT_IsrFunc
,
(
char
*
)
gpioInNum
);
if
(
!
(
ret
==
0
||
((
ret
>=
WIFI_IOT_ERR_GPIO_INVALID_PARAMETER
)
&&
(
ret
<=
WIFI_IOT_ERR_GPIO_NOT_SUPPORT
))))
{
TEST_FAIL
();
...
...
@@ -944,7 +942,7 @@ LITE_TEST_CASE(WifiIotGpioFuncTestSuite, testWifiIotGPIO031, LEVEL1)
TEST_ASSERT_EQUAL_INT
(
0
,
ret
);
ret
=
GpioRegisterIsrFunc
(
gpioInNum
,
WIFI_IOT_INT_TYPE_EDGE
,
WIFI_IOT_GPIO_EDGE_FALL_LEVEL_LOW
,
IOT_IsrFunc
,
(
char
*
)
(
intptr_t
)
gpioInNum
);
WIFI_IOT_GPIO_EDGE_FALL_LEVEL_LOW
,
IOT_IsrFunc
,
(
char
*
)
gpioInNum
);
if
(
!
(
ret
==
0
||
((
ret
>=
WIFI_IOT_ERR_GPIO_INVALID_PARAMETER
)
&&
(
ret
<=
WIFI_IOT_ERR_GPIO_NOT_SUPPORT
))))
{
TEST_FAIL
();
...
...
@@ -974,7 +972,7 @@ LITE_TEST_CASE(WifiIotGpioFuncTestSuite, testWifiIotGPIO032, LEVEL1)
TEST_ASSERT_EQUAL_INT
(
0
,
ret
);
ret
=
GpioRegisterIsrFunc
(
gpioInNum
,
WIFI_IOT_INT_TYPE_EDGE
,
WIFI_IOT_GPIO_EDGE_FALL_LEVEL_LOW
,
IOT_IsrFunc
,
(
char
*
)
(
intptr_t
)
gpioInNum
);
WIFI_IOT_GPIO_EDGE_FALL_LEVEL_LOW
,
IOT_IsrFunc
,
(
char
*
)
gpioInNum
);
if
(
!
(
ret
==
0
||
((
ret
>=
WIFI_IOT_ERR_GPIO_INVALID_PARAMETER
)
&&
(
ret
<=
WIFI_IOT_ERR_GPIO_NOT_SUPPORT
))))
{
TEST_FAIL
();
...
...
@@ -1007,7 +1005,7 @@ LITE_TEST_CASE(WifiIotGpioFuncTestSuite, testWifiIotGPIO033, LEVEL1)
TEST_ASSERT_EQUAL_INT
(
0
,
ret
);
ret
=
GpioRegisterIsrFunc
(
gpioInNum
,
WIFI_IOT_INT_TYPE_EDGE
,
WIFI_IOT_GPIO_EDGE_RISE_LEVEL_HIGH
,
IOT_IsrFunc
,
(
char
*
)
(
intptr_t
)
gpioInNum
);
WIFI_IOT_GPIO_EDGE_RISE_LEVEL_HIGH
,
IOT_IsrFunc
,
(
char
*
)
gpioInNum
);
if
(
!
(
ret
==
0
||
((
ret
>=
WIFI_IOT_ERR_GPIO_INVALID_PARAMETER
)
&&
(
ret
<=
WIFI_IOT_ERR_GPIO_NOT_SUPPORT
))))
{
TEST_FAIL
();
...
...
@@ -1037,7 +1035,7 @@ LITE_TEST_CASE(WifiIotGpioFuncTestSuite, testWifiIotGPIO034, LEVEL1)
TEST_ASSERT_EQUAL_INT
(
0
,
ret
);
ret
=
GpioRegisterIsrFunc
(
gpioInNum
,
WIFI_IOT_INT_TYPE_EDGE
,
WIFI_IOT_GPIO_EDGE_RISE_LEVEL_HIGH
,
IOT_IsrFunc
,
(
char
*
)
(
intptr_t
)
gpioInNum
);
WIFI_IOT_GPIO_EDGE_RISE_LEVEL_HIGH
,
IOT_IsrFunc
,
(
char
*
)
gpioInNum
);
if
(
!
(
ret
==
0
||
((
ret
>=
WIFI_IOT_ERR_GPIO_INVALID_PARAMETER
)
&&
(
ret
<=
WIFI_IOT_ERR_GPIO_NOT_SUPPORT
))))
{
TEST_FAIL
();
...
...
@@ -1067,7 +1065,7 @@ LITE_TEST_CASE(WifiIotGpioFuncTestSuite, testWifiIotGPIO035, LEVEL1)
TEST_ASSERT_EQUAL_INT
(
0
,
ret
);
ret
=
GpioRegisterIsrFunc
(
gpioInNum
,
WIFI_IOT_INT_TYPE_EDGE
,
WIFI_IOT_GPIO_EDGE_RISE_LEVEL_HIGH
,
IOT_IsrFunc
,
(
char
*
)
(
intptr_t
)
gpioInNum
);
WIFI_IOT_GPIO_EDGE_RISE_LEVEL_HIGH
,
IOT_IsrFunc
,
(
char
*
)
gpioInNum
);
if
(
!
(
ret
==
0
||
((
ret
>=
WIFI_IOT_ERR_GPIO_INVALID_PARAMETER
)
&&
(
ret
<=
WIFI_IOT_ERR_GPIO_NOT_SUPPORT
))))
{
TEST_FAIL
();
...
...
@@ -1097,7 +1095,7 @@ LITE_TEST_CASE(WifiIotGpioFuncTestSuite, testWifiIotGPIO036, LEVEL1)
TEST_ASSERT_EQUAL_INT
(
0
,
ret
);
ret
=
GpioRegisterIsrFunc
(
gpioInNum
,
WIFI_IOT_INT_TYPE_EDGE
,
WIFI_IOT_GPIO_EDGE_RISE_LEVEL_HIGH
,
IOT_IsrFunc
,
(
char
*
)
(
intptr_t
)
gpioInNum
);
WIFI_IOT_GPIO_EDGE_RISE_LEVEL_HIGH
,
IOT_IsrFunc
,
(
char
*
)
gpioInNum
);
if
(
!
(
ret
==
0
||
((
ret
>=
WIFI_IOT_ERR_GPIO_INVALID_PARAMETER
)
&&
(
ret
<=
WIFI_IOT_ERR_GPIO_NOT_SUPPORT
))))
{
TEST_FAIL
();
...
...
iot_hardware_lite/wifiiot_hal/src/wifiiot_sdio_func_test.c
浏览文件 @
1e2763cb
...
...
@@ -18,8 +18,6 @@
#include <los_base.h>
#include <securec.h>
#include "hctest.h"
#include "hi_task.h"
#include "hi_time.h"
#include "samgr_lite.h"
#include "wifiiot_errno.h"
...
...
@@ -269,7 +267,7 @@ LITE_TEST_CASE(WifiIotSdioFuncTestSuite, testWifiIotSdio004, LEVEL1)
extendInfo
.
xferCount
=
TEST_BYTE_NUM
;
extendInfo
.
creditInfo
=
1
;
extendInfo
.
creditIsvalid
=
1
;
extendInfo
.
commReg
[
WIFI_IOT_SDIO_EXTENDREG_COUNT
-
1
]
=
(
uintptr_t
)
"CommonRegister"
;
extendInfo
.
commReg
[
WIFI_IOT_SDIO_EXTENDREG_COUNT
-
1
]
=
1
;
extendInfo
.
commregIsvalid
=
1
;
extendInfo
.
validCommregCnt
=
TEST_REG_NUM
;
...
...
@@ -328,7 +326,7 @@ LITE_TEST_CASE(WifiIotSdioFuncTestSuite, testWifiIotSdio005, LEVEL1)
extendInfo
.
xferCount
=
TEST_BYTE_NUM
;
extendInfo
.
creditInfo
=
1
;
extendInfo
.
creditIsvalid
=
1
;
extendInfo
.
commReg
[
WIFI_IOT_SDIO_EXTENDREG_COUNT
-
1
]
=
(
uintptr_t
)
"CommonRegister"
;
extendInfo
.
commReg
[
WIFI_IOT_SDIO_EXTENDREG_COUNT
-
1
]
=
1
;
extendInfo
.
commregIsvalid
=
1
;
extendInfo
.
validCommregCnt
=
TEST_REG_NUM
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录