added a "test mode" for aos::Die and used it
ipc_stress_test was getting slowed down by disk I/O because of the
aos_fatal_error files getting written to /tmp and the stdout messages
that gtest doesn't capture were annoying, so I added a setting for
aos::Die to not do those things and used it in the ipc_stress_test
tests.
diff --git a/aos/common/condition_test.cc b/aos/common/condition_test.cc
index fca2820..7e74918 100644
--- a/aos/common/condition_test.cc
+++ b/aos/common/condition_test.cc
@@ -13,6 +13,7 @@
#include "aos/atom_code/ipc_lib/core_lib.h"
#include "aos/common/logging/logging.h"
#include "aos/common/macros.h"
+#include "aos/common/die.h"
using ::aos::time::Time;
using ::aos::common::testing::GlobalCoreInstance;
@@ -43,6 +44,11 @@
time::SleepFor(::Time::InSeconds(0.008));
}
+ protected:
+ void SetUp() override {
+ SetDieTestMode(true);
+ }
+
private:
DISALLOW_COPY_AND_ASSIGN(ConditionTest);
};