diff options
| author | Stefan Boberg <[email protected]> | 2021-09-29 22:26:07 +0200 |
|---|---|---|
| committer | Stefan Boberg <[email protected]> | 2021-09-29 22:26:07 +0200 |
| commit | 24d571fc92761d84a186a01803036720b8c5fba9 (patch) | |
| tree | 2a7321fe2172e8f49d44872f078193ecf3b02bd1 | |
| parent | stats: added Histogram, UniformSample and SampleSnapshot (diff) | |
| parent | Prevent mesh tests to crash by moving behind define. (diff) | |
| download | zen-24d571fc92761d84a186a01803036720b8c5fba9.tar.xz zen-24d571fc92761d84a186a01803036720b8c5fba9.zip | |
Merge branch 'main' of https://github.com/EpicGames/zen
| -rw-r--r-- | zencore/filesystem.cpp | 3 | ||||
| -rw-r--r-- | zencore/include/zencore/string.h | 10 | ||||
| -rw-r--r-- | zenserver-test/zenserver-test.cpp | 3 | ||||
| -rw-r--r-- | zenserver/upstream/jupiter.h | 1 |
4 files changed, 10 insertions, 7 deletions
diff --git a/zencore/filesystem.cpp b/zencore/filesystem.cpp index 54ab2ad85..a06c00e41 100644 --- a/zencore/filesystem.cpp +++ b/zencore/filesystem.cpp @@ -816,7 +816,8 @@ TEST_CASE("filesystem") // GetExePath path BinPath = GetRunningExecutablePath(); - CHECK(BinPath.stem() == "zencore-test"); + const bool ExpectedExe = BinPath.stem() == "zencore-test" || BinPath.stem() == "zenserver-test"; + CHECK(ExpectedExe); CHECK(is_regular_file(BinPath)); // PathFromHandle diff --git a/zencore/include/zencore/string.h b/zencore/include/zencore/string.h index 2c0d10577..c205b199d 100644 --- a/zencore/include/zencore/string.h +++ b/zencore/include/zencore/string.h @@ -219,7 +219,7 @@ public: return AppendRange(String.data(), String.data() + String.size()); } - inline void RemoveSuffix(int32_t Count) + inline void RemoveSuffix(uint32_t Count) { ZEN_ASSERT(Count <= Size()); m_CurPos -= Count; @@ -717,7 +717,7 @@ public: template<typename CharType> constexpr inline bool Contains(CharType Char) const { - using UnsignedCharType = std::make_unsigned<CharType>::type; + using UnsignedCharType = typename std::make_unsigned<CharType>::type; return !!TestImpl((UnsignedCharType)Char); } @@ -726,7 +726,7 @@ public: template<typename CharType> constexpr inline uint64_t Test(CharType Char) const { - using UnsignedCharType = std::make_unsigned<CharType>::type; + using UnsignedCharType = typename std::make_unsigned<CharType>::type; return TestImpl((UnsignedCharType)Char); } @@ -734,7 +734,7 @@ public: /** Create new set with specified character in it */ constexpr inline AsciiSet operator+(char Char) const { - using UnsignedCharType = std::make_unsigned<char>::type; + using UnsignedCharType = typename std::make_unsigned<char>::type; InitData Bitset = {LoMask, HiMask}; SetImpl(Bitset, (UnsignedCharType)Char); @@ -960,7 +960,7 @@ private: template<typename CharType, int N> static constexpr InitData StringToBitset(const CharType (&Chars)[N]) { - using UnsignedCharType = std::make_unsigned<CharType>::type; + using UnsignedCharType = typename std::make_unsigned<CharType>::type; InitData Bitset = {0, 0}; for (int I = 0; I < N - 1; ++I) diff --git a/zenserver-test/zenserver-test.cpp b/zenserver-test/zenserver-test.cpp index 9b5a48128..6461b76c2 100644 --- a/zenserver-test/zenserver-test.cpp +++ b/zenserver-test/zenserver-test.cpp @@ -1963,6 +1963,8 @@ TEST_CASE("exec.basic") TEST_CASE("mesh.basic") { +// --mesh option only available with ZEN_ENABLE_MESH +# if ZEN_ENABLE_MESH using namespace std::literals; const int kInstanceCount = 4; @@ -1987,6 +1989,7 @@ TEST_CASE("mesh.basic") Instance->WaitUntilReady(); } +# endif } class ZenServerTestHelper diff --git a/zenserver/upstream/jupiter.h b/zenserver/upstream/jupiter.h index f05e059bd..d8844279e 100644 --- a/zenserver/upstream/jupiter.h +++ b/zenserver/upstream/jupiter.h @@ -51,7 +51,6 @@ struct CloudCacheResult int32_t ErrorCode = {}; std::string Reason; bool Success = false; - bool Exists = false; }; /** |