unit_test_launcher.h revision a3f6a49ab37290eeeb8db0f41ec0f1cb74a68be7
1// Copyright 2013 The Chromium Authors. All rights reserved. 2// Use of this source code is governed by a BSD-style license that can be 3// found in the LICENSE file. 4 5#ifndef BASE_TEST_LAUNCHER_UNIT_TEST_LAUNCHER_H_ 6#define BASE_TEST_LAUNCHER_UNIT_TEST_LAUNCHER_H_ 7 8#include "base/callback.h" 9 10namespace base { 11 12// Callback that runs a test suite and returns exit code. 13typedef base::Callback<int(void)> RunTestSuiteCallback; 14 15// Launches unit tests in given test suite. Returns exit code. 16int LaunchUnitTests(int argc, 17 char** argv, 18 const RunTestSuiteCallback& run_test_suite); 19 20// Same as above, but always runs tests serially. 21int LaunchUnitTestsSerially(int argc, 22 char** argv, 23 const RunTestSuiteCallback& run_test_suite); 24 25} // namespace base 26 27#endif // BASE_TEST_LAUNCHER_UNIT_TEST_LAUNCHER_H_ 28