fspoettel / advent-of-code-rust

🎄Starter template for solving Advent of Code in Rust.
MIT License
713 stars 54 forks source link

Incorrect documentation for --release flag #33

Closed alexlapp closed 1 year ago

alexlapp commented 1 year ago

The docs say setting the --release flag should run the real puzzle inputs, and omitting the flag should run the examples.

The solve command runs your solution. If you set the --release flag, real puzzle inputs will be passed to your solution, otherwise the example inputs will be used.

As far as I can tell this is not the case. Running tests uses the example file, but any configuration of solve, with or without the release flag, will run the real puzzle inputs. I think one of these things would need to be updated, but first I would want to check which behavior is correct.

Is the expectation that solve should run the example or puzzle based on its input? Or does the documentation need to be updated that "solve" will always run puzzle input and "test" should be used for running examples?

fspoettel commented 1 year ago

Hey, thank you for reporting this, you are absolutely correct that this is inconsistent. The expectation is that test maps to example input (treating the example input as a fixture) while solve uses real input. I'll update the documentation to reflect this.