diff options
author | bors[bot] <bors[bot]@users.noreply.github.com> | 2019-02-12 14:08:20 +0000 |
---|---|---|
committer | bors[bot] <bors[bot]@users.noreply.github.com> | 2019-02-12 14:08:20 +0000 |
commit | 74ecfc2729d2d0771304a4fed3afdfa2c2d99b43 (patch) | |
tree | eacf6870c6fab537d787bc2764901028ce595f0a /crates/test_utils | |
parent | a36e310229f13d6959d6ce95c99b659700cefc9a (diff) | |
parent | 4fd361343449bcdf7af4642851dc5dbf772f1a68 (diff) |
Merge #804
804: Fix some typos r=killercup a=killercup
Cherry-picked and updated from my now-closed PR. All credit goes to [Code Spell Checker](https://marketplace.visualstudio.com/items?itemName=streetsidesoftware.code-spell-checker).
Co-authored-by: Pascal Hertleif <[email protected]>
Diffstat (limited to 'crates/test_utils')
-rw-r--r-- | crates/test_utils/src/lib.rs | 4 | ||||
-rw-r--r-- | crates/test_utils/src/marks.rs | 8 |
2 files changed, 7 insertions, 5 deletions
diff --git a/crates/test_utils/src/lib.rs b/crates/test_utils/src/lib.rs index 09fc2e659..4d83af00c 100644 --- a/crates/test_utils/src/lib.rs +++ b/crates/test_utils/src/lib.rs | |||
@@ -113,9 +113,9 @@ pub struct FixtureEntry { | |||
113 | pub text: String, | 113 | pub text: String, |
114 | } | 114 | } |
115 | 115 | ||
116 | /// Parses text wich looks like this: | 116 | /// Parses text which looks like this: |
117 | /// | 117 | /// |
118 | /// ```notrust | 118 | /// ```rust,ignore |
119 | /// //- some meta | 119 | /// //- some meta |
120 | /// line 1 | 120 | /// line 1 |
121 | /// line 2 | 121 | /// line 2 |
diff --git a/crates/test_utils/src/marks.rs b/crates/test_utils/src/marks.rs index d2a84643c..107432926 100644 --- a/crates/test_utils/src/marks.rs +++ b/crates/test_utils/src/marks.rs | |||
@@ -1,10 +1,10 @@ | |||
1 | //! This module implements manually tracked test coverage, which useful for | 1 | //! This module implements manually tracked test coverage, which useful for |
2 | //! quickly finding a test responsible for testing a particular bit of code. | 2 | //! quickly finding a test responsible for testing a particular bit of code. |
3 | //! | 3 | //! |
4 | //! See https://matklad.github.io/2018/06/18/a-trick-for-test-maintenance.html | 4 | //! See <https://matklad.github.io/2018/06/18/a-trick-for-test-maintenance.html> |
5 | //! for details, but the TL;DR is that you write your test as | 5 | //! for details, but the TL;DR is that you write your test as |
6 | //! | 6 | //! |
7 | //! ```no-run | 7 | //! ```rust,no_run |
8 | //! #[test] | 8 | //! #[test] |
9 | //! fn test_foo() { | 9 | //! fn test_foo() { |
10 | //! covers!(test_foo); | 10 | //! covers!(test_foo); |
@@ -13,7 +13,9 @@ | |||
13 | //! | 13 | //! |
14 | //! and in the code under test you write | 14 | //! and in the code under test you write |
15 | //! | 15 | //! |
16 | //! ```no-run | 16 | //! ```rust,no_run |
17 | //! # use test_utils::tested_by; | ||
18 | //! # fn some_condition() -> bool { true } | ||
17 | //! fn foo() { | 19 | //! fn foo() { |
18 | //! if some_condition() { | 20 | //! if some_condition() { |
19 | //! tested_by!(test_foo); | 21 | //! tested_by!(test_foo); |