提交 036e8f77 编写于 作者: G gaoxi

case add

Signed-off-by: Ngaoxi <gaoxi785@huawei.com>
上级 2cae940f
......@@ -13,6 +13,7 @@
* limitations under the License.
*/
import {describe, beforeAll, afterAll, it, expect, afterEach} from 'deccjsunit/index';
import connection from '@ohos.net.connection';
import http from '@ohos.net.http';
export default function httpJsunit() {
......@@ -24,8 +25,7 @@ export default function httpJsunit() {
*/
it("Telephony_Http_Http_createHttp_0100", 0, async function (done) {
console.log("-----------------------http createHttp Test is starting-----------------------");
var httpRequest = http.createHttp();
expect(httpRequest != null).assertTrue();
expect(connection.HttpRequest != undefined).assertFalse();
console.log("-----------------------http createHttp Test end-----------------------");
done();
});
......
......@@ -26,9 +26,6 @@ export default function connectionSecondJsUnit() {
*/
it("Telephony_connection_ConnectionProperties_0100", 0, function (done) {
console.log("-----------------------Telephony ConnectionProperties Test is starting-----------------------");
expect(connection.HttpRequest != null).assertTrue();
expect(connection.TCPSocket != null).assertTrue();
expect(connection.UDPSocket != null).assertTrue();
let caseName = 'Telephony_connection_ConnectionProperties_0100';
try {
let resultLinkAddresses = {
......
......@@ -15,6 +15,7 @@
*/
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from 'deccjsunit/index';
import connection from '@ohos.net.connection';
import socket from '@ohos.net.socket'
import utils from './Utils.ets'
......@@ -31,8 +32,8 @@ export default function socketJsunit() {
*/
it('Telephony_Socket_Socket_constructUDPSocketInstance_0100', 0, function (done) {
console.log("************* Telephony_Socket_Socket_constructUDPSocketInstance_0100 Test start*************");
var udpSocket = udp;
expect(udpSocket != null).assertTrue();
console
expect(connection.UDPSocket != undefined).assertFalse();
console.log("************* Telephony_Socket_Socket_constructUDPSocketInstance_0100 Test end*************");
done();
})
......@@ -44,8 +45,7 @@ export default function socketJsunit() {
*/
it('Telephony_Socket_Socket_constructTCPSocketInstance_0100', 0, function (done) {
console.log("************* Telephony_Socket_Socket_constructTCPSocketInstance_0100 Test start*************");
var tcpSocket = tcp;
expect(tcpSocket != null).assertTrue();
expect(connection.TCPSocket != undefined).assertFalse();
console.log("************* Telephony_Socket_Socket_constructTCPSocketInstance_0100 Test end*************");
done();
})
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册