File tree 2 files changed +7
-5
lines changed
2 files changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -2004,7 +2004,7 @@ fn crate_versions() {
2004
2004
let output_path = p. root ( ) . join ( "target/doc/foo/index.html" ) ;
2005
2005
let output_documentation = fs:: read_to_string ( & output_path) . unwrap ( ) ;
2006
2006
2007
- assert ! ( output_documentation. contains( "Version 1.2.4" ) ) ;
2007
+ assert ! ( output_documentation. contains( "1.2.4" ) ) ;
2008
2008
}
2009
2009
2010
2010
#[ cargo_test]
@@ -2028,7 +2028,7 @@ fn crate_versions_flag_is_overridden() {
2028
2028
} ;
2029
2029
let asserts = |html : String | {
2030
2030
assert ! ( !html. contains( "1.2.4" ) ) ;
2031
- assert ! ( html. contains( "Version 2.0.3" ) ) ;
2031
+ assert ! ( html. contains( "2.0.3" ) ) ;
2032
2032
} ;
2033
2033
2034
2034
p. cargo ( "doc" )
Original file line number Diff line number Diff line change @@ -110,17 +110,19 @@ fn whitespace() {
110
110
. with_status ( 101 )
111
111
. run ( ) ;
112
112
113
- const SPACED_VERSION : & str = "a\n b\t c\u{00a0} d" ;
114
113
p. cargo ( "doc" )
115
114
. env_remove ( "__CARGO_TEST_FORCE_ARGFILE" ) // Not applicable for argfile.
116
115
. env (
117
116
"RUSTDOCFLAGS" ,
118
- format ! ( "--crate-version {}" , SPACED_VERSION ) ,
117
+ "--crate-version 1111 \n 2222 \t 3333 \u{00a0} 4444" ,
119
118
)
120
119
. run ( ) ;
121
120
122
121
let contents = p. read_file ( "target/doc/foo/index.html" ) ;
123
- assert ! ( contents. contains( SPACED_VERSION ) ) ;
122
+ assert ! ( contents. contains( "1111" ) ) ;
123
+ assert ! ( contents. contains( "2222" ) ) ;
124
+ assert ! ( contents. contains( "3333" ) ) ;
125
+ assert ! ( contents. contains( "4444" ) ) ;
124
126
}
125
127
126
128
#[ cargo_test]
You can’t perform that action at this time.
0 commit comments