Skip to content

Commit

Permalink
Add debug output to allocation_error_test
Browse files Browse the repository at this point in the history
  • Loading branch information
Flamefire committed Jan 4, 2025
1 parent 48c3594 commit 6d3de0f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion test/test_06_state.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#include "kaguya/kaguya.hpp"
#include "test_util.hpp"
#include <iostream>

KAGUYA_TEST_GROUP_START(test_06_state)

Expand Down Expand Up @@ -356,7 +357,8 @@ KAGUYA_TEST_FUNCTION_DEF(allocation_error_test)(kaguya::State &) {
state["data"] = kaguya::NewTable();
Foo foodata;
for (size_t i = 0; i < alloclimit; ++i) {
state("data[" + to_string(i) + "] ='abc'");
std::cout << i << '/' << alloclimit << '\n';
state("data[" + to_string(i) + "] = 'xyz'");
state["data"][i + alloclimit * 2] = alloctest();
state["data"][i + alloclimit * 3] = 1;
state["data"][i + alloclimit * 4] = "str";
Expand Down

0 comments on commit 6d3de0f

Please sign in to comment.