Luanti 5.15.0-dev
 
Loading...
Searching...
No Matches
TestVoxelManipulator Class Reference
+ Inheritance diagram for TestVoxelManipulator:
+ Collaboration diagram for TestVoxelManipulator:

Public Member Functions

 TestVoxelManipulator ()
 
const char * getName ()
 
void runTests (IGameDef *gamedef)
 
void testBasic (const NodeDefManager *nodedef)
 
void testEmerge (IGameDef *gamedef)
 
void testBlitBack (IGameDef *gamedef)
 
void testBlitBack2 (IGameDef *gamedef)
 
- Public Member Functions inherited from TestBase
bool testModule (IGameDef *gamedef)
 
std::string getTestTempDirectory ()
 
std::string getTestTempFile ()
 
void runTest (const char *name, std::function< void()> &&test)
 

Additional Inherited Members

- Public Attributes inherited from TestBase
u32 num_tests_failed
 
u32 num_tests_run
 

Constructor & Destructor Documentation

◆ TestVoxelManipulator()

TestVoxelManipulator::TestVoxelManipulator ( )
inline

References TestManager::registerTestModule().

+ Here is the call graph for this function:

Member Function Documentation

◆ getName()

const char * TestVoxelManipulator::getName ( )
inlinevirtual

Implements TestBase.

◆ runTests()

void TestVoxelManipulator::runTests ( IGameDef * gamedef)
virtual

Implements TestBase.

References IGameDef::ndef(), TEST, testBasic(), testBlitBack(), testBlitBack2(), and testEmerge().

+ Here is the call graph for this function:

◆ testBasic()

void TestVoxelManipulator::testBasic ( const NodeDefManager * nodedef)

References VoxelManipulator::addArea(), EXCEPTION_CHECK, VoxelManipulator::getNode(), VoxelArea::hasEmptyExtent(), infostream, VoxelManipulator::m_area, VoxelManipulator::print(), VoxelManipulator::setNode(), t_CONTENT_GRASS, and UASSERT.

Referenced by runTests().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ testBlitBack()

void TestVoxelManipulator::testBlitBack ( IGameDef * gamedef)

References MMVManip::clone(), CONTENT_AIR, CONTENT_IGNORE, VoxelManipulator::exists(), DummyMap::fill(), MMVManip::initialEmerge(), VoxelManipulator::setNodeNoEmerge(), t_CONTENT_GRASS, t_CONTENT_STONE, UASSERT, and UASSERTEQ.

Referenced by runTests().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ testBlitBack2()

void TestVoxelManipulator::testBlitBack2 ( IGameDef * gamedef)

References VoxelManipulator::addArea(), MMVManip::blitBackAll(), CONTENT_AIR, CONTENT_IGNORE, DummyMap::fill(), MMVManip::getCoveredBlocks(), MAP_BLOCKSIZE, VoxelManipulator::setFlags(), VoxelManipulator::setNodeNoEmerge(), t_CONTENT_LAVA, t_CONTENT_TORCH, UASSERT, UASSERTEQ, VOXELFLAG_NO_DATA, x, y, and z.

Referenced by runTests().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ testEmerge()

void TestVoxelManipulator::testEmerge ( IGameDef * gamedef)

References VoxelManipulator::clear(), CONTENT_AIR, CONTENT_IGNORE, VoxelManipulator::exists(), DummyMap::fill(), MapNode::getContent(), VoxelArea::getExtent(), VoxelManipulator::getNodeNoExNoEmerge(), VoxelArea::hasEmptyExtent(), MMVManip::initialEmerge(), MMVManip::isOrphan(), VoxelManipulator::m_area, MAP_BLOCKSIZE, VoxelArea::MaxEdge, VoxelArea::MinEdge, t_CONTENT_BRICK, UASSERT, and UASSERTEQ.

Referenced by runTests().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

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