mirror of
https://gitee.com/openharmony/applications_app_samples
synced 2025-02-17 02:08:44 +00:00
修改错误格式
Signed-off-by: l-l <liuxiaobofight@163.com>
This commit is contained in:
parent
6e1482020d
commit
9479293030
@ -1,3 +1,18 @@
|
||||
/*
|
||||
* Copyright (C) 2023-2024 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.
|
||||
*/
|
||||
|
||||
{
|
||||
"app": {
|
||||
"signingConfigs": [],
|
||||
|
@ -63,7 +63,7 @@ export default struct AddFormByMenu {
|
||||
.fontSize(30)
|
||||
.margin({ bottom: 20 })
|
||||
}
|
||||
.backgroundImage($r("app.media.CardEvent"))
|
||||
.backgroundImage($r('app.media.CardEvent'))
|
||||
.backgroundImageSize(ImageSize.Cover)
|
||||
.id(this.compId)
|
||||
.width(200)
|
||||
|
@ -63,7 +63,7 @@ export default struct AddFormByMenu {
|
||||
.fontSize(30)
|
||||
.margin({ bottom: 20 })
|
||||
}
|
||||
.backgroundImage($r("app.media.CardEvent"))
|
||||
.backgroundImage($r('app.media.CardEvent'))
|
||||
.backgroundImageSize(ImageSize.Cover)
|
||||
.id(this.compId)
|
||||
.width(200)
|
||||
|
@ -56,12 +56,13 @@ export default class OpenHarmonyTestRunner implements TestRunner {
|
||||
}
|
||||
}
|
||||
|
||||
async function checkMock(abilityDelegator: abilityDelegatorRegistry.AbilityDelegator, resourceManager: resourceManager.ResourceManager) {
|
||||
async function checkMock(abilityDelegator: abilityDelegatorRegistry.AbilityDelegator,
|
||||
resourceManager: resourceManager.ResourceManager) {
|
||||
let rawFile: Uint8Array;
|
||||
try {
|
||||
rawFile = resourceManager.getRawFileContentSync(jsonPath);
|
||||
hilog.info(0x0000, tag, 'MockList file exists');
|
||||
let mockStr: string = util.TextDecoder.create("utf-8", { ignoreBOM: true }).decodeWithStream(rawFile);
|
||||
let mockStr: string = util.TextDecoder.create('utf-8', { ignoreBOM: true }).decodeWithStream(rawFile);
|
||||
let mockMap: Record<string, string> = getMockList(mockStr);
|
||||
try {
|
||||
abilityDelegator.setMockList(mockMap)
|
||||
@ -73,7 +74,8 @@ async function checkMock(abilityDelegator: abilityDelegatorRegistry.AbilityDeleg
|
||||
} catch (error) {
|
||||
let code = (error as BusinessError).code;
|
||||
let message = (error as BusinessError).message;
|
||||
hilog.error(0x0000, tag, `ResourceManager:callback getRawFileContent failed, error code: ${code}, message: ${message}.`);
|
||||
hilog.error(0x0000, tag,
|
||||
`ResourceManager:callback getRawFileContent failed, error code: ${code}, message: ${message}.`);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1,3 +1,18 @@
|
||||
/*
|
||||
* Copyright (C) 2023-2024 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.
|
||||
*/
|
||||
|
||||
{
|
||||
"modelVersion": "5.0.0",
|
||||
"name": "formSample",
|
||||
|
Loading…
x
Reference in New Issue
Block a user