Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
85badcbf
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看板
提交
85badcbf
编写于
10月 22, 2021
作者:
S
ssy
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Signed-off-by:shuisiyuan<shuisiyuan@huawei.com>
Signed-off-by:
N
ssy
<
shuisiyuan@huawei.com
>
上级
f711bc52
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
4 addition
and
7 deletion
+4
-7
communication_lite/wifiservice_hal/src/wifiservice_func_test.c
...nication_lite/wifiservice_hal/src/wifiservice_func_test.c
+4
-7
未找到文件。
communication_lite/wifiservice_hal/src/wifiservice_func_test.c
浏览文件 @
85badcbf
...
@@ -17,9 +17,6 @@
...
@@ -17,9 +17,6 @@
#include "ohos_types.h"
#include "ohos_types.h"
#include "wifi_device.h"
#include "wifi_device.h"
#include "wifi_hotspot.h"
#include "wifi_hotspot.h"
#include "lwip/netif.h"
#include "lwip/netifapi.h"
#include "lwip/ip4_addr.h"
#include "cmsis_os2.h"
#include "cmsis_os2.h"
#include <unistd.h>
#include <unistd.h>
...
@@ -188,7 +185,7 @@ static void WaitScanResult(void)
...
@@ -188,7 +185,7 @@ static void WaitScanResult(void)
{
{
int
scanTimeout
=
DEF_TIMEOUT
;
int
scanTimeout
=
DEF_TIMEOUT
;
while
(
scanTimeout
>
0
)
{
while
(
scanTimeout
>
0
)
{
sleep
(
ONE_SECOND
);
osDelay
(
ONE_SECOND
);
scanTimeout
--
;
scanTimeout
--
;
if
(
g_staScanSuccess
==
1
)
{
if
(
g_staScanSuccess
==
1
)
{
printf
(
"WaitScanResult:wait success[%d]s
\n
"
,
(
DEF_TIMEOUT
-
scanTimeout
));
printf
(
"WaitScanResult:wait success[%d]s
\n
"
,
(
DEF_TIMEOUT
-
scanTimeout
));
...
@@ -393,7 +390,7 @@ LITE_TEST_CASE(WifiServiceFuncTestSuite, testConnectDisConnect, Function | Mediu
...
@@ -393,7 +390,7 @@ LITE_TEST_CASE(WifiServiceFuncTestSuite, testConnectDisConnect, Function | Mediu
LITE_TEST_CASE
(
WifiServiceFuncTestSuite
,
testHandleDeviceConfig
,
Function
|
MediumTest
|
Level2
)
LITE_TEST_CASE
(
WifiServiceFuncTestSuite
,
testHandleDeviceConfig
,
Function
|
MediumTest
|
Level2
)
{
{
int
netId
=
0
;
int
netId
=
0
;
const
char
*
ssid0
=
"TestWifi01"
;
const
char
*
ssid0
=
"TestWifi01"
;
const
char
*
ssid
[
TEST_SSID_COUNT
]
=
{
"TestWifi02"
,
"TestWifi03"
,
"TestWifi04"
,
"TestWifi05"
,
"TestWifi06"
,
const
char
*
ssid
[
TEST_SSID_COUNT
]
=
{
"TestWifi02"
,
"TestWifi03"
,
"TestWifi04"
,
"TestWifi05"
,
"TestWifi06"
,
"TestWifi07"
,
"TestWifi08"
,
"TestWifi09"
,
"TestWifi10"
};
"TestWifi07"
,
"TestWifi08"
,
"TestWifi09"
,
"TestWifi10"
};
const
char
*
ssid10
=
"TestWifi11"
;
const
char
*
ssid10
=
"TestWifi11"
;
...
@@ -426,7 +423,7 @@ LITE_TEST_CASE(WifiServiceFuncTestSuite, testHandleDeviceConfig, Function | Medi
...
@@ -426,7 +423,7 @@ LITE_TEST_CASE(WifiServiceFuncTestSuite, testHandleDeviceConfig, Function | Medi
break
;
break
;
}
}
}
}
ret
=
strncpy_s
(
config
.
ssid
,
WIFI_MAX_SSID_LEN
,
ssid10
,
strlen
(
ssid10
));
ret
=
strncpy_s
(
config
.
ssid
,
WIFI_MAX_SSID_LEN
,
ssid10
,
strlen
(
ssid10
));
TEST_ASSERT_EQUAL_INT
(
WIFI_SUCCESS
,
ret
);
TEST_ASSERT_EQUAL_INT
(
WIFI_SUCCESS
,
ret
);
ret
=
strncpy_s
(
config
.
preSharedKey
,
WIFI_MAX_KEY_LEN
,
info
,
strlen
(
info
));
ret
=
strncpy_s
(
config
.
preSharedKey
,
WIFI_MAX_KEY_LEN
,
info
,
strlen
(
info
));
...
@@ -525,7 +522,7 @@ LITE_TEST_CASE(WifiServiceFuncTestSuite, testEnableDisableHotSpot, Function | Me
...
@@ -525,7 +522,7 @@ LITE_TEST_CASE(WifiServiceFuncTestSuite, testEnableDisableHotSpot, Function | Me
int
timeout
=
3
;
int
timeout
=
3
;
g_apEnableSuccess
=
0
;
g_apEnableSuccess
=
0
;
while
(
timeout
>
0
)
{
while
(
timeout
>
0
)
{
sleep
(
ONE_SECOND
);
osDelay
(
ONE_SECOND
);
timeout
--
;
timeout
--
;
if
(
g_apEnableSuccess
>=
1
)
{
if
(
g_apEnableSuccess
>=
1
)
{
printf
(
"Wait %d seconds.
\n
"
,
(
DEF_TIMEOUT
-
timeout
));
printf
(
"Wait %d seconds.
\n
"
,
(
DEF_TIMEOUT
-
timeout
));
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录