solanaceae_factorio/test/test1.cpp
Green Sky 6f6894419a
Some checks are pending
ContinuousIntegration / macos (push) Waiting to run
ContinuousIntegration / windows (push) Waiting to run
ContinuousIntegration / linux (push) Successful in 22s
event parsing and dispatching
2024-06-11 10:37:20 +02:00

22 lines
623 B
C++

#include "log_parse.hpp"
#include <cassert>
int main(void) {
{
const auto parse_res = log_parse_line(" 442.539 Script @__Factorio-Event-Logger__/logger.lua:65: [RESEARCH CANCELLED] worker-robots-speed");
assert(parse_res.has_value());
assert(parse_res.value().event == "RESEARCH CANCELLED");
assert(parse_res.value().params == "worker-robots-speed");
}
{
const auto parse_res = log_parse_line(" 224.089 Info ServerMultiplayerManager.cpp:944: updateTick(38228812) received stateChanged peerID(2) oldState(ConnectedLoadingMap) newState(TryingToCatchUp)");
assert(!parse_res.has_value());
}
return 0;
}