The commit hook's own reflow, taken as it came
Browse files at this commitdd8c9bbd508613e786f722270d249f9ece5dd1d4Parent: 7023001- style
- the commit hook's own reflow, taken as it came
2 changed files +13 -12
crates/app/src/tests/media.rsmodified+11 -10
| @@ -6,8 +6,8 @@ use crate::player::library::{ | |||
| 6 | auto_proxies_pref_path, load_auto_proxies_pref, save_auto_proxies_pref, | 6 | auto_proxies_pref_path, load_auto_proxies_pref, save_auto_proxies_pref, |
| 7 | }; | 7 | }; |
| 8 | use crate::subs::{ | 8 | use crate::subs::{ |
| 9 | - SUB_SIZE_RANGE, audio_import_tail, load_subtitle_style, save_subtitle_style, sub_line_h_for, | 9 | + audio_import_tail, load_subtitle_style, save_subtitle_style, sub_line_h_for, |
| 10 | - subtitle_style_path, | 10 | + subtitle_style_path, SUB_SIZE_RANGE, |
| 11 | }; | 11 | }; |
| 12 | use crate::ui::preview::{bgra_to_rgba, screenshot_path}; | 12 | use crate::ui::preview::{bgra_to_rgba, screenshot_path}; |
| 13 | 13 | ||
| @@ -32,8 +32,8 @@ fn an_audio_import_names_its_rate_channels_and_length() { | |||
| 32 | /// stuck read and never as a frozen window. | 32 | /// stuck read and never as a frozen window. |
| 33 | #[test] | 33 | #[test] |
| 34 | fn an_import_line_says_a_stage_has_stopped_moving_and_only_then() { | 34 | fn an_import_line_says_a_stage_has_stopped_moving_and_only_then() { |
| 35 | - use std::sync::Arc; | ||
| 36 | use std::sync::atomic::{AtomicU8, Ordering::Relaxed}; | 35 | use std::sync::atomic::{AtomicU8, Ordering::Relaxed}; |
| 36 | + use std::sync::Arc; | ||
| 37 | let stage = Arc::new(AtomicU8::new(ImportStage::Header as u8)); | 37 | let stage = Arc::new(AtomicU8::new(ImportStage::Header as u8)); |
| 38 | let started = Instant::now() - Duration::from_secs(9); | 38 | let started = Instant::now() - Duration::from_secs(9); |
| 39 | let mut import = Import { | 39 | let mut import = Import { |
| @@ -303,7 +303,10 @@ fn a_strand_slot_on_a_single_strand_clip_is_the_clip_s_own_colour() { | |||
| 303 | // The clip's own slot is never redirected -- it is what the fallback | 303 | // The clip's own slot is never redirected -- it is what the fallback |
| 304 | // lands on. | 304 | // lands on. |
| 305 | assert_eq!(VizSlot::Main.picked(one), VizSlot::Main); | 305 | assert_eq!(VizSlot::Main.picked(one), VizSlot::Main); |
| 306 | - assert_eq!(VizSlot::Strand.picked(with_viz_paint_strands(one, 2)), VizSlot::Strand); | 306 | + assert_eq!( |
| 307 | + VizSlot::Strand.picked(with_viz_paint_strands(one, 2)), | ||
| 308 | + VizSlot::Strand | ||
| 309 | + ); | ||
| 307 | } | 310 | } |
| 308 | 311 | ||
| 309 | /// A seek says nothing until it has stood: an ordinary one is a flicker and | 312 | /// A seek says nothing until it has stood: an ordinary one is a flicker and |
| @@ -326,8 +329,8 @@ fn a_seek_says_so_only_once_it_has_stood() { | |||
| 326 | /// fifty-one seconds on a 25 GB film. | 329 | /// fifty-one seconds on a 25 GB film. |
| 327 | #[test] | 330 | #[test] |
| 328 | fn a_silence_card_is_up_while_its_scan_runs_and_says_where_it_has_got_to() { | 331 | fn a_silence_card_is_up_while_its_scan_runs_and_says_where_it_has_got_to() { |
| 329 | - use std::sync::Arc; | ||
| 330 | use std::sync::atomic::Ordering::Relaxed; | 332 | use std::sync::atomic::Ordering::Relaxed; |
| 333 | + use std::sync::Arc; | ||
| 331 | let progress = Arc::new(engine::silence::Progress::default()); | 334 | let progress = Arc::new(engine::silence::Progress::default()); |
| 332 | // Two hours and eight minutes, as the header claims it. | 335 | // Two hours and eight minutes, as the header claims it. |
| 333 | progress.total.store(7680, Relaxed); | 336 | progress.total.store(7680, Relaxed); |
| @@ -757,11 +760,9 @@ fn every_codec_row_is_offered_or_says_why_not() { | |||
| 757 | detail.contains("ec-vorbis"), | 760 | detail.contains("ec-vorbis"), |
| 758 | "the row names the encoder like every other live one: {detail}" | 761 | "the row names the encoder like every other live one: {detail}" |
| 759 | ); | 762 | ); |
| 760 | - assert!( | 763 | + assert!(FORMATS |
| 761 | - FORMATS | 764 | + .into_iter() |
| 762 | - .into_iter() | 765 | + .any(|(row, _, _, detail)| row.contains(&Format::Hevc) && detail.contains("intra"))); |
| 763 | - .any(|(row, _, _, detail)| row.contains(&Format::Hevc) && detail.contains("intra")) | ||
| 764 | - ); | ||
| 765 | // The destination follows the format and keeps the stem, mp4 included. | 766 | // The destination follows the format and keeps the stem, mp4 included. |
| 766 | assert_eq!( | 767 | assert_eq!( |
| 767 | retarget(std::path::Path::new("/a/take.export.mp4"), Format::Wav), | 768 | retarget(std::path::Path::new("/a/take.export.mp4"), Format::Wav), |
crates/app/src/tests/view.rsmodified+2 -2
| @@ -891,7 +891,7 @@ fn the_zoom_button_says_how_much_is_on_the_bed() { | |||
| 891 | /// lives. | 891 | /// lives. |
| 892 | #[test] | 892 | #[test] |
| 893 | fn tab_cycles_dock_bench_inspector_and_wraps() { | 893 | fn tab_cycles_dock_bench_inspector_and_wraps() { |
| 894 | - use crate::ui::stance::{Surface, next_surface}; | 894 | + use crate::ui::stance::{next_surface, Surface}; |
| 895 | 895 | ||
| 896 | assert_eq!(next_surface(Surface::Dock, false), Surface::Bench); | 896 | assert_eq!(next_surface(Surface::Dock, false), Surface::Bench); |
| 897 | assert_eq!(next_surface(Surface::Bench, false), Surface::Inspector); | 897 | assert_eq!(next_surface(Surface::Bench, false), Surface::Inspector); |
| @@ -912,7 +912,7 @@ fn tab_cycles_dock_bench_inspector_and_wraps() { | |||
| 912 | /// surface being entered is always the one mounted. | 912 | /// surface being entered is always the one mounted. |
| 913 | #[test] | 913 | #[test] |
| 914 | fn surface_wants_src_active_mounts_the_tab_before_focus_lands_on_it() { | 914 | fn surface_wants_src_active_mounts_the_tab_before_focus_lands_on_it() { |
| 915 | - use crate::ui::stance::{Surface, surface_wants_src_active}; | 915 | + use crate::ui::stance::{surface_wants_src_active, Surface}; |
| 916 | 916 | ||
| 917 | assert_eq!(surface_wants_src_active(Surface::Dock), Some(true)); | 917 | assert_eq!(surface_wants_src_active(Surface::Dock), Some(true)); |
| 918 | assert_eq!(surface_wants_src_active(Surface::Inspector), Some(false)); | 918 | assert_eq!(surface_wants_src_active(Surface::Inspector), Some(false)); |