diff --git a/CODEOWNERS b/CODEOWNERS index c63c8083e..c07d33366 100644 --- a/CODEOWNERS +++ b/CODEOWNERS @@ -94,13 +94,12 @@ tests/core/common/ zhusiyuan2@huawei.com interfaces/kits/common/softbus_common.h zhusiyuan2@huawei.com [DFX] -dfx/ zhusiyuan2@huawei.com -tests/core/common/dfx zhusiyuan2@huawei.com +dfx/ zhusiyuan2@huawei.com +tests/dfx zhusiyuan2@huawei.com [DFXInterface] hisysevent.yaml litongxin3@huawei.com interfaces/kits/common/softbus_error_code.h litongxin3@huawei.com -dfx/interface litongxin3@huawei.com [Framework] core/frame/ zhangfengxi@huawei.com diff --git a/core/common/BUILD.gn b/core/common/BUILD.gn index f22270c4e..748d868e6 100644 --- a/core/common/BUILD.gn +++ b/core/common/BUILD.gn @@ -80,9 +80,8 @@ if (defined(ohos_lite)) { "$dsoftbus_root_path/components/nstackx/nstackx_core/dfile/interface", ] include_dirs += conn_common_inc + trans_common_inc - dfx_src = [ - "$dsoftbus_dfx_path/event/legacy/hisysevent_adapter/softbus_hisysevt_nstack_virtual.c", - ] + dfx_src = + [ "$dsoftbus_dfx_path/event/legacy/softbus_hisysevt_nstack_virtual.c" ] sources = common_utils_src sources += conn_common_src + trans_common_src + dfx_src sources += [ "message_handler/message_handler.c" ] diff --git a/dfx/dumper/legacy/BUILD.gn b/dfx/dumper/legacy/BUILD.gn index f729297fa..0415ac1ae 100644 --- a/dfx/dumper/legacy/BUILD.gn +++ b/dfx/dumper/legacy/BUILD.gn @@ -11,8 +11,8 @@ # See the License for the specific language governing permissions and # limitations under the License. -import("../../../dsoftbus.gni") import("../../../core/transmission/common/trans_common.gni") +import("../../../dsoftbus.gni") softbus_adapter_common = "${dsoftbus_root_path}/adapter/common" diff --git a/dsoftbus.gni b/dsoftbus.gni index 9c620f1d0..f51f07321 100644 --- a/dsoftbus.gni +++ b/dsoftbus.gni @@ -17,7 +17,7 @@ dsoftbus_sdk_path = "${dsoftbus_root_path}/sdk" dsoftbus_core_path = "${dsoftbus_root_path}/core" dsoftbus_dfx_path = "${dsoftbus_root_path}/dfx" dsoftbus_test_path = "${dsoftbus_root_path}/tests" -dsoftbus_test_dfx_path = "${dsoftbus_test_path}/core/common/dfx" +dsoftbus_test_dfx_path = "${dsoftbus_test_path}/dfx" dsoftbus_fuzz_out_path = "dsoftbus/soft_bus" declare_args() { diff --git a/tests/BUILD.gn b/tests/BUILD.gn index f086af4b6..2fefae354 100644 --- a/tests/BUILD.gn +++ b/tests/BUILD.gn @@ -48,6 +48,7 @@ if (defined(ohos_lite)) { "core/discovery:unittest", "core/frame:unittest", "core/transmission:unittest", + "dfx:unittest", "sdk/bus_center:unittest", "sdk/discovery:unittest", "sdk/frame/common:unittest", @@ -70,6 +71,7 @@ if (defined(ohos_lite)) { "core/discovery:fuzztest", "core/frame:fuzztest", "core/transmission:fuzztest", + "dfx:fuzztest", "sdk/bus_center:fuzztest", "sdk/frame:fuzztest", "sdk/transmission:fuzztest", diff --git a/tests/core/common/BUILD.gn b/tests/core/common/BUILD.gn index 574ba31fe..fe66af897 100644 --- a/tests/core/common/BUILD.gn +++ b/tests/core/common/BUILD.gn @@ -18,12 +18,6 @@ group("unittest") { testonly = true deps = [ "bitmap:unittest", - "dfx/anonymize:unittest", - "dfx/event:unittest", - "dfx/hidumper_adapter/unittest:unittest", - "dfx/hisysevent_adapter/unittest:unittest", - "dfx/log:unittest", - "dfx/statistics/unittest:unittest", "json_utils:unittest", "network:unittest", "queue:unittest", @@ -37,8 +31,6 @@ group("unittest") { group("fuzztest") { testonly = true deps = [ - "dfx/hidumper_adapter/fuzztest:fuzztest", - "dfx/hisysevent_adapter/fuzztest:fuzztest", "json_utils:fuzztest", "message_handler:fuzztest", "utils/fuzztest:fuzztest", diff --git a/tests/dfx/BUILD.gn b/tests/dfx/BUILD.gn new file mode 100644 index 000000000..414b01a5e --- /dev/null +++ b/tests/dfx/BUILD.gn @@ -0,0 +1,35 @@ +# Copyright (c) 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. + +import("//build/test.gni") +import("../../dsoftbus.gni") + +group("unittest") { + testonly = true + deps = [ + "anonymize:unittest", + "dumper/legacy/unittest:unittest", + "event:unittest", + "event/legacy/unittest:unittest", + "log:unittest", + "statistics/unittest:unittest", + ] +} + +group("fuzztest") { + testonly = true + deps = [ + "dumper/legacy/fuzztest:fuzztest", + "event/legacy/fuzztest:fuzztest", + ] +} diff --git a/tests/core/common/dfx/anonymize/BUILD.gn b/tests/dfx/anonymize/BUILD.gn similarity index 100% rename from tests/core/common/dfx/anonymize/BUILD.gn rename to tests/dfx/anonymize/BUILD.gn diff --git a/tests/core/common/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/BUILD.gn b/tests/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/BUILD.gn similarity index 96% rename from tests/core/common/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/BUILD.gn rename to tests/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/BUILD.gn index d0a47e387..f31e683b9 100644 --- a/tests/core/common/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/BUILD.gn +++ b/tests/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/BUILD.gn @@ -15,7 +15,7 @@ import("//build/config/features.gni") import("//build/ohos.gni") import("//build/test.gni") -import("../../../../../../../dsoftbus.gni") +import("../../../../../dsoftbus.gni") ##############################fuzztest########################################## diff --git a/tests/core/common/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/corpus/init b/tests/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/corpus/init similarity index 100% rename from tests/core/common/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/corpus/init rename to tests/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/corpus/init diff --git a/tests/core/common/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/project.xml b/tests/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/project.xml similarity index 100% rename from tests/core/common/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/project.xml rename to tests/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/project.xml diff --git a/tests/core/common/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/softbusdfxanonymize_fuzzer.cpp b/tests/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/softbusdfxanonymize_fuzzer.cpp similarity index 100% rename from tests/core/common/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/softbusdfxanonymize_fuzzer.cpp rename to tests/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/softbusdfxanonymize_fuzzer.cpp diff --git a/tests/core/common/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/softbusdfxanonymize_fuzzer.h b/tests/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/softbusdfxanonymize_fuzzer.h similarity index 100% rename from tests/core/common/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/softbusdfxanonymize_fuzzer.h rename to tests/dfx/anonymize/fuzztest/softbusdfxanonymize_fuzzer/softbusdfxanonymize_fuzzer.h diff --git a/tests/core/common/dfx/anonymize/unittest/BUILD.gn b/tests/dfx/anonymize/unittest/BUILD.gn similarity index 91% rename from tests/core/common/dfx/anonymize/unittest/BUILD.gn rename to tests/dfx/anonymize/unittest/BUILD.gn index a4e9f5d2f..7448c4e37 100644 --- a/tests/core/common/dfx/anonymize/unittest/BUILD.gn +++ b/tests/dfx/anonymize/unittest/BUILD.gn @@ -12,9 +12,9 @@ # limitations under the License. import("//build/test.gni") -import("../../../../../../dsoftbus.gni") +import("../../../../dsoftbus.gni") -module_output_path = "dsoftbus/common/dfx" +module_output_path = "dsoftbus/dfx" ohos_unittest("SoftBusDfxAnonymizeTest") { module_out_path = module_output_path diff --git a/tests/core/common/dfx/anonymize/unittest/src/anonymizer_test.cpp b/tests/dfx/anonymize/unittest/src/anonymizer_test.cpp similarity index 100% rename from tests/core/common/dfx/anonymize/unittest/src/anonymizer_test.cpp rename to tests/dfx/anonymize/unittest/src/anonymizer_test.cpp diff --git a/tests/core/common/dfx/hidumper_adapter/fuzztest/BUILD.gn b/tests/dfx/dumper/legacy/fuzztest/BUILD.gn similarity index 100% rename from tests/core/common/dfx/hidumper_adapter/fuzztest/BUILD.gn rename to tests/dfx/dumper/legacy/fuzztest/BUILD.gn diff --git a/tests/core/common/dfx/hidumper_adapter/fuzztest/softbushidumper_fuzzer/BUILD.gn b/tests/dfx/dumper/legacy/fuzztest/softbushidumper_fuzzer/BUILD.gn similarity index 93% rename from tests/core/common/dfx/hidumper_adapter/fuzztest/softbushidumper_fuzzer/BUILD.gn rename to tests/dfx/dumper/legacy/fuzztest/softbushidumper_fuzzer/BUILD.gn index 4fbbb109b..4d971fd6e 100644 --- a/tests/core/common/dfx/hidumper_adapter/fuzztest/softbushidumper_fuzzer/BUILD.gn +++ b/tests/dfx/dumper/legacy/fuzztest/softbushidumper_fuzzer/BUILD.gn @@ -15,14 +15,14 @@ import("//build/config/features.gni") import("//build/ohos.gni") import("//build/test.gni") -import("../../../../../../../dsoftbus.gni") +import("../../../../../../dsoftbus.gni") ##############################fuzztest########################################## ohos_fuzztest("SoftBusHiDumperFuzzTest") { module_out_path = dsoftbus_fuzz_out_path fuzz_config_file = - "$dsoftbus_test_dfx_path/hidumper_adapter/fuzztest/softbushidumper_fuzzer" + "$dsoftbus_test_dfx_path/dumper/legacy/fuzztest/softbushidumper_fuzzer" include_dirs = [ "$dsoftbus_dfx_path/interface/include", diff --git a/tests/core/common/dfx/hidumper_adapter/fuzztest/softbushidumper_fuzzer/corpus/init b/tests/dfx/dumper/legacy/fuzztest/softbushidumper_fuzzer/corpus/init similarity index 100% rename from tests/core/common/dfx/hidumper_adapter/fuzztest/softbushidumper_fuzzer/corpus/init rename to tests/dfx/dumper/legacy/fuzztest/softbushidumper_fuzzer/corpus/init diff --git a/tests/core/common/dfx/hidumper_adapter/fuzztest/softbushidumper_fuzzer/project.xml b/tests/dfx/dumper/legacy/fuzztest/softbushidumper_fuzzer/project.xml similarity index 100% rename from tests/core/common/dfx/hidumper_adapter/fuzztest/softbushidumper_fuzzer/project.xml rename to tests/dfx/dumper/legacy/fuzztest/softbushidumper_fuzzer/project.xml diff --git a/tests/core/common/dfx/hidumper_adapter/fuzztest/softbushidumper_fuzzer/softbushidumper_fuzzer.cpp b/tests/dfx/dumper/legacy/fuzztest/softbushidumper_fuzzer/softbushidumper_fuzzer.cpp similarity index 100% rename from tests/core/common/dfx/hidumper_adapter/fuzztest/softbushidumper_fuzzer/softbushidumper_fuzzer.cpp rename to tests/dfx/dumper/legacy/fuzztest/softbushidumper_fuzzer/softbushidumper_fuzzer.cpp diff --git a/tests/core/common/dfx/hidumper_adapter/fuzztest/softbushidumper_fuzzer/softbushidumper_fuzzer.h b/tests/dfx/dumper/legacy/fuzztest/softbushidumper_fuzzer/softbushidumper_fuzzer.h similarity index 100% rename from tests/core/common/dfx/hidumper_adapter/fuzztest/softbushidumper_fuzzer/softbushidumper_fuzzer.h rename to tests/dfx/dumper/legacy/fuzztest/softbushidumper_fuzzer/softbushidumper_fuzzer.h diff --git a/tests/core/common/dfx/hidumper_adapter/unittest/BUILD.gn b/tests/dfx/dumper/legacy/unittest/BUILD.gn similarity index 94% rename from tests/core/common/dfx/hidumper_adapter/unittest/BUILD.gn rename to tests/dfx/dumper/legacy/unittest/BUILD.gn index 04d3e8a80..e7be5dec4 100644 --- a/tests/core/common/dfx/hidumper_adapter/unittest/BUILD.gn +++ b/tests/dfx/dumper/legacy/unittest/BUILD.gn @@ -14,10 +14,9 @@ import("//build/lite/config/component/lite_component.gni") import("//build/ohos.gni") import("//build/test.gni") -import("../../../../../../dsoftbus.gni") +import("../../../../../dsoftbus.gni") module_output_path = "dsoftbus/common" -dsoftbus_root_path = "../../../../../.." ohos_unittest("HidumperTest") { module_out_path = module_output_path diff --git a/tests/core/common/dfx/hidumper_adapter/unittest/hidumper_test.cpp b/tests/dfx/dumper/legacy/unittest/hidumper_test.cpp similarity index 100% rename from tests/core/common/dfx/hidumper_adapter/unittest/hidumper_test.cpp rename to tests/dfx/dumper/legacy/unittest/hidumper_test.cpp diff --git a/tests/core/common/dfx/event/BUILD.gn b/tests/dfx/event/BUILD.gn similarity index 100% rename from tests/core/common/dfx/event/BUILD.gn rename to tests/dfx/event/BUILD.gn diff --git a/tests/core/common/dfx/hisysevent_adapter/fuzztest/BUILD.gn b/tests/dfx/event/legacy/fuzztest/BUILD.gn similarity index 100% rename from tests/core/common/dfx/hisysevent_adapter/fuzztest/BUILD.gn rename to tests/dfx/event/legacy/fuzztest/BUILD.gn diff --git a/tests/core/common/dfx/hisysevent_adapter/fuzztest/softbushisysevt_fuzzer/BUILD.gn b/tests/dfx/event/legacy/fuzztest/softbushisysevt_fuzzer/BUILD.gn similarity index 92% rename from tests/core/common/dfx/hisysevent_adapter/fuzztest/softbushisysevt_fuzzer/BUILD.gn rename to tests/dfx/event/legacy/fuzztest/softbushisysevt_fuzzer/BUILD.gn index 3fa25dcf4..290633f5d 100644 --- a/tests/core/common/dfx/hisysevent_adapter/fuzztest/softbushisysevt_fuzzer/BUILD.gn +++ b/tests/dfx/event/legacy/fuzztest/softbushisysevt_fuzzer/BUILD.gn @@ -15,13 +15,14 @@ import("//build/config/features.gni") import("//build/ohos.gni") import("//build/test.gni") -import("../../../../../../../dsoftbus.gni") +import("../../../../../../dsoftbus.gni") ##############################fuzztest########################################## ohos_fuzztest("SoftBusHiSysEvtFuzzTest") { module_out_path = dsoftbus_fuzz_out_path - fuzz_config_file = "$dsoftbus_test_dfx_path/hisysevent_adapter/fuzztest/softbushisysevt_fuzzer" + fuzz_config_file = + "$dsoftbus_test_dfx_path/event/legacy/fuzztest/softbushisysevt_fuzzer" include_dirs = [ "$dsoftbus_root_path/core/common/include", diff --git a/tests/core/common/dfx/hisysevent_adapter/fuzztest/softbushisysevt_fuzzer/corpus/init b/tests/dfx/event/legacy/fuzztest/softbushisysevt_fuzzer/corpus/init similarity index 100% rename from tests/core/common/dfx/hisysevent_adapter/fuzztest/softbushisysevt_fuzzer/corpus/init rename to tests/dfx/event/legacy/fuzztest/softbushisysevt_fuzzer/corpus/init diff --git a/tests/core/common/dfx/hisysevent_adapter/fuzztest/softbushisysevt_fuzzer/project.xml b/tests/dfx/event/legacy/fuzztest/softbushisysevt_fuzzer/project.xml similarity index 100% rename from tests/core/common/dfx/hisysevent_adapter/fuzztest/softbushisysevt_fuzzer/project.xml rename to tests/dfx/event/legacy/fuzztest/softbushisysevt_fuzzer/project.xml diff --git a/tests/core/common/dfx/hisysevent_adapter/fuzztest/softbushisysevt_fuzzer/softbushisysevt_fuzzer.cpp b/tests/dfx/event/legacy/fuzztest/softbushisysevt_fuzzer/softbushisysevt_fuzzer.cpp similarity index 100% rename from tests/core/common/dfx/hisysevent_adapter/fuzztest/softbushisysevt_fuzzer/softbushisysevt_fuzzer.cpp rename to tests/dfx/event/legacy/fuzztest/softbushisysevt_fuzzer/softbushisysevt_fuzzer.cpp diff --git a/tests/core/common/dfx/hisysevent_adapter/fuzztest/softbushisysevt_fuzzer/softbushisysevt_fuzzer.h b/tests/dfx/event/legacy/fuzztest/softbushisysevt_fuzzer/softbushisysevt_fuzzer.h similarity index 100% rename from tests/core/common/dfx/hisysevent_adapter/fuzztest/softbushisysevt_fuzzer/softbushisysevt_fuzzer.h rename to tests/dfx/event/legacy/fuzztest/softbushisysevt_fuzzer/softbushisysevt_fuzzer.h diff --git a/tests/core/common/dfx/hisysevent_adapter/unittest/BUILD.gn b/tests/dfx/event/legacy/unittest/BUILD.gn similarity index 97% rename from tests/core/common/dfx/hisysevent_adapter/unittest/BUILD.gn rename to tests/dfx/event/legacy/unittest/BUILD.gn index ec6c474b1..6bd5f5486 100644 --- a/tests/core/common/dfx/hisysevent_adapter/unittest/BUILD.gn +++ b/tests/dfx/event/legacy/unittest/BUILD.gn @@ -11,9 +11,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -import("../../../../../../dsoftbus.gni") - -dsoftbus_root_path = "../../../../../.." +import("../../../../../dsoftbus.gni") if (defined(ohos_lite)) { import("//build/lite/config/component/lite_component.gni") diff --git a/tests/core/common/dfx/hisysevent_adapter/unittest/disc_conn_dfx_test.cpp b/tests/dfx/event/legacy/unittest/disc_conn_dfx_test.cpp similarity index 100% rename from tests/core/common/dfx/hisysevent_adapter/unittest/disc_conn_dfx_test.cpp rename to tests/dfx/event/legacy/unittest/disc_conn_dfx_test.cpp diff --git a/tests/core/common/dfx/hisysevent_adapter/unittest/lnn_dfx_test.cpp b/tests/dfx/event/legacy/unittest/lnn_dfx_test.cpp similarity index 100% rename from tests/core/common/dfx/hisysevent_adapter/unittest/lnn_dfx_test.cpp rename to tests/dfx/event/legacy/unittest/lnn_dfx_test.cpp diff --git a/tests/core/common/dfx/hisysevent_adapter/unittest/trans_dfx_test.cpp b/tests/dfx/event/legacy/unittest/trans_dfx_test.cpp similarity index 100% rename from tests/core/common/dfx/hisysevent_adapter/unittest/trans_dfx_test.cpp rename to tests/dfx/event/legacy/unittest/trans_dfx_test.cpp diff --git a/tests/core/common/dfx/event/unittest/BUILD.gn b/tests/dfx/event/unittest/BUILD.gn similarity index 93% rename from tests/core/common/dfx/event/unittest/BUILD.gn rename to tests/dfx/event/unittest/BUILD.gn index 3f99e1270..25e4fe3d4 100644 --- a/tests/core/common/dfx/event/unittest/BUILD.gn +++ b/tests/dfx/event/unittest/BUILD.gn @@ -12,9 +12,9 @@ # limitations under the License. import("//build/test.gni") -import("../../../../../../dsoftbus.gni") +import("../../../../dsoftbus.gni") -module_output_path = "dsoftbus/common/dfx" +module_output_path = "dsoftbus/dfx" ohos_unittest("SoftBusDfxEventTest") { module_out_path = module_output_path diff --git a/tests/core/common/dfx/event/unittest/mock/conn_hisysevent_matcher.h b/tests/dfx/event/unittest/mock/conn_hisysevent_matcher.h similarity index 100% rename from tests/core/common/dfx/event/unittest/mock/conn_hisysevent_matcher.h rename to tests/dfx/event/unittest/mock/conn_hisysevent_matcher.h diff --git a/tests/core/common/dfx/event/unittest/mock/disc_hisysevent_matcher.h b/tests/dfx/event/unittest/mock/disc_hisysevent_matcher.h similarity index 100% rename from tests/core/common/dfx/event/unittest/mock/disc_hisysevent_matcher.h rename to tests/dfx/event/unittest/mock/disc_hisysevent_matcher.h diff --git a/tests/core/common/dfx/event/unittest/mock/hisysevent_mock.cpp b/tests/dfx/event/unittest/mock/hisysevent_mock.cpp similarity index 100% rename from tests/core/common/dfx/event/unittest/mock/hisysevent_mock.cpp rename to tests/dfx/event/unittest/mock/hisysevent_mock.cpp diff --git a/tests/core/common/dfx/event/unittest/mock/hisysevent_mock.h b/tests/dfx/event/unittest/mock/hisysevent_mock.h similarity index 100% rename from tests/core/common/dfx/event/unittest/mock/hisysevent_mock.h rename to tests/dfx/event/unittest/mock/hisysevent_mock.h diff --git a/tests/core/common/dfx/event/unittest/mock/lnn_hisysevent_matcher.h b/tests/dfx/event/unittest/mock/lnn_hisysevent_matcher.h similarity index 100% rename from tests/core/common/dfx/event/unittest/mock/lnn_hisysevent_matcher.h rename to tests/dfx/event/unittest/mock/lnn_hisysevent_matcher.h diff --git a/tests/core/common/dfx/event/unittest/mock/softbus_hisysevent_matcher.h b/tests/dfx/event/unittest/mock/softbus_hisysevent_matcher.h similarity index 100% rename from tests/core/common/dfx/event/unittest/mock/softbus_hisysevent_matcher.h rename to tests/dfx/event/unittest/mock/softbus_hisysevent_matcher.h diff --git a/tests/core/common/dfx/event/unittest/mock/trans_hisysevent_matcher.h b/tests/dfx/event/unittest/mock/trans_hisysevent_matcher.h similarity index 100% rename from tests/core/common/dfx/event/unittest/mock/trans_hisysevent_matcher.h rename to tests/dfx/event/unittest/mock/trans_hisysevent_matcher.h diff --git a/tests/core/common/dfx/event/unittest/src/conn_event_test.cpp b/tests/dfx/event/unittest/src/conn_event_test.cpp similarity index 100% rename from tests/core/common/dfx/event/unittest/src/conn_event_test.cpp rename to tests/dfx/event/unittest/src/conn_event_test.cpp diff --git a/tests/core/common/dfx/event/unittest/src/disc_event_test.cpp b/tests/dfx/event/unittest/src/disc_event_test.cpp similarity index 100% rename from tests/core/common/dfx/event/unittest/src/disc_event_test.cpp rename to tests/dfx/event/unittest/src/disc_event_test.cpp diff --git a/tests/core/common/dfx/event/unittest/src/lnn_event_test.cpp b/tests/dfx/event/unittest/src/lnn_event_test.cpp similarity index 100% rename from tests/core/common/dfx/event/unittest/src/lnn_event_test.cpp rename to tests/dfx/event/unittest/src/lnn_event_test.cpp diff --git a/tests/core/common/dfx/event/unittest/src/softbus_event_test.cpp b/tests/dfx/event/unittest/src/softbus_event_test.cpp similarity index 100% rename from tests/core/common/dfx/event/unittest/src/softbus_event_test.cpp rename to tests/dfx/event/unittest/src/softbus_event_test.cpp diff --git a/tests/core/common/dfx/event/unittest/src/trans_event_test.cpp b/tests/dfx/event/unittest/src/trans_event_test.cpp similarity index 100% rename from tests/core/common/dfx/event/unittest/src/trans_event_test.cpp rename to tests/dfx/event/unittest/src/trans_event_test.cpp diff --git a/tests/core/common/dfx/log/BUILD.gn b/tests/dfx/log/BUILD.gn similarity index 100% rename from tests/core/common/dfx/log/BUILD.gn rename to tests/dfx/log/BUILD.gn diff --git a/tests/core/common/dfx/log/unittest/BUILD.gn b/tests/dfx/log/unittest/BUILD.gn similarity index 93% rename from tests/core/common/dfx/log/unittest/BUILD.gn rename to tests/dfx/log/unittest/BUILD.gn index bc9c80877..3aae2b491 100644 --- a/tests/core/common/dfx/log/unittest/BUILD.gn +++ b/tests/dfx/log/unittest/BUILD.gn @@ -12,9 +12,9 @@ # limitations under the License. import("//build/test.gni") -import("../../../../../../dsoftbus.gni") +import("../../../../dsoftbus.gni") -module_output_path = "dsoftbus/common/dfx" +module_output_path = "dsoftbus/dfx" ohos_unittest("SoftBusDfxLogTest") { module_out_path = module_output_path diff --git a/tests/core/common/dfx/log/unittest/include/softbus_log_test_utils.h b/tests/dfx/log/unittest/include/softbus_log_test_utils.h similarity index 100% rename from tests/core/common/dfx/log/unittest/include/softbus_log_test_utils.h rename to tests/dfx/log/unittest/include/softbus_log_test_utils.h diff --git a/tests/core/common/dfx/log/unittest/mock/hilog_mock.cpp b/tests/dfx/log/unittest/mock/hilog_mock.cpp similarity index 100% rename from tests/core/common/dfx/log/unittest/mock/hilog_mock.cpp rename to tests/dfx/log/unittest/mock/hilog_mock.cpp diff --git a/tests/core/common/dfx/log/unittest/mock/hilog_mock.h b/tests/dfx/log/unittest/mock/hilog_mock.h similarity index 100% rename from tests/core/common/dfx/log/unittest/mock/hilog_mock.h rename to tests/dfx/log/unittest/mock/hilog_mock.h diff --git a/tests/core/common/dfx/log/unittest/src/auth_log_test.cpp b/tests/dfx/log/unittest/src/auth_log_test.cpp similarity index 100% rename from tests/core/common/dfx/log/unittest/src/auth_log_test.cpp rename to tests/dfx/log/unittest/src/auth_log_test.cpp diff --git a/tests/core/common/dfx/log/unittest/src/comm_log_test.cpp b/tests/dfx/log/unittest/src/comm_log_test.cpp similarity index 100% rename from tests/core/common/dfx/log/unittest/src/comm_log_test.cpp rename to tests/dfx/log/unittest/src/comm_log_test.cpp diff --git a/tests/core/common/dfx/log/unittest/src/conn_log_test.cpp b/tests/dfx/log/unittest/src/conn_log_test.cpp similarity index 100% rename from tests/core/common/dfx/log/unittest/src/conn_log_test.cpp rename to tests/dfx/log/unittest/src/conn_log_test.cpp diff --git a/tests/core/common/dfx/log/unittest/src/disc_log_test.cpp b/tests/dfx/log/unittest/src/disc_log_test.cpp similarity index 100% rename from tests/core/common/dfx/log/unittest/src/disc_log_test.cpp rename to tests/dfx/log/unittest/src/disc_log_test.cpp diff --git a/tests/core/common/dfx/log/unittest/src/lnn_log_test.cpp b/tests/dfx/log/unittest/src/lnn_log_test.cpp similarity index 100% rename from tests/core/common/dfx/log/unittest/src/lnn_log_test.cpp rename to tests/dfx/log/unittest/src/lnn_log_test.cpp diff --git a/tests/core/common/dfx/log/unittest/src/softbus_log_test.cpp b/tests/dfx/log/unittest/src/softbus_log_test.cpp similarity index 100% rename from tests/core/common/dfx/log/unittest/src/softbus_log_test.cpp rename to tests/dfx/log/unittest/src/softbus_log_test.cpp diff --git a/tests/core/common/dfx/log/unittest/src/trans_log_test.cpp b/tests/dfx/log/unittest/src/trans_log_test.cpp similarity index 100% rename from tests/core/common/dfx/log/unittest/src/trans_log_test.cpp rename to tests/dfx/log/unittest/src/trans_log_test.cpp diff --git a/tests/core/common/dfx/statistics/unittest/BUILD.gn b/tests/dfx/statistics/unittest/BUILD.gn similarity index 94% rename from tests/core/common/dfx/statistics/unittest/BUILD.gn rename to tests/dfx/statistics/unittest/BUILD.gn index 94a3e6bdd..044bb82d5 100644 --- a/tests/core/common/dfx/statistics/unittest/BUILD.gn +++ b/tests/dfx/statistics/unittest/BUILD.gn @@ -14,10 +14,9 @@ import("//build/lite/config/component/lite_component.gni") import("//build/ohos.gni") import("//build/test.gni") -import("../../../../../../dsoftbus.gni") +import("../../../../dsoftbus.gni") module_output_path = "dsoftbus/common" -dsoftbus_root_path = "../../../../../.." ohos_unittest("TransNetworkStatisticsTest") { module_out_path = module_output_path diff --git a/tests/core/common/dfx/statistics/unittest/trans_network_statistics_test.cpp b/tests/dfx/statistics/unittest/trans_network_statistics_test.cpp similarity index 100% rename from tests/core/common/dfx/statistics/unittest/trans_network_statistics_test.cpp rename to tests/dfx/statistics/unittest/trans_network_statistics_test.cpp