Skip to content

Commit

Permalink
types: fix any_buffer tests with MS STL
Browse files Browse the repository at this point in the history
std::string is bigger in debug builds causing build to fail
  • Loading branch information
Hedede committed Mar 9, 2024
1 parent 9880df4 commit 0bb0157
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions types/tests/any_buffer.c++
Original file line number Diff line number Diff line change
@@ -1,14 +1,19 @@
#include <aw/math/matrix4.h>
#include <aw/math/matrix_compare.h>
#include <aw/test/test.h>
#include <aw/types/containers/any_buffer.h>
#include <aw/utility/to_string/math/matrix.h>

#include <aw/test/test.h>

#include <utility>

TestFile( "aw::any_buffer" );

constexpr auto buf_size = std::max({ 32uz, sizeof(std::string) });

Test(any_buffer_basic) {
using namespace std::string_literals;
aw::any_buffer<32> buf;
aw::any_buffer<buf_size> buf;
buf.emplace<std::string>("Test string!"s);
TestEqual(buf.get<std::string>(), "Test string!"s);
}
Expand Down

0 comments on commit 0bb0157

Please sign in to comment.