1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-06 09:09:40 +02:00

Fix some warnings, Add headers to the solution

This commit is contained in:
Dmitry Orlov
2021-09-05 15:23:36 +03:00
committed by Andrii Danylchenko
parent 093076c6d0
commit ec7453ae85
6 changed files with 49 additions and 6 deletions

View File

@@ -40,9 +40,11 @@ set(test_SRCS
erm/ERM_MF.cpp
erm/ERM_TM_T.cpp
erm/ERM_VR.cpp
erm/ERM_UN.cpp
erm/ERMPersistenceTest.cpp
erm/ExamplesTest.cpp
erm/interpretter/ERM_VR.cpp
erm/interpretter/ERM_UN.cpp
erm/interpretter/ErmRunner.cpp
events/ApplyDamageTest.cpp

View File

@@ -0,0 +1,28 @@
/*
* ERM_UN.cpp, part of VCMI engine
*
* Authors: listed in file AUTHORS in main folder
*
* License: GNU General Public License v2.0 or later
* Full text of license available in license.txt file, in main folder
*
*/
#include "StdInc.h"
#include "ErmRunner.h"
namespace test
{
namespace scripting
{
using namespace ::testing;
TEST(ERM_UN_B, AnyInteger_ShouldGenerateIntToStringConversionAndSetStatement)
{
LuaStrings lua = ErmRunner::convertErmToLua({ "!#UN:B;" });
ASSERT_EQ(lua.lines.size(), 9) << lua.text;
EXPECT_EQ(lua.lines[ErmRunner::REGULAR_INSTRUCTION_FIRST_LINE], "ERM.UN():B(x)");
}
}
}