1# Copyright 2024 The Pigweed Authors 2# 3# Licensed under the Apache License, Version 2.0 (the "License"); you may not 4# use this file except in compliance with the License. You may obtain a copy of 5# the License at 6# 7# https://www.apache.org/licenses/LICENSE-2.0 8# 9# Unless required by applicable law or agreed to in writing, software 10# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12# License for the specific language governing permissions and limitations under 13# the License. 14 15import("//build_overrides/pigweed.gni") 16 17import("$dir_pw_unit_test/test.gni") 18 19# Examples -- Compile-only tests 20 21pw_test("input") { 22 enable_if = current_os == "linux" 23 deps = [ 24 "$dir_pw_digital_io_linux", 25 "$dir_pw_log", 26 ] 27 sources = [ "input.cc" ] 28} 29 30pw_test("output") { 31 enable_if = current_os == "linux" 32 deps = [ "$dir_pw_digital_io_linux" ] 33 sources = [ "output.cc" ] 34} 35 36pw_test("interrupt") { 37 enable_if = current_os == "linux" 38 deps = [ 39 "$dir_pw_chrono:system_clock", 40 "$dir_pw_digital_io_linux", 41 "$dir_pw_log", 42 "$dir_pw_thread:sleep", 43 ] 44 sources = [ "interrupt.cc" ] 45} 46 47pw_test_group("examples") { 48 tests = [ 49 ":input", 50 ":output", 51 ":interrupt", 52 ] 53} 54