Public Member Functions | Public Attributes
BuildTest Struct Reference
Inheritance diagram for BuildTest:
Inheritance graph

List of all members.

Public Member Functions

void AddCatRule (State *state)
 Add a "cat" rule to state.
 BuildTest ()
void Dirty (const string &path)
NodeGetNode (const string &path)
 Short way to get a Node by its path from state_.
BuildConfig MakeConfig ()
void RebuildTarget (const string &target, const char *manifest, const char *log_path=NULL, const char *deps_path=NULL)
 Rebuild target in the 'working tree' (fs_).
virtual void SetUp ()
 ~BuildTest ()

Public Attributes

Builder builder_
FakeCommandRunner command_runner_
BuildConfig config_
VirtualFileSystem fs_
State state_
BuildStatus status_

Detailed Description

Definition at line 415 of file

Constructor & Destructor Documentation

BuildTest::BuildTest ( ) [inline]

Definition at line 416 of file

BuildTest::~BuildTest ( ) [inline]

Definition at line 434 of file

References builder_, and Builder::command_runner_.

Member Function Documentation

void StateTestWithBuiltinRules::AddCatRule ( State state) [inherited]

Add a "cat" rule to state.

Used by some tests; it's otherwise done by the ctor to state_.

Definition at line 80 of file

References AssertParse().

Referenced by RebuildTarget(), and StateTestWithBuiltinRules::StateTestWithBuiltinRules().

void BuildTest::Dirty ( const string &  path)
Node * StateTestWithBuiltinRules::GetNode ( const string &  path) [inherited]

Short way to get a Node by its path from state_.

Definition at line 86 of file

References State::GetNode(), and StateTestWithBuiltinRules::state_.

Referenced by Dirty().

Definition at line 448 of file

References BuildConfig::QUIET, and BuildConfig::verbosity.

void BuildTest::RebuildTarget ( const string &  target,
const char *  manifest,
const char *  log_path = NULL,
const char *  deps_path = NULL 

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 462 of file

References StateTestWithBuiltinRules::AddCatRule(), Builder::AddTarget(), Builder::AlreadyUpToDate(), AssertParse(), Builder::Build(), Builder::command_runner_, command_runner_, FakeCommandRunner::commands_ran_, config_, fs_, BuildLog::Load(), DepsLog::Load(), BuildLog::OpenForWrite(), and DepsLog::OpenForWrite().

virtual void BuildTest::SetUp ( ) [inline, virtual]

Member Data Documentation

Reimplemented in BuildWithDepsLogTest.

Definition at line 457 of file

Referenced by BuildWithLogTest::BuildWithLogTest(), SetUp(), and ~BuildTest().

Definition at line 455 of file

Referenced by RebuildTarget(), and SetUp().

Definition at line 454 of file

Referenced by BuildDryRun::BuildDryRun(), and RebuildTarget().

Definition at line 456 of file

Referenced by RebuildTarget(), and SetUp().

Definition at line 459 of file

The documentation for this struct was generated from the following file: