diff --git a/content/posts/rust-di-mocking.md b/content/posts/rust-di-mocking.md index 8a6890b..879c97c 100644 --- a/content/posts/rust-di-mocking.md +++ b/content/posts/rust-di-mocking.md @@ -10,7 +10,7 @@ tags = ["rust", "testing"] Rust is hard. {{< /lead >}} -That's one of my takeways from one of my recent endeavors during the winter break. +That's one of my takeways from a recent endeavor during the winter break. {{< forgejo repo="ghoscht/picoKontroller" >}} @@ -19,3 +19,14 @@ Rust isn't necessarily suited for pure object oriented programming. ## Getting Started Use [Shaku](https://github.com/AzureMarker/shaku) and [Mockall](https://github.com/asomers/mockall) + +{{< highlight rust "linenos=table" >}} +#[derive(Parser)] +#[command(version, about, long_about = None)] +struct Cli { + #[arg(long, help = "List all available MIDI devices.")] + list_midi: bool, + #[arg(long, help = "List all available MPRIS players.")] + list_mpris: bool, +} +{{< / highlight >}}