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 16import { Cmd } from '../../src/command/Cmd'; 17 18describe('Cmd', () => { 19 it('CmdTest_01', () => { 20 expect(Cmd.execObjDump('', '')).toBeUndefined(); 21 }); 22 23 it('CmdTest_02', () => { 24 expect(Cmd.execHdcCmd('')).toBeUndefined(); 25 }); 26 27 it('CmdTest_03', () => { 28 expect(Cmd.execFileRecv('', '')).toBeTruthy(); 29 }); 30 31 it('CmdTest_04', () => { 32 expect(Cmd.execHdcTraceCmd('', '')).toBeUndefined(); 33 }); 34 35 it('CmdTest_05', () => { 36 let params = [ 37 { 38 length: 0, 39 }, 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}); 64