1# Copyright (c) 2023 Huawei Device Co., Ltd. 2# Licensed under the Apache License, Version 2.0 (the "License"); 3# you may not use this file except in compliance with the License. 4# You may obtain a copy of the License at 5# 6# http:\www.apache.org/licenses/LICENSE-2.0 7# 8# Unless required by applicable law or agreed to in writing, software 9# distributed under the License is distributed on an "AS IS" BASIS, 10# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 11# See the License for the specific language governing permissions and 12# limitations under the License. 13 14# Description: configs for test suite 15 16# environment settings 17deveco_path: D:\Software\Deveco-0602\DevEco Studio 18deveco_harmonyos_sdk_path: D:\SDK\HarmonyOS_SDK 19deveco_openharmony_sdk_path: D:\SDK\openHarmony_SDK 20node_js_path: D:\Software\nodejs # The nodejs which is used in Deveco 21# the mapping between API and file name 22api_version_file_name_map: 23 '4.0.0(10)': "HarmonyOS-NEXT-DP0" 24 '4.1.0(11)': "HarmonyOS-NEXT-DP1" 25 '5.0.0(12)': "HarmonyOS-NEXT-DB0" 26 27# output settings 28output_html_file: ./sdk_test_report.html 29log_file: ./sdk_test_log.txt 30pictures_dic: ./pictures 31 32# descriptions about test haps list 33# each hap have the following attributes: 34# -name: name of the hap 35# -path: path of the hap project 36# -type: type of the hap. Available values are: [stage, fa, js, compatible8] 37# besides, you can also append attributes in [widget, ohosTest, error, exceed_length_error] 38# -widget: indicates this hap has widget, which has widgets.abc in stage mode 39# -error: indicates this hap need to test whether compile error is correctly generated as well 40# -exceed_length_error: indicates this hap need to test whether compile error is correctly generated when path exceed the limit 41# -ohosTest: indicates this hap needed to compile ohosTest as well 42# -hap_module: specify one module to build in the test. 43# -build_path: path to build path, in form of list 44# -cache_path: path to cache path, in form of list 45# -output_hap_path: path of output hap(debug mode), in form of list 46# -output_app_path: path of output app(release mode), in form of list 47# -inc_modify_file: path of modified file in incremental build, in form of list 48# -description: description about the hap, this attribute is not used yet. 49haps: 50 # complex haps 51 - calendar: 52 name: Calendar 53 path: D:\haps\calendar 54 type: [stage] 55 hap_module: entry 56 build_path: 57 cache_path: 58 output_hap_path: 59 output_app_path: 60 inc_modify_file: 61 description: 62 # widget haps 63 - widgetdemo: 64 name: WidgetDemo 65 path: D:\haps\WidgetDemo 66 type: [stage, widget] 67 hap_module: entry 68 build_path: 69 cache_path: 70 output_hap_path: 71 output_app_path: 72 inc_modify_file: 73 description: 74 # IDE demo haps 75 - idedemo_00: 76 name: IdeStageDemoEmptyAbility 77 path: D:\sdk-test\DemoApplication_EmptyAbility 78 type: [stage, ohosTest, exceed_length_error, error] 79 hap_module: entry 80 build_path: [entry, build, default] 81 bundle_name: com.example.idestagedemoemptyability 82 ability_name: EntryAbility 83 cache_path: [cache, default, default@CompileArkTS, esmodule] 84 output_hap_path: [outputs, default, entry-default-unsigned.hap] 85 output_hap_path_signed: [outputs, default, entry-default-signed.hap] 86 output_app_path: [outputs, default, app, entry-default.hap] 87 inc_modify_file: [entry, src, main, ets, pages, Index.ets] 88 description: 89 - idedemo_01: 90 name: IdeFaDemoEmptyAbility 91 path: D:\sdk-test\DemoApplication_EmptyAbility_fa 92 type: [fa, ohosTest, exceed_length_error, error] 93 hap_module: entry 94 build_path: [entry, build, default] 95 bundle_name: com.example.idefademoemptyability 96 ability_name: com.example.idefademoemptyability.MainAbility 97 cache_path: [cache, default, default@LegacyCompileArkTS, jsbundle] 98 output_hap_path: [outputs, default, entry-default-unsigned.hap] 99 output_hap_path_signed: [outputs, default, entry-default-signed.hap] 100 output_app_path: [outputs, default, app, entry-default.hap] 101 inc_modify_file: [entry, src, main, ets, MainAbility, pages, index.ets] 102 description: 103 - idedemo_02: 104 name: IdeCompatible8DemoEmptyAbility 105 path: D:\sdk-test\DemoApplication_EmptyAbility_compatible8 106 type: [compatible8, ohosTest, exceed_length_error, error] 107 hap_module: entry 108 build_path: [entry, build, default] 109 bundle_name: com.example.idecompatible8demoemptyability 110 ability_name: com.example.idecompatible8demoemptyability.MainAbility 111 cache_path: [cache, default, default@LegacyCompileArkTS, jsbundle] 112 output_hap_path: [outputs, default, entry-default-unsigned.hap] 113 output_hap_path_signed: [outputs, default, entry-default-signed.hap] 114 output_app_path: [outputs, default, app, entry-default.hap] 115 inc_modify_file: [entry, src, main, ets, MainAbility, pages, index.ets] 116 description: 117 - idedemo_03: 118 name: IdeJsDemoEmptyAbility 119 path: D:\sdk-test\DemoApplication_EmptyAbility_js 120 type: [js, ohosTest, exceed_length_error, error] 121 hap_module: entry 122 build_path: [entry, build, default] 123 bundle_name: com.example.idejsdemoemptyability 124 ability_name: com.example.idejsdemoemptyability.MainAbility 125 cache_path: [cache, default, default@LegacyCompileJS, jsbundle] 126 output_hap_path_signed: [ outputs, default, entry-default-signed.hap] 127 output_hap_path: [outputs, default, entry-default-unsigned.hap] 128 output_app_path: [outputs, default, app, entry-default.hap] 129 inc_modify_file: [entry, src, main, js, MainAbility, pages, index, index.js] 130 description: 131 132# modifications for incremental compilation and other tests 133patch_content: 134 patch_new_file_ets: 135 # This new file will be added to the same directory as 'inc_modify_file' specified in haps 136 name: test.ets 137 content: "export function a() {return 'a'}" 138 patch_new_file_js: 139 name: test.js 140 content: "export function a() {return 'a'}" 141 patch_lines_1: 142 head: "import {a} from './test'\n" 143 tail: "\n console.log(a.toString());\n" 144 patch_lines_2: 145 tail: "\n console.log('This is a new line');\n" 146 patch_lines_error: 147 tail: "\n let a_duplicated_value_for_test_suite = 1; function a_duplicated_value_for_test_suite() {};" 148 expected_error: [Duplicate identifier 'a_duplicated_value_for_test_suite', Identifier 'a_duplicated_value_for_test_suite' has already been declared]