add a test for hover btn and more refactors

[?]
May 17, 2025, 7:45 PM
3BK22XE5LPOH2EK5AMRXFXHNQNCJ54HEPYRINHJT4DA7INT32I7AC

Dependencies

Change contents

  • edit in libflorescence/src/diff.rs at line 107
    [9.3090]
    pub fn contents_to_lines(contents: &str) -> Lines {
    contents.split('\n').map(str::to_string).collect()
    }
  • edit in inflorescence_view/src/testing.rs at line 1
    [6.599]
    [7.6095]
    #[doc(inline)]
    pub use iced_test::selector;
  • edit in inflorescence_view/src/testing.rs at line 47
    [6.1650]
    [6.1650]
    results: &mut Vec<TestViewResult<'b>>,
    uniq_name: &'b str,
    element: impl Into<Element<'a, Message, Theme, Renderer>>,
    size: Size,
    ) where
    Renderer: iced::advanced::Renderer + iced::advanced::renderer::Headless,
    {
    test_view_change_sim(results, uniq_name, element, size, |_sim| {})
    }
    /// The name of the test calling this function MUST start with "view".
    pub fn test_view_change_sim<'a, 'b, Message, Renderer, F>(
  • edit in inflorescence_view/src/testing.rs at line 63
    [6.1796]
    [6.1796]
    change_sim: F,
  • edit in inflorescence_view/src/testing.rs at line 66
    [6.1881]
    [6.1881]
    F: Fn(&mut Simulator<Message, Theme, Renderer>),
  • edit in inflorescence_view/src/testing.rs at line 79
    [7.6272]
    [6.2173]
    change_sim(&mut sim);
  • edit in inflorescence_view/src/lib.rs at line 8
    [4.123]
    [8.2558]
    #[doc(inline)]
  • edit in inflorescence_view/src/lib.rs at line 10
    [8.2579]
    [7.6290]
    #[doc(inline)]
  • edit in inflorescence_view/src/diff.rs at line 1
    [5.417]
    [9.5127]
    #[doc(inline)]
  • replacement in inflorescence_view/src/diff.rs at line 3
    [9.5159][9.5159:5296]()
    Combined, DecodedFile, DiffWithContents, DiffWithoutContents, File, Lines,
    Section, State, UndecodableContents, UndecodableFile,
    [9.5159]
    [9.5296]
    contents_to_lines, Combined, DecodedFile, DiffWithContents,
    DiffWithoutContents, File, Lines, Section, State, UndecodableContents,
    UndecodableFile,
  • edit in inflorescence_view/src/diff.rs at line 30
    [5.3762][5.3762:3872]()
    pub fn contents_to_lines(contents: &str) -> Lines {
    contents.split('\n').map(str::to_string).collect()
    }
  • replacement in inflorescence_view/src/app/test.rs at line 2
    [6.4264][6.4264:4319]()
    use crate::testing::{report_results, test_view, Size};
    [6.4264]
    [6.4319]
    use crate::testing::{
    report_results, selector, test_view, test_view_change_sim, Size,
    };
  • edit in inflorescence_view/src/app/test.rs at line 103
    [7.8482]
    [7.8482]
    &mut results,
    uniq_name,
    view(state, window_id, |_id| Some(&diff)),
    size,
    );
    // _________________________________________________________________________
    //
    let uniq_name = "app_loaded_point_at_untracked";
    let state = State {
    repo_path: &repo_path,
    repo: repo.as_ref(),
    cursor: &cursor,
    record_msg: record_msg.as_ref(),
    diffs_state: &diffs_state,
    };
    test_view_change_sim(
  • edit in inflorescence_view/src/app/test.rs at line 125
    [7.8588]
    [7.8588]
    |sim| {
    let target = sim.find(selector::text("untracked.rs")).unwrap();
    sim.point_at(target.bounds.center());
    },
  • edit in inflorescence/src/file.rs at line 3
    [5.29020]
    [9.6102]
    #[doc(inline)]
  • replacement in inflorescence/src/diff.rs at line 3
    [3.5056][5.29079:29116]()
    pub use inflorescence_view::diff::*;
    [3.5056]
    [4.731]
    #[doc(inline)]
    pub use inflorescence_view::diff::Msg;
    #[doc(inline)]
    pub use libflorescence::diff::{
    contents_to_lines, Combined, DecodedFile, DiffWithContents,
    DiffWithoutContents, File, Lines, Section, State, UndecodableContents,
    UndecodableFile,
    };
  • edit in inflorescence/src/cursor.rs at line 1
    [2.26]
    [9.6153]
    #[doc(inline)]