|
Ninja
|
Tests of builds involving deps logs necessarily must span multiple builds. More...

Public Member Functions | |
| void | AddAssertionFailure () |
| void | AddCatRule (State *state) |
| Add a "cat" rule to state. More... | |
| int | AssertionFailures () const |
| BuildWithDepsLogTest () | |
| bool | Check (bool condition, const char *file, int line, const char *error) |
| void | Dirty (const string &path) |
| bool | Failed () const |
| Node * | GetNode (const string &path) |
| Short way to get a Node by its path from state_. More... | |
| virtual bool | IsPathDead (StringPiece s) const |
| Return if a given output is no longer part of the build manifest. More... | |
| BuildConfig | MakeConfig () |
| void | RebuildTarget (const string &target, const char *manifest, const char *log_path=NULL, const char *deps_path=NULL, State *state=NULL) |
| Rebuild target in the 'working tree' (fs_). More... | |
| virtual void | Run ()=0 |
| virtual void | SetUp () |
| virtual void | TearDown () |
Public Attributes | |
| void * | builder_ |
| Shadow parent class builder_ so we don't accidentally use it. More... | |
| FakeCommandRunner | command_runner_ |
| BuildConfig | config_ |
| VirtualFileSystem | fs_ |
| State | state_ |
| BuildStatus | status_ |
| ScopedTempDir | temp_dir_ |
Tests of builds involving deps logs necessarily must span multiple builds.
We reuse methods on BuildTest but not the builder_ it sets up, because we want pristine objects for each build.
Definition at line 1802 of file build_test.cc.
|
inline |
Definition at line 1803 of file build_test.cc.
|
inlineinherited |
Definition at line 42 of file test.h.
References testing::Test::assertion_failures_.
|
inherited |
Add a "cat" rule to state.
Used by some tests; it's otherwise done by the ctor to state_.
Definition at line 87 of file test.cc.
References AssertParse().
Referenced by BuildTest::RebuildTarget(), and StateTestWithBuiltinRules::StateTestWithBuiltinRules().
|
inlineinherited |
Definition at line 41 of file test.h.
References testing::Test::assertion_failures_.
|
inherited |
Definition at line 119 of file ninja_test.cc.
References testing::Test::failed_, printer, and LinePrinter::PrintOnNewLine().
|
inherited |
Definition at line 620 of file build_test.cc.
References StateTestWithBuiltinRules::GetNode(), Node::in_edge(), Node::MarkDirty(), and Node::MarkMissing().
|
inlineinherited |
|
inherited |
Short way to get a Node by its path from state_.
Definition at line 93 of file test.cc.
References EXPECT_FALSE, State::GetNode(), and StateTestWithBuiltinRules::state_.
Referenced by BuildTest::Dirty(), and PlanTest::TestPoolWithDepthOne().
|
inlinevirtualinherited |
Return if a given output is no longer part of the build manifest.
This is only called during recompaction and doesn't have to be fast.
Implements BuildLogUser.
Definition at line 481 of file build_test.cc.
|
inlineinherited |
Definition at line 493 of file build_test.cc.
References BuildConfig::QUIET, and BuildConfig::verbosity.
|
inherited |
Rebuild target in the 'working tree' (fs_).
State of command_runner_ and logs contents (if specified) ARE MODIFIED. Handy to check for NOOP builds, and higher-level rebuild tests.
Definition at line 507 of file build_test.cc.
References StateTestWithBuiltinRules::AddCatRule(), Builder::AddTarget(), Builder::AlreadyUpToDate(), ASSERT_EQ, ASSERT_NO_FATAL_FAILURE, ASSERT_TRUE, AssertParse(), Builder::Build(), Builder::command_runner_, BuildTest::command_runner_, FakeCommandRunner::commands_ran_, BuildTest::config_, EXPECT_TRUE, BuildTest::fs_, BuildLog::Load(), DepsLog::Load(), BuildLog::OpenForWrite(), and DepsLog::OpenForWrite().
|
pure virtualinherited |
Referenced by main().
|
inlinevirtual |
Reimplemented from BuildTest.
Definition at line 1805 of file build_test.cc.
References ScopedTempDir::CreateAndEnter(), BuildTest::SetUp(), and temp_dir_.
|
inlinevirtual |
Reimplemented from testing::Test.
Definition at line 1811 of file build_test.cc.
References ScopedTempDir::Cleanup(), and temp_dir_.
| void* BuildWithDepsLogTest::builder_ |
Shadow parent class builder_ so we don't accidentally use it.
Definition at line 1818 of file build_test.cc.
|
inherited |
Definition at line 500 of file build_test.cc.
Referenced by BuildTest::RebuildTarget(), and BuildTest::SetUp().
|
inherited |
Definition at line 499 of file build_test.cc.
Referenced by BuildDryRun::BuildDryRun(), and BuildTest::RebuildTarget().
|
inherited |
Definition at line 501 of file build_test.cc.
Referenced by BuildTest::RebuildTarget(), and BuildTest::SetUp().
|
inherited |
Definition at line 123 of file test.h.
Referenced by StateTestWithBuiltinRules::GetNode(), BuildTest::SetUp(), StateTestWithBuiltinRules::StateTestWithBuiltinRules(), and PlanTest::TestPoolWithDepthOne().
|
inherited |
Definition at line 504 of file build_test.cc.
| ScopedTempDir BuildWithDepsLogTest::temp_dir_ |
Definition at line 1815 of file build_test.cc.
Referenced by SetUp(), and TearDown().
1.8.14