blob: d93f690336f152ba7ad250ed4ff551f697ef49c5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
#include "2022/day1/aoc.h"
#include "2022/day2/aoc.h"
#include "2022/day3/aoc.h"
#include "2022/day4/aoc.h"
#include "catch.hpp"
#include <stdio.h>
TEST_CASE("Calorie Counting", "[2022]") {
line_view lv = load_file("../src/2022/day1/input");
auto p = aoc2022::day1(lv);
REQUIRE(69693 == p.first);
REQUIRE(200945 == p.second);
}
TEST_CASE("Rock Paper Scissors", "[2022]") {
line_view lv = load_file("../src/2022/day2/input");
auto p = aoc2022::day2(lv);
REQUIRE(17189 == p.first);
REQUIRE(13490 == p.second);
}
TEST_CASE("Rucksack Reorganization", "[2022]") {
line_view lv = load_file("../src/2022/day3/input");
auto p = aoc2022::day3(lv);
REQUIRE(8185 == p.first);
REQUIRE(2817 == p.second);
}
TEST_CASE("Camp Cleanup", "[2022]") {
line_view lv = load_file("../src/2022/day4/input");
auto p = aoc2022::day4(lv);
REQUIRE(431 == p.first);
REQUIRE(823 == p.second);
}
|