File tree 1 file changed +5
-3
lines changed
1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -461,7 +461,7 @@ mod test {
461
461
}
462
462
463
463
assert_eq!(fi.read_byte(), -1);
464
- fail_unless !(fi.eof());
464
+ assert !(fi.eof());
465
465
assert_eq!(fi.state().line_num, 3)
466
466
467
467
}
@@ -482,7 +482,7 @@ mod test {
482
482
let count = fi.read(buf, 10);
483
483
assert_eq!(count, 6);
484
484
assert_eq!(buf, " 0 \n 1 \n 2 \n ". to_bytes( ) ) ;
485
- fail_unless !( fi. eof( ) )
485
+ assert !( fi. eof( ) )
486
486
assert_eq!( fi. state( ) . line_num, 3 ) ;
487
487
}
488
488
@@ -520,7 +520,9 @@ mod test {
520
520
}
521
521
522
522
for input_vec_state( filenames) |line, state| {
523
- let nums = str :: split_char( line, ' ' ) ;
523
+ let nums = do vec:: build |p| {
524
+ for str :: each_split_char( line, ' ' ) |s| { p( s. to_owned( ) ) ; }
525
+ } ;
524
526
let file_num = uint:: from_str( nums[ 0 ] ) . get( ) ;
525
527
let line_num = uint:: from_str( nums[ 1 ] ) . get( ) ;
526
528
assert_eq!( line_num, state. line_num_file) ;
You can’t perform that action at this time.
5 commit comments
bors commentedon Apr 3, 2013
saw approval from graydon
at https://github.com/dbaupp/rust/commit/fea1380a9a0ca94738132db4d51ec4bd86bac3dd
bors commentedon Apr 3, 2013
merging dbaupp/rust/std-fileinput = fea1380 into auto
bors commentedon Apr 3, 2013
dbaupp/rust/std-fileinput = fea1380 merged ok, testing candidate = 0cc9030
bors commentedon Apr 3, 2013
all tests pass:
http://buildbot.rust-lang.org/builders/auto-linux/builds/730
http://buildbot.rust-lang.org/builders/auto-win/builds/725
http://buildbot.rust-lang.org/builders/auto-mac/builds/738
bors commentedon Apr 3, 2013
fast-forwarding incoming to auto = 0cc9030