/* * Copyright (C) 2022 Huawei Device Co., Ltd. * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ // @ts-ignore import {SpQuerySQL} from "../../../dist/trace/component/SpQuerySQL.js" describe('SpQuerySQL Test', () => { let spQuerySQL= new SpQuerySQL(); it('SpQuerySQLTest01', function () { expect(spQuerySQL.checkSupportSqlAbility()).toBeFalsy() }); it('SpQuerySQLTest02', function () { expect(spQuerySQL.checkSafetySelectSql()).toBeTruthy() }); it('SpQuerySQLTest03', function () { expect(spQuerySQL.getSelectSqlField()).toBe("") }); it('SpQuerySQLTest04', function () { expect(spQuerySQL.getSelectSqlTableName()).not.toBeUndefined() }); it('SpQuerySQLTest05', function () { expect(spQuerySQL.initDataElement()).toBeUndefined() }); it('SpQuerySQLTest06', function () { spQuerySQL.statDataArray.length = 1 expect(spQuerySQL.initData()).toBeUndefined() }); it('SpQuerySQLTest07', function () { expect(spQuerySQL.attributeChangedCallback()).toBeUndefined() }); it('SpQuerySQLTest08', function () { expect(spQuerySQL.initHtml()).toMatchInlineSnapshot(` "