<commit_before>
// Tests.cpp
// These tests execute some basic scenarios that should be useful for regression testing.
// Run manually for now

#include "sc2lib/sc2_lib.h"
#include "sc2api/sc2_api.h"
#include "sc2api/sc2_interfaces.h"
#include "sc2api/sc2_score.h"
#include "sc2api/sc2_map_info.h"
#include "sc2utils/sc2_manage_process.h"
#include "sc2api/sc2_game_settings.h"
#include "sc2api/sc2_proto_interface.h"
#include "sc2api/sc2_interfaces.h"
#include "sc2api/sc2_proto_to_pods.h"
#include "s2clientprotocol/sc2api.pb.h"
#include "sc2api/sc2_server.h"
#include "sc2api/sc2_connection.h"
#include "sc2api/sc2_args.h"
#include "sc2api/sc2_client.h"
#include "sc2api/sc2_proto_to_pods.h"
#include "sc2utils/sc2_arg_parser.h"
#include "civetweb.h"

#include <iostream>
#include <fstream>
#include <string>
#include <map>

#include "Types.h"
#include "LadderConfig.h"
#include "LadderManager.h"
#include "MatchupList.h"

bool TestMatch_Bot1Eliminated(int argc, char** argv) {
	try
	{
		// Write out the matchup file before launching LadderManager so we can dictate the bot load order
		std::ofstream myfile;
		myfile.open("./tests/tests/test_configs/TestMatch_Bot1Eliminated/matchuplist");
		myfile << "\"DebugBot1\" \"DebugBot2\" Ladder2017Season3/InterloperLE.SC2Map";
		myfile.close();

		// Run LadderManager
		LadderManager LadderMan(argc, argv, "./tests/tests/test_configs/TestMatch_Bot1Eliminated/LadderManager.conf");
		if (LadderMan.LoadSetup())
		{
			LadderMan.RunLadderManager();
		}
		return true;
	}
	catch (const std::exception& e)
	{
		std::cerr << "Exception in TestMatch_Bot1Eliminated" << std::endl;
		std::cerr << e.what() << std::endl;
		return false;
	}
}

// Handy macro from: s2client-api/tests/all_tests.cc
#define TEST(X)                                                     \<commit_msg>Update test config references in code<commit_after>
// Tests.cpp
// These tests execute some basic scenarios that should be useful for regression testing.
// Run manually for now

#include "sc2lib/sc2_lib.h"
#include "sc2api/sc2_api.h"
#include "sc2api/sc2_interfaces.h"
#include "sc2api/sc2_score.h"
#include "sc2api/sc2_map_info.h"
#include "sc2utils/sc2_manage_process.h"
#include "sc2api/sc2_game_settings.h"
#include "sc2api/sc2_proto_interface.h"
#include "sc2api/sc2_interfaces.h"
#include "sc2api/sc2_proto_to_pods.h"
#include "s2clientprotocol/sc2api.pb.h"
#include "sc2api/sc2_server.h"
#include "sc2api/sc2_connection.h"
#include "sc2api/sc2_args.h"
#include "sc2api/sc2_client.h"
#include "sc2api/sc2_proto_to_pods.h"
#include "sc2utils/sc2_arg_parser.h"
#include "civetweb.h"

#include <iostream>
#include <fstream>
#include <string>
#include <map>

#include "Types.h"
#include "LadderConfig.h"
#include "LadderManager.h"
#include "MatchupList.h"

bool TestMatch_Bot1Eliminated(int argc, char** argv) {
	try
	{
		// Write out the matchup file before launching LadderManager so we can dictate the bot load order
		std::ofstream myfile;
		myfile.open("./test_configs/TestMatch_Bot1Eliminated/matchuplist");
		myfile << "\"DebugBot1\" \"DebugBot2\" Ladder2017Season3/InterloperLE.SC2Map";
		myfile.close();

		// Run LadderManager
		LadderManager LadderMan(argc, argv, "./test_configs/TestMatch_Bot1Eliminated/LadderManager.conf");
		if (LadderMan.LoadSetup())
		{
			LadderMan.RunLadderManager();
		}
		return true;
	}
	catch (const std::exception& e)
	{
		std::cerr << "Exception in TestMatch_Bot1Eliminated" << std::endl;
		std::cerr << e.what() << std::endl;
		return false;
	}
}

// Handy macro from: s2client-api/tests/all_tests.cc
#define TEST(X)                                                     \
{'fraction_non_alphanumeric': 0.13318657127132635, 'fraction_numerical': 0.025866813428728673, 'mean_word_length': 4.507575757575758, 'pattern_counts': {'":': 0, '<': 31, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6235937', 'n_tokens_mistral': 1446, 'n_tokens_neox': 1380, 'n_words': 269}