From f434dc2f9579aeea0c7afe6fa8b78d56c560707f Mon Sep 17 00:00:00 2001 From: Charles Kerr Date: Thu, 24 May 2012 10:00:15 -0500 Subject: add a 'hello world' test for instantiating IndicatorPower --- tests/Makefile.am | 37 +++++++++++++++++++++++++------------ 1 file changed, 25 insertions(+), 12 deletions(-) (limited to 'tests') diff --git a/tests/Makefile.am b/tests/Makefile.am index 87dd606..341abdd 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -2,9 +2,6 @@ TESTS = CLEANFILES = check_PROGRAMS = -AM_CPPFLAGS = $(GTEST_CPPFLAGS) -I${top_srcdir}/src -Wall -Werror -AM_CXXFLAGS = $(GTEST_CXXFLAGS) - ### ### ### @@ -12,27 +9,43 @@ AM_CXXFLAGS = $(GTEST_CXXFLAGS) # stock UMB tests on user-visible strings include $(srcdir)/Makefile.am.strings +check_LIBRARIES = libgtest.a +nodist_libgtest_a_SOURCES = \ + $(GTEST_SOURCE)/src/gtest-all.cc \ + $(GTEST_SOURCE)/src/gtest_main.cc + +AM_CPPFLAGS = $(GTEST_CPPFLAGS) -I${top_srcdir}/src -Wall -Werror +AM_CXXFLAGS = $(GTEST_CXXFLAGS) + ### ### ### -TESTS += test-device -check_PROGRAMS += test-device -test_device_SOURCES = test-device.cc -test_device_LDADD = \ +TEST_LIBS = \ $(top_builddir)/src/libpower.la \ $(INDICATOR_LIBS) \ $(UPOWER_LIBS) \ $(COVERAGE_LDFLAGS) \ libgtest.a -test_device_CPPFLAGS = \ +TEST_CPPFLAGS = \ $(AM_CPPFLAGS) \ $(UPOWER_CFLAGS) \ $(INDICATOR_CFLAGS) \ $(COVERAGE_CFLAGS) -check_LIBRARIES = libgtest.a -nodist_libgtest_a_SOURCES = \ - $(GTEST_SOURCE)/src/gtest-all.cc \ - $(GTEST_SOURCE)/src/gtest_main.cc +TESTS += test-device +check_PROGRAMS += test-device +test_device_SOURCES = test-device.cc +test_device_LDADD = $(TEST_LIBS) +test_device_CPPFLAGS = $(TEST_CPPFLAGS) + +TESTS += test-indicator +check_PROGRAMS += test-indicator +test_indicator_SOURCES = test-indicator.cc +test_indicator_LDADD = $(TEST_LIBS) +test_indicator_CPPFLAGS = $(TEST_CPPFLAGS) + +### +### +### -- cgit v1.2.3