1/* 2 * Copyright (C) 2022 Huawei Device Co., Ltd. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 16// @ts-ignore 17import {Cmd} from "../../dist/command/Cmd.js"; 18 19describe('Cmd', () => { 20 21 it('CmdTest_01', () => { 22 expect(Cmd.execObjDump("","")).toBeUndefined() 23 }); 24 25 it('CmdTest_02', () => { 26 expect(Cmd.execHdcCmd("")).toBeUndefined() 27 }); 28 29 it('CmdTest_03', () => { 30 expect(Cmd.execFileRecv("","")).toBeTruthy() 31 }); 32 33 it('CmdTest_04', () => { 34 expect(Cmd.execHdcTraceCmd("","")).toBeUndefined() 35 }); 36 37 it('CmdTest_05', () => { 38 let params = [{ 39 length:0 40 }] 41 expect(Cmd.formatString("",params)).toBe("") 42 }); 43 44 it('CmdTest_06', () => { 45 expect(Cmd.showSaveFile()).toBeUndefined() 46 }); 47 48 it('CmdTest_07', () => { 49 expect(Cmd.uploadFile()).toBeUndefined() 50 }); 51 52 it('CmdTest_08', () => { 53 expect(Cmd.copyFile("","")).toBeUndefined() 54 }); 55 56 it('CmdTest_09', () => { 57 expect(Cmd.openFileDialog()).toBeTruthy() 58 }); 59 60 it('CmdTest_10', () => { 61 expect(Cmd.formatString("",[])).toBe("") 62 }); 63})