1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Make unittests less reliant on files in the source distribution

This commit is contained in:
sfan5 2024-01-10 19:10:58 +01:00
parent 863c9b55b4
commit 133f706bf3
11 changed files with 70 additions and 79 deletions

View file

@ -22,8 +22,11 @@ with this program; if not, write to the Free Software Foundation, Inc.,
class MockServer : public Server
{
public:
MockServer() : Server(TEST_WORLDDIR, SubgameSpec("fakespec", "fakespec"), true,
Address(), true, nullptr)
/* Set path_world to a real existing folder if you plan to initialize scripting! */
MockServer(const std::string &path_world = "fakepath") :
Server(path_world, SubgameSpec("fakespec", "fakespec"), true,
Address(), true, nullptr
)
{}
private: