@@ -125,11 +125,7 @@ fn cargo_compile_offline_with_cached_git_dep() {
125
125
// Commit the changes and make sure we trigger a recompile
126
126
File :: create ( & git_project. root ( ) . join ( "src/lib.rs" ) )
127
127
. unwrap ( )
128
- . write_all (
129
- br#"
130
- pub static COOL_STR:&str = "cached git repo rev2";
131
- "# ,
132
- )
128
+ . write_all ( br#"pub static COOL_STR:&str = "cached git repo rev2";"# )
133
129
. unwrap ( ) ;
134
130
git:: add ( & repo) ;
135
131
let rev2 = git:: commit ( & repo) ;
@@ -657,11 +653,7 @@ fn two_revs_same_deps() {
657
653
// Commit the changes and make sure we trigger a recompile
658
654
File :: create ( & bar. root ( ) . join ( "src/lib.rs" ) )
659
655
. unwrap ( )
660
- . write_all (
661
- br#"
662
- pub fn bar() -> i32 { 2 }
663
- "# ,
664
- )
656
+ . write_all ( br#"pub fn bar() -> i32 { 2 }"# )
665
657
. unwrap ( ) ;
666
658
git:: add ( & repo) ;
667
659
let rev2 = git:: commit ( & repo) ;
@@ -784,11 +776,7 @@ fn recompilation() {
784
776
// Modify a file manually, shouldn't trigger a recompile
785
777
File :: create ( & git_project. root ( ) . join ( "src/bar.rs" ) )
786
778
. unwrap ( )
787
- . write_all (
788
- br#"
789
- pub fn bar() { println!("hello!"); }
790
- "# ,
791
- )
779
+ . write_all ( br#"pub fn bar() { println!("hello!"); }"# )
792
780
. unwrap ( ) ;
793
781
794
782
assert_that ( p. cargo ( "build" ) , execs ( ) . with_stdout ( "" ) ) ;
@@ -940,11 +928,7 @@ fn update_with_shared_deps() {
940
928
// Modify a file manually, and commit it
941
929
File :: create ( & git_project. root ( ) . join ( "src/bar.rs" ) )
942
930
. unwrap ( )
943
- . write_all (
944
- br#"
945
- pub fn bar() { println!("hello!"); }
946
- "# ,
947
- )
931
+ . write_all ( br#"pub fn bar() { println!("hello!"); }"# )
948
932
. unwrap ( ) ;
949
933
let repo = git2:: Repository :: open ( & git_project. root ( ) ) . unwrap ( ) ;
950
934
let old_head = repo. head ( ) . unwrap ( ) . target ( ) . unwrap ( ) ;
@@ -1204,11 +1188,7 @@ fn two_deps_only_update_one() {
1204
1188
1205
1189
File :: create ( & git1. root ( ) . join ( "src/lib.rs" ) )
1206
1190
. unwrap ( )
1207
- . write_all (
1208
- br#"
1209
- pub fn foo() {}
1210
- "# ,
1211
- )
1191
+ . write_all ( br#"pub fn foo() {}"# )
1212
1192
. unwrap ( ) ;
1213
1193
let repo = git2:: Repository :: open ( & git1. root ( ) ) . unwrap ( ) ;
1214
1194
git:: add ( & repo) ;
@@ -1268,11 +1248,7 @@ fn stale_cached_version() {
1268
1248
// us pulling it down.
1269
1249
File :: create ( & bar. root ( ) . join ( "src/lib.rs" ) )
1270
1250
. unwrap ( )
1271
- . write_all (
1272
- br#"
1273
- pub fn bar() -> i32 { 1 + 0 }
1274
- "# ,
1275
- )
1251
+ . write_all ( br#"pub fn bar() -> i32 { 1 + 0 }"# )
1276
1252
. unwrap ( ) ;
1277
1253
let repo = git2:: Repository :: open ( & bar. root ( ) ) . unwrap ( ) ;
1278
1254
git:: add ( & repo) ;
@@ -1657,11 +1633,7 @@ fn git_repo_changing_no_rebuild() {
1657
1633
// Make a commit to lock p2 to a different rev
1658
1634
File :: create ( & bar. root ( ) . join ( "src/lib.rs" ) )
1659
1635
. unwrap ( )
1660
- . write_all (
1661
- br#"
1662
- pub fn bar() -> i32 { 2 }
1663
- "# ,
1664
- )
1636
+ . write_all ( br#"pub fn bar() -> i32 { 2 }"# )
1665
1637
. unwrap ( ) ;
1666
1638
let repo = git2:: Repository :: open ( & bar. root ( ) ) . unwrap ( ) ;
1667
1639
git:: add ( & repo) ;
@@ -2121,11 +2093,7 @@ fn update_one_source_updates_all_packages_in_that_git_source() {
2121
2093
// Just be sure to change a file
2122
2094
File :: create ( & dep. root ( ) . join ( "src/lib.rs" ) )
2123
2095
. unwrap ( )
2124
- . write_all (
2125
- br#"
2126
- pub fn bar() -> i32 { 2 }
2127
- "# ,
2128
- )
2096
+ . write_all ( br#"pub fn bar() -> i32 { 2 }"# )
2129
2097
. unwrap ( ) ;
2130
2098
git:: add ( & repo) ;
2131
2099
git:: commit ( & repo) ;
0 commit comments