Lines Matching defs:test

34 #include "gtest/gtest-death-test.h"
83 // The default death test style.
89 "Indicates how to run a death test in a forked child process: "
90 "\"threadsafe\" (child process re-executes the test binary "
91 "from the beginning, running only the specific death test) or "
92 "\"fast\" (child process runs the death test immediately "
111 "the single death test to run, and a file descriptor to "
115 "death test. FOR INTERNAL USE ONLY.");
123 // child process of a fast style death test.
129 // executing in the context of the death test child process. Tools such as
224 // Generates a textual failure message when a death test finds more than
231 << " in a threaded context. For this test, " << GTEST_NAME_ << " ";
240 // Flag characters for reporting a death test that did not die.
246 // An enumeration describing all of the possible ways that a death test can
247 // conclude. DIED means that the process died while executing the test
248 // code; LIVED means that process lived beyond the end of the test code;
249 // RETURNED means that the test statement attempted to execute a return
250 // statement, which is not allowed; THREW means that the test statement
251 // returned control by throwing an exception. IN_PROGRESS means the test
258 // exec-style death test child process, in which case the error
264 // death test child process, which operates on a very small stack. Use
319 // This is called from a death test parent process to read a failure
320 // message from the death test child process and log it with the FATAL
339 GTEST_LOG_(FATAL) << "Error while reading death test internal: "
344 // Death test constructor. Increments the running death test count
345 // for the current test.
349 DeathTestAbort("Cannot run a death test outside of a TEST or "
354 // Creates and returns a death test by dispatching to the current
355 // death test factory.
357 const char* file, int line, DeathTest** test) {
359 statement, regex, file, line, test);
404 // test child process via a pipe, interprets it to set the outcome_
413 // The regular expression which test output must match. DeathTestImpl
416 // True if the death test child process has been successfully spawned.
420 // How the death test concluded.
433 // test child process via a pipe, interprets it to set the outcome_
441 // failure of the death test) or until the pipe is closed (signifying
465 GTEST_LOG_(FATAL) << "Death test child process reported "
470 GTEST_LOG_(FATAL) << "Read from death test child process failed: "
477 // Signals that the death test code which should have exited, didn't.
478 // Should be called only in a death test child process.
482 // The parent process considers the death test to be a failure if
501 // Returns an indented copy of stderr output for a death test.
502 // This makes distinguishing death test output lines from regular log lines
519 // Assesses the success or failure of a death test, using both private
523 // outcome: An enumeration describing how the death test
524 // concluded: DIED, LIVED, THREW, or RETURNED. The death test
531 // the test's captured standard error output; the death test
536 // this particular death test, which fails if it is false
540 // reported. Also sets the last death test message string.
550 buffer << "Death test: " << statement() << "\n";
561 buffer << " Result: illegal return in test statement.\n"
583 << "DeathTest::Passed somehow called before conclusion of test";
614 // determines whether to fail the test.
632 // The name of the file in which the death test is located.
634 // The line number on which the death test is located.
647 // Waits for the child in a death test to exit, returning its exit
690 // The AssumeRole process for a Windows death test. It creates a child
692 // death test. The child process is given the --gtest_filter and
694 // current death test only.
710 // a death test.
798 // PID of child process during death test; 0 in the child process itself.
807 // Waits for the child in a death test to exit, returning its exit
822 // A concrete death test class that forks, then immediately runs the test
831 // The AssumeRole process for a fork-and-run death test. It implements a
849 // there are multiple threads running before the death test, and another
864 // down in death test subprocesses.
876 // A concrete death test class that forks and re-executes the main
878 // only this specific death test to be run.
896 // The name of the file in which the death test is located.
898 // The line number on which the death test is located.
936 // threadsafe-style death test process.
957 // The main function for a threadsafe-style death test child process.
964 // We need to execute the test program in the same environment where
979 // invoke the test program via a valid path that contains at least
1014 // a thread-safe manner and instructs it to run the death test. The
1030 // We need to execute the test program in the same environment where
1114 // The AssumeRole process for a fork-and-exec death test. It re-executes the
1117 // death test to be re-run.
1168 // by the "test" argument to its address. If the test should be
1173 DeathTest** test) {
1183 "Death test count (" + StreamableToString(death_test_index)
1191 *test = NULL;
1200 *test = new WindowsDeathTest(statement, regex, file, line);
1206 *test = new ExecDeathTest(statement, regex, file, line);
1208 *test = new NoExecDeathTest(statement, regex);
1215 "Unknown death test style \"" + GTEST_FLAG(death_test_style)