Add solution for "Day 12: Garden Groups", part 1

This commit is contained in:
2025-02-14 15:47:38 +01:00
parent 8bea3c2c48
commit 28baf4db3e
4 changed files with 145 additions and 1 deletions

View File

@@ -15,6 +15,9 @@
#include <catch2/catch_test_macros.hpp>
#include <aocTests/TestContext.hpp>
// Solver implementations in day order.
#include <aoc/HistorianHysteria.hpp>
#include <aoc/RedNosedReports.hpp>
#include <aoc/MullItOver.hpp>
@@ -26,8 +29,8 @@
#include <aoc/DiskFragmenter.hpp>
#include <aoc/HoofIt.hpp>
#include <aoc/PlutonianPebbles.hpp>
#include <aoc/GardenGroups.hpp>
#include <aoc/LanParty.hpp>
#include <aocTests/TestContext.hpp>
#define REQUIRE_MESSAGE(cond, msg) if (!(cond)) { INFO(msg); REQUIRE(cond); }
@@ -174,6 +177,19 @@ TEST_CASE("[PlutonianPebblesTests]")
}
}
TEST_CASE("[GardenGroupsTests]")
{
TestContext test;
SECTION("FullData")
{
test.run(std::make_unique<GardenGroups>(), 1477762, 0, test.getInputPaths());
}
SECTION("ExampleData")
{
test.run(std::make_unique<GardenGroups>(), 1930, 0, test.getExampleInputPaths());
}
}
TEST_CASE("[LanPartyTests]")
{
TestContext test;