From: alex <> Date: Mon, 16 Dec 2024 15:28:58 +0000 (+0100) Subject: Day16 - more test cases and still failing X-Git-Url: https://aoc.elinar.fr/?a=commitdiff_plain;h=148aacd1a206df58f7853a9a761d471b381ba35e;p=aoc_2024 Day16 - more test cases and still failing Since the provided answer is wrong, try more test cases found in the subreddit of the day. Such test cases are passing. I can’t find the implementation error yet. --- diff --git a/src/day16.rs b/src/day16.rs index fb9facc..111dee1 100644 --- a/src/day16.rs +++ b/src/day16.rs @@ -167,11 +167,60 @@ mod tests { #.#.#.#########.# #S#.............# #################"; + // from + // + static TEXT_INPUT_2: &str = "\ +########################### +#######################..E# +######################..#.# +#####################..##.# +####################..###.# +###################..##...# +##################..###.### +#################..####...# +################..#######.# +###############..##.......# +##############..###.####### +#############..####.......# +############..###########.# +###########..##...........# +##########..###.########### +#########..####...........# +########..###############.# +#######..##...............# +######..###.############### +#####..####...............# +####..###################.# +###..##...................# +##..###.################### +#..####...................# +#.#######################.# +#S........................# +###########################"; + // same source + static TEXT_INPUT_3: &str = "\ +#################################################### +#......................................#..........E# +#......................................#...........# +#....................#.................#...........# +#....................#.................#...........# +#....................#.................#...........# +#....................#.................#...........# +#....................#.................#...........# +#....................#.................#...........# +#....................#.................#...........# +#....................#.................#...........# +#....................#.............................# +#S...................#.............................# +####################################################"; + #[test] fn test_part1() { assert_eq!(7036, run_part1(TEXT_INPUT_0).unwrap()); assert_eq!(11048, run_part1(TEXT_INPUT_1).unwrap()); + assert_eq!(21148, run_part1(TEXT_INPUT_2).unwrap()); + assert_eq!(5078, run_part1(TEXT_INPUT_3).unwrap()); } #[test]