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//@ts-ignore 16import { SpFileSystem } from "../../../../dist/trace/component/setting/SpFileSystem"; 17 18describe('spFileSystem Test', () => { 19 let spFileSystem = new SpFileSystem(); 20 it('SpFileSystemTest01', function () { 21 spFileSystem.startSamp = true; 22 expect(spFileSystem.startSamp).toBeTruthy(); 23 }); 24 25 it('SpFileSystemTest02', function () { 26 spFileSystem.startSamp = false; 27 expect(spFileSystem.startSamp).toBeFalsy(); 28 }); 29 30 it('SpFileSystemTest03', function () { 31 expect(spFileSystem.getSystemConfig()).toStrictEqual({"process": ""}) 32 }); 33 34 it('SpFileSystemTest04', function () { 35 expect(spFileSystem.unDisable()).toBeUndefined(); 36 }); 37 38 it('SpFileSystemTest05', function () { 39 expect(spFileSystem.disable()).toBeUndefined(); 40 }); 41 42 it('SpFileSystemTest06', function () { 43 expect(spFileSystem.initConfigList()).toBeUndefined(); 44 }); 45 46 it('SpFileSystemTest07', function () { 47 spFileSystem.startRecord = true; 48 expect(spFileSystem.startRecord).toBeTruthy(); 49 }); 50 51 it('SpFileSystemTest08', function () { 52 spFileSystem.startRecord = false; 53 expect(spFileSystem.startRecord).toBeFalsy(); 54 }); 55 56 it('SpFileSystemTest09', function () { 57 spFileSystem.startFileSystem = true; 58 expect(spFileSystem.startFileSystem).toBeTruthy(); 59 }); 60 61 it('SpFileSystemTest10', function () { 62 spFileSystem.startFileSystem = false; 63 expect(spFileSystem.startFileSystem).toBeFalsy(); 64 }); 65 66 it('SpFileSystemTest11', function () { 67 spFileSystem.startVirtualMemory = true; 68 expect(spFileSystem.startVirtualMemory).toBeTruthy(); 69 }); 70 71 it('SpFileSystemTest12', function () { 72 spFileSystem.startVirtualMemory = false; 73 expect(spFileSystem.startVirtualMemory).toBeFalsy(); 74 }); 75 76 it('SpFileSystemTest13', function () { 77 spFileSystem.startIo = true; 78 expect(spFileSystem.startIo).toBeTruthy(); 79 }); 80 81 it('SpFileSystemTest14', function () { 82 spFileSystem.startIo = false; 83 expect(spFileSystem.startIo).toBeFalsy(); 84 }); 85})