File tree 1 file changed +7
-6
lines changed
src/doc/contrib/src/tests
1 file changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -207,14 +207,15 @@ mod <case>;
207
207
208
208
` tests/testsuite/<command>/<case>/mod.rs ` :
209
209
``` rust,ignore
210
- use cargo_test_support::prelude::*;
211
210
use cargo_test_support::compare::assert_ui;
211
+ use cargo_test_support::current_dir;
212
+ use cargo_test_support::file;
213
+ use cargo_test_support::prelude::*;
212
214
use cargo_test_support::Project;
213
- use cargo_test_support::curr_dir;
214
215
215
216
#[cargo_test]
216
217
fn case() {
217
- let project = Project::from_template(curr_dir !().join("in"));
218
+ let project = Project::from_template(current_dir !().join("in"));
218
219
let project_root = project.root();
219
220
let cwd = &project_root;
220
221
@@ -224,10 +225,10 @@ fn case() {
224
225
.current_dir(cwd)
225
226
.assert()
226
227
.success()
227
- .stdout_matches_path(curr_dir!().join ("stdout.log"))
228
- .stderr_matches_path(curr_dir!().join ("stderr.log"));
228
+ .stdout_matches(file! ("stdout.log"))
229
+ .stderr_matches(file! ("stderr.log"));
229
230
230
- assert_ui().subset_matches(curr_dir !().join("out"), &project_root);
231
+ assert_ui().subset_matches(current_dir !().join("out"), &project_root);
231
232
}
232
233
```
233
234
You can’t perform that action at this time.
0 commit comments