|
@@ -25,7 +25,9 @@ TEST(director, director_debugging) {
|
|
|
dir.to_client = [&client](const std::string line) { client.push_back(line); };
|
|
|
dir.to_server = [&server](const std::string line) { server.push_back(line); };
|
|
|
|
|
|
+ // activating the game gets this over to dir.galaxy.username.
|
|
|
dir.username = "test";
|
|
|
+
|
|
|
// should I setup galaxy-N-test.yaml ? Probably yes.
|
|
|
std::string lines[] = {
|
|
|
"TradeWars Game Server Copyright (C) "
|
|
@@ -58,17 +60,13 @@ TEST(director, director_debugging) {
|
|
|
|
|
|
TEST(director, director_galaxy_save) {
|
|
|
Director dir;
|
|
|
- /*
|
|
|
- std::vector<std::string> client;
|
|
|
- std::vector<std::string> server;
|
|
|
- dir.to_client = [&client](const std::string line) { client.push_back(line); };
|
|
|
- dir.to_server = [&server](const std::string line) { server.push_back(line); };
|
|
|
- */
|
|
|
- dir.username = "test";
|
|
|
- dir.game = 'Z';
|
|
|
+
|
|
|
+ dir.galaxy.username = "test";
|
|
|
+ dir.galaxy.game = 'Z';
|
|
|
+ // This causes a YAML::Node Sequence
|
|
|
dir.galaxy.meta["trade"][10963][0] = 1;
|
|
|
dir.galaxy.save();
|
|
|
- EXPECT_TRUE(1) << "No execption, this is good!";
|
|
|
- GTEST_COUT << "We're still alive, good!" << std::endl;
|
|
|
+
|
|
|
+ EXPECT_TRUE(1) << "No exception, this is good!";
|
|
|
}
|
|
|
} // namespace
|