rm -r -f autom4te.cache
./config/autorun.sh
-./configure --disable-assert=no
+./configure --enable-assert
make
built_argv[x++]= strdup(_exectuble_with_path.c_str());
- for (Options::const_iterator iter= _options.begin(); iter != _options.end(); iter++)
+ for (Options::const_iterator iter= _options.begin(); iter != _options.end(); ++iter)
{
built_argv[x++]= strdup((*iter).first.c_str());
if ((*iter).second.empty() == false)
void create_core(void)
{
-#ifdef TARGET_OS_OSX
- return;
+#if defined(TARGET_OS_OSX) && TARGET_OS_OSX
+ if (TARGET_OS_OSX)
+ {
+ return;
+ }
#endif
if (getenv("YATL_COREDUMP"))
{
namespace libtest {
struct failed_st {
- failed_st(const std::string collection_arg, const std::string test_arg) :
+ failed_st(const std::string& collection_arg, const std::string& test_arg) :
collection(collection_arg),
test(test_arg)
{ }
void print_failed_test(void)
{
- for (Failures::iterator iter= failures.begin(); iter != failures.end(); iter++)
+ for (Failures::iterator iter= failures.begin(); iter != failures.end(); ++iter)
{
Error << "\t" << (*iter).collection << " " << (*iter).test;
}
strncpy(_mesg, last_error, sizeof(_mesg));
- snprintf(_error_message, sizeof(_error_message), "%s", last_error);
+ snprintf(_error_message, sizeof(_error_message), "%.*s", last_error_length, last_error);
}
static bool _disabled= false;
return (getenv("LIBTEST_LOCAL"));
}
+static bool _is_massive= false;
+void is_massive(bool arg)
+{
+ _is_massive= arg;
+}
+
+bool is_massive()
+{
+ return _is_massive;
+}
+
} // namespace libtest
LIBTEST_API
bool test_is_local();
+LIBTEST_API
+void is_massive(bool);
+
+LIBTEST_API
+bool is_massive();
+
} // namespace libtest
+m4_include([libtest/m4/ax_lib_mysql.m4])
+m4_include([libtest/m4/ax_prog_mysqld.m4])
+
AX_LIB_MYSQL([5.0])
AM_CONDITIONAL(HAVE_LIBMYSQL, test "x${found_mysql}" = "xyes")
AS_IF([test "x${found_mysql}" = "xyes"],
}
}
+ if ((bool(getenv("YATL_RUN_MASSIVE_TESTS"))) or opt_massive)
+ {
+ opt_massive= true;
+ }
+
if (opt_quiet)
{
close(STDOUT_FILENO);
}
+ if (opt_massive)
+ {
+ is_massive(opt_massive);
+ }
+
char buffer[1024];
if (getenv("LIBTEST_TMP"))
{
server->build(argc, argv);
+#if 0
if (false)
{
Out << "Pausing for startup, hit return when ready.";
std::string gdb_command= server->base_command();
- std::string options;
-#if 0
- Out << "run " << server->args(options);
-#endif
getchar();
}
- else if (server->start() == false)
+ else
+#endif
+ if (server->start() == false)
{
delete server;
return false;
server->build(argc, argv);
+#if 0
if (false)
{
Out << "Pausing for startup, hit return when ready.";
std::string gdb_command= server->base_command();
std::string options;
-#if 0
Out << "run " << server->args(options);
-#endif
getchar();
}
- else if (server->start() == false)
+ else
+#endif
+ if (server->start() == false)
{
Error << "Failed to start " << *server;
delete server;
static test_return_t var_tmp_test(void *)
{
FILE *file= fopen("var/tmp/junk", "w+");
- char buffer[1024];
test_true(file);
fclose(file);
return TEST_SUCCESS;