Skip to content

Commit

Permalink
Fix linux deps, add makes UnitTestUtils independent source set
Browse files Browse the repository at this point in the history
  • Loading branch information
jlatusek committed Jan 11, 2024
1 parent cb0c0a9 commit 8313e68
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
3 changes: 1 addition & 2 deletions examples/placeholder/linux/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,7 @@ executable("chip-${chip_tests_zap_config}") {
"${chip_root}/src/app/tests/suites/credentials:dac_provider",
"${chip_root}/src/app/tests/suites/pics",
"${chip_root}/src/lib",
"${chip_root}/src/lib/support:testing", # For sleepMillis. TODO: this is
# odd and should be fixed
"${chip_root}/src/lib/support:test_utils",
"${chip_root}/src/platform/logging:headers",
"${chip_root}/third_party/jsoncpp",
]
Expand Down
10 changes: 8 additions & 2 deletions src/lib/support/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -297,6 +297,13 @@ static_library("support") {
}
}

source_set("test_utils") {
sources = [
"UnitTestUtils.cpp",
"UnitTestUtils.h",
]
}

static_library("testing") {
output_name = "libSupportTesting"
output_dir = "${root_out_dir}/lib"
Expand All @@ -305,12 +312,11 @@ static_library("testing") {
"UnitTestExtendedAssertions.h",
"UnitTestRegistration.cpp",
"UnitTestRegistration.h",
"UnitTestUtils.cpp",
"UnitTestUtils.h",
]

public_deps = [
":support",
":test_utils",
"${chip_root}/src/lib/core",
"${chip_root}/src/platform",
"${nlassert_root}:nlassert",
Expand Down

0 comments on commit 8313e68

Please sign in to comment.