verso-reader 0.1.0

A terminal EPUB reader with vim navigation, a Kindle-style library, and Markdown highlight export
Documentation
1
2
3
4
5
6
7
8
use verso::reader::search::{find_matches, SearchDirection};

#[test]
fn finds_case_insensitive_matches() {
    let text = "Foo bar foo Baz FOOBAR";
    let m = find_matches(text, "foo", SearchDirection::Forward);
    assert_eq!(m.len(), 3);
}