You've already forked comprehensive-rust
mirror of
https://github.com/google/comprehensive-rust.git
synced 2025-07-14 10:04:19 +02:00
Be more consistent about tests vs. main (#2644)
The content slides all use `fn main`, with the exception of the testing segment. But with this change, where it makes sense exercises use tests instead, and not both tests and `fn main`. A small change in `book.js` supports running tests when a code sample does not have `fn main` but does have `#[test]`, so these work naturally. Fixes #1581.
This commit is contained in:
committed by
GitHub
parent
699c5137c7
commit
44a79741ff
@ -18,7 +18,7 @@ implementing that same trait, adding behavior in the process. In the "Generics"
|
||||
segment this afternoon, we will see how to make the wrapper generic over the
|
||||
wrapped type.
|
||||
|
||||
```rust,compile_fail
|
||||
```rust,compile_fail,editable
|
||||
{{#include exercise.rs:setup}}
|
||||
|
||||
// TODO: Implement the `Logger` trait for `VerbosityFilter`.
|
||||
|
Reference in New Issue
Block a user