Remove custom main() from test_PipeCapture (!22)

After removing Glib::thread_init() from test_PipeCapture's main() all it
does is exactly what the built in Google Test main() does [1][2].  So
use that instead like the other unit test programs do.

[1] Google Test, Primer, Writing the main() Function
    https://github.com/google/googletest/blob/master/googletest/docs/primer.md#writing-the-main-function

[2] Google Test 1.8.0, gtest_main.cc::main()
    file: lib/gtest/src/gtest_main.cc
    https://github.com/google/googletest/blob/release-1.8.0/googletest/src/gtest_main.cc#L34

Closes !22 - Increase minimums to libparted 2.2 and glibmm 2.32
This commit is contained in:
Mike Fleetwood 2019-01-20 10:24:44 +00:00 committed by Curtis Gedak
parent 80d6394684
commit c8a6866716
2 changed files with 1 additions and 14 deletions

View File

@ -34,5 +34,4 @@ test_PasswordRAMStore_LDADD = \
test_PipeCapture_SOURCES = test_PipeCapture.cc test_PipeCapture_SOURCES = test_PipeCapture.cc
test_PipeCapture_LDADD = \ test_PipeCapture_LDADD = \
$(top_builddir)/src/PipeCapture.$(OBJEXT) \ $(top_builddir)/src/PipeCapture.$(OBJEXT) \
$(GTEST_LIBS) \ $(LDADD)
$(top_builddir)/lib/gtest/lib/libgtest.la

View File

@ -411,15 +411,3 @@ TEST_F( PipeCaptureTest, LineDisciplineSkipCtrlAB )
} }
} // namespace GParted } // namespace GParted
// Custom Google Test main().
// Reference:
// * Google Test, Primer, Writing the main() Function
// https://github.com/google/googletest/blob/master/googletest/docs/primer.md#writing-the-main-function
int main( int argc, char **argv )
{
printf("Running main() from %s\n", __FILE__ );
testing::InitGoogleTest( &argc, argv );
return RUN_ALL_TESTS();
}