diff options
| author | Miguel Ojeda <[email protected]> | 2025-05-02 21:51:28 +0000 |
|---|---|---|
| committer | Miguel Ojeda <[email protected]> | 2025-05-27 18:09:59 +0000 |
| commit | 897d1df6532f05814acd364af9055cd6628fd1b3 (patch) | |
| tree | 024067ee6ab4dc112e3e098e82f2da2981eed477 /rust/macros/lib.rs | |
| parent | rust: kunit: support checked `-> Result`s in KUnit `#[test]`s (diff) | |
| download | kernel-897d1df6532f05814acd364af9055cd6628fd1b3.tar.gz kernel-897d1df6532f05814acd364af9055cd6628fd1b3.zip | |
rust: add `kunit_tests` to the prelude
It is convenient to have certain things in the `kernel` prelude, and
means kernel developers will find it even easier to start writing tests.
And, anyway, nobody should need to use this identifier for anything else.
Thus add it to the prelude.
Reviewed-by: David Gow <[email protected]>
Acked-by: Danilo Krummrich <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Miguel Ojeda <[email protected]>
Diffstat (limited to 'rust/macros/lib.rs')
| -rw-r--r-- | rust/macros/lib.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/rust/macros/lib.rs b/rust/macros/lib.rs index bb5df3b730fc..fa847cf3a9b5 100644 --- a/rust/macros/lib.rs +++ b/rust/macros/lib.rs @@ -407,7 +407,7 @@ pub fn paste(input: TokenStream) -> TokenStream { /// # Examples /// /// ```ignore -/// # use macros::kunit_tests; +/// # use kernel::prelude::*; /// #[kunit_tests(kunit_test_suit_name)] /// mod tests { /// #[test] |
