@@ -17,7 +17,7 @@ use std::io::Read as _;
17
17
extern crate test_assembler;
18
18
use self :: test_assembler:: * ;
19
19
20
- use boxes:: { BoxType , FourCC } ;
20
+ use boxes:: BoxType ;
21
21
22
22
enum BoxSize {
23
23
Short ( u32 ) ,
@@ -181,11 +181,11 @@ fn read_ftyp() {
181
181
assert_eq ! ( stream. head. name, BoxType :: FileTypeBox ) ;
182
182
assert_eq ! ( stream. head. size, 24 ) ;
183
183
let parsed = super :: read_ftyp ( & mut stream) . unwrap ( ) ;
184
- assert_eq ! ( parsed. major_brand, FourCC :: from ( * b"mp42" ) ) ; // mp42
184
+ assert_eq ! ( parsed. major_brand, b"mp42" ) ; // mp42
185
185
assert_eq ! ( parsed. minor_version, 0 ) ;
186
186
assert_eq ! ( parsed. compatible_brands. len( ) , 2 ) ;
187
- assert_eq ! ( parsed. compatible_brands[ 0 ] , FourCC :: from ( * b"isom" ) ) ; // isom
188
- assert_eq ! ( parsed. compatible_brands[ 1 ] , FourCC :: from ( * b"mp42" ) ) ; // mp42
187
+ assert_eq ! ( parsed. compatible_brands[ 0 ] , b"isom" ) ; // isom
188
+ assert_eq ! ( parsed. compatible_brands[ 1 ] , b"mp42" ) ; // mp42
189
189
}
190
190
191
191
#[ test]
@@ -223,11 +223,11 @@ fn read_ftyp_case() {
223
223
assert_eq ! ( stream. head. name, BoxType :: FileTypeBox ) ;
224
224
assert_eq ! ( stream. head. size, 24 ) ;
225
225
let parsed = super :: read_ftyp ( & mut stream) . unwrap ( ) ;
226
- assert_eq ! ( parsed. major_brand, FourCC :: from ( * b"MP42" ) ) ;
226
+ assert_eq ! ( parsed. major_brand, b"MP42" ) ;
227
227
assert_eq ! ( parsed. minor_version, 0 ) ;
228
228
assert_eq ! ( parsed. compatible_brands. len( ) , 2 ) ;
229
- assert_eq ! ( parsed. compatible_brands[ 0 ] , FourCC :: from ( * b"ISOM" ) ) ; // ISOM
230
- assert_eq ! ( parsed. compatible_brands[ 1 ] , FourCC :: from ( * b"MP42" ) ) ; // MP42
229
+ assert_eq ! ( parsed. compatible_brands[ 0 ] , b"ISOM" ) ; // ISOM
230
+ assert_eq ! ( parsed. compatible_brands[ 1 ] , b"MP42" ) ; // MP42
231
231
}
232
232
233
233
#[ test]
@@ -474,7 +474,7 @@ fn read_hdlr() {
474
474
assert_eq ! ( stream. head. name, BoxType :: HandlerBox ) ;
475
475
assert_eq ! ( stream. head. size, 45 ) ;
476
476
let parsed = super :: read_hdlr ( & mut stream) . unwrap ( ) ;
477
- assert_eq ! ( parsed. handler_type, FourCC :: from ( * b"vide" ) ) ;
477
+ assert_eq ! ( parsed. handler_type, b"vide" ) ;
478
478
}
479
479
480
480
#[ test]
@@ -487,7 +487,7 @@ fn read_hdlr_short_name() {
487
487
assert_eq ! ( stream. head. name, BoxType :: HandlerBox ) ;
488
488
assert_eq ! ( stream. head. size, 33 ) ;
489
489
let parsed = super :: read_hdlr ( & mut stream) . unwrap ( ) ;
490
- assert_eq ! ( parsed. handler_type, FourCC :: from ( * b"vide" ) ) ;
490
+ assert_eq ! ( parsed. handler_type, b"vide" ) ;
491
491
}
492
492
493
493
#[ test]
@@ -500,7 +500,7 @@ fn read_hdlr_zero_length_name() {
500
500
assert_eq ! ( stream. head. name, BoxType :: HandlerBox ) ;
501
501
assert_eq ! ( stream. head. size, 32 ) ;
502
502
let parsed = super :: read_hdlr ( & mut stream) . unwrap ( ) ;
503
- assert_eq ! ( parsed. handler_type, FourCC :: from ( * b"vide" ) ) ;
503
+ assert_eq ! ( parsed. handler_type, b"vide" ) ;
504
504
}
505
505
506
506
fn flac_streaminfo ( ) -> Vec < u8 > {
0 commit comments