From 5ed9d992de7844f12b78d96aa27dee53a4035518 Mon Sep 17 00:00:00 2001 From: hu0475 Date: Wed, 12 Jul 2023 19:48:16 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=A3=80=E8=A7=86=E6=84=8F?= =?UTF-8?q?=E8=A7=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: hu0475 --- commonlibrary/BUILD.gn | 2 +- .../commonlibraryTreeMapetstest/BUILD.gn | 12 ++++++++++++ .../commonlibraryTreeMapetstest/Test.json | 9 +-------- .../src/main/ets/TestAbility/TestAbility.ets | 14 ++++++++++++++ .../src/main/ets/TestAbility/pages/Index.ets | 14 ++++++++++++++ .../src/main/ets/test/List.test.ets | 14 ++++++++++++++ 6 files changed, 56 insertions(+), 9 deletions(-) diff --git a/commonlibrary/BUILD.gn b/commonlibrary/BUILD.gn index 2109ccf67..ff1e721a0 100644 --- a/commonlibrary/BUILD.gn +++ b/commonlibrary/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (C) 2022 Huawei Device Co., Ltd. +# Copyright (C) 2023 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 diff --git a/commonlibrary/crossplatform/commonlibraryTreeMapetstest/BUILD.gn b/commonlibrary/crossplatform/commonlibraryTreeMapetstest/BUILD.gn index d54ce1111..d3bef2417 100644 --- a/commonlibrary/crossplatform/commonlibraryTreeMapetstest/BUILD.gn +++ b/commonlibrary/crossplatform/commonlibraryTreeMapetstest/BUILD.gn @@ -1,3 +1,15 @@ +# Copyright (C) 2023 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. import("//test/xts/tools/build/suite.gni") ohos_js_hap_suite("TreeMap_ets_test") { diff --git a/commonlibrary/crossplatform/commonlibraryTreeMapetstest/Test.json b/commonlibrary/crossplatform/commonlibraryTreeMapetstest/Test.json index 561a43d42..879a5e5db 100644 --- a/commonlibrary/crossplatform/commonlibraryTreeMapetstest/Test.json +++ b/commonlibrary/crossplatform/commonlibraryTreeMapetstest/Test.json @@ -1,20 +1,13 @@ { "description": "Configuration for hjunit demo Tests", - // 指定设备执行的驱动 "driver": { "type": "OHJSUnitTest", - //test-timeout: 测试hap 整体执行用例的执行时长 "test-timeout": "60000", - //shell-timeout: aa test 拉起命令执行时长 "shell-timeout": "60000", - //bundle-name: 与HAP的app.json 中 bundleName 保持一致 "bundle-name": "ohos.acts.commonlibrary.crossplatform.TreeMap.normal", - //module-name: 与HAP的module.json 中"module"字段的 name 保持一致 "module-name": "entry_test" - //testcase-timeout: 测试hap 单条用例的执行时长 - //"testcase-timeout": 5000 }, - // kit的作用主要是为了支撑测试执行活动,在测试前执行预制操作(Setup),在测试后执行清理操作(Teardown) + "kits": [ { "test-file-name": [ diff --git a/commonlibrary/crossplatform/commonlibraryTreeMapetstest/src/main/ets/TestAbility/TestAbility.ets b/commonlibrary/crossplatform/commonlibraryTreeMapetstest/src/main/ets/TestAbility/TestAbility.ets index 2d889f4fd..368aef919 100644 --- a/commonlibrary/crossplatform/commonlibraryTreeMapetstest/src/main/ets/TestAbility/TestAbility.ets +++ b/commonlibrary/crossplatform/commonlibraryTreeMapetstest/src/main/ets/TestAbility/TestAbility.ets @@ -1,3 +1,17 @@ +/* + * Copyright (C) 2023 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. + */ import UIAbility from '@ohos.app.ability.UIAbility'; import AbilityDelegatorRegistry from '@ohos.app.ability.abilityDelegatorRegistry'; import hilog from '@ohos.hilog'; diff --git a/commonlibrary/crossplatform/commonlibraryTreeMapetstest/src/main/ets/TestAbility/pages/Index.ets b/commonlibrary/crossplatform/commonlibraryTreeMapetstest/src/main/ets/TestAbility/pages/Index.ets index 166366593..e95640899 100644 --- a/commonlibrary/crossplatform/commonlibraryTreeMapetstest/src/main/ets/TestAbility/pages/Index.ets +++ b/commonlibrary/crossplatform/commonlibraryTreeMapetstest/src/main/ets/TestAbility/pages/Index.ets @@ -1,3 +1,17 @@ +/* + * Copyright (C) 2023 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. + */ import hilog from '@ohos.hilog'; @Entry diff --git a/commonlibrary/crossplatform/commonlibraryTreeMapetstest/src/main/ets/test/List.test.ets b/commonlibrary/crossplatform/commonlibraryTreeMapetstest/src/main/ets/test/List.test.ets index 1b02130a3..5a7752173 100644 --- a/commonlibrary/crossplatform/commonlibraryTreeMapetstest/src/main/ets/test/List.test.ets +++ b/commonlibrary/crossplatform/commonlibraryTreeMapetstest/src/main/ets/test/List.test.ets @@ -1,3 +1,17 @@ +/* + * Copyright (c) 2023 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. + */ import TreeMapTest from './TreeMap.test' export default function testsuite() { -- GitLab