Fix some nightly Clippy lints
This commit is contained in:
parent
d1b9a19d68
commit
a8ca8f5b74
2 changed files with 4 additions and 4 deletions
|
|
@ -48,7 +48,7 @@ fn test_it_converts_callbacks<CBPRE, CBPOST>(
|
||||||
CBPOST: FnMut(&Path),
|
CBPOST: FnMut(&Path),
|
||||||
CBPRE: FnMut(&Path),
|
CBPRE: FnMut(&Path),
|
||||||
{
|
{
|
||||||
let png = PngData::new(&input, &opts).unwrap();
|
let png = PngData::new(&input, opts).unwrap();
|
||||||
|
|
||||||
assert_eq!(png.raw.ihdr.color_type.png_header_code(), color_type_in);
|
assert_eq!(png.raw.ihdr.color_type.png_header_code(), color_type_in);
|
||||||
assert_eq!(png.raw.ihdr.bit_depth, bit_depth_in);
|
assert_eq!(png.raw.ihdr.bit_depth, bit_depth_in);
|
||||||
|
|
@ -64,7 +64,7 @@ fn test_it_converts_callbacks<CBPRE, CBPOST>(
|
||||||
|
|
||||||
callback_post(output);
|
callback_post(output);
|
||||||
|
|
||||||
let png = match PngData::new(output, &opts) {
|
let png = match PngData::new(output, opts) {
|
||||||
Ok(x) => x,
|
Ok(x) => x,
|
||||||
Err(x) => {
|
Err(x) => {
|
||||||
remove_file(output).ok();
|
remove_file(output).ok();
|
||||||
|
|
@ -196,7 +196,7 @@ fn verbose_mode() {
|
||||||
for (i, log) in logs.into_iter().enumerate() {
|
for (i, log) in logs.into_iter().enumerate() {
|
||||||
let expected_prefix = expected_prefixes[i];
|
let expected_prefix = expected_prefixes[i];
|
||||||
assert!(
|
assert!(
|
||||||
log.starts_with(&expected_prefix),
|
log.starts_with(expected_prefix),
|
||||||
"logs[{}] = {:?} doesn't start with {:?}",
|
"logs[{}] = {:?} doesn't start with {:?}",
|
||||||
i,
|
i,
|
||||||
log,
|
log,
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,7 @@ fn test_it_converts(input: &str) {
|
||||||
let input = PathBuf::from(input);
|
let input = PathBuf::from(input);
|
||||||
let opts = get_opts();
|
let opts = get_opts();
|
||||||
|
|
||||||
let original_data = PngData::read_file(&PathBuf::from(input)).unwrap();
|
let original_data = PngData::read_file(&input).unwrap();
|
||||||
let image = PngData::from_slice(&original_data, &opts).unwrap();
|
let image = PngData::from_slice(&original_data, &opts).unwrap();
|
||||||
let png = Arc::try_unwrap(image.raw).unwrap();
|
let png = Arc::try_unwrap(image.raw).unwrap();
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue