cargo fmt src/display.rs

This commit is contained in:
Kenta Kubo 2018-12-20 11:51:44 +09:00 committed by Pierre Peltier
parent 1ecbdeef46
commit c1a3ef81ac

View file

@ -108,10 +108,8 @@ impl Display {
} }
} }
#[cfg(test)] #[cfg(test)]
mod tests { mod tests {
use std::path::Path;
use super::*; use super::*;
use color; use color;
use color::Colors; use color::Colors;
@ -119,6 +117,7 @@ mod tests {
use icon; use icon;
use icon::Icons; use icon::Icons;
use meta::{FileType, Name}; use meta::{FileType, Name};
use std::path::Path;
#[test] #[test]
fn test_display_get_visible_width() { fn test_display_get_visible_width() {
@ -134,7 +133,10 @@ mod tests {
] { ] {
let path = Path::new(s); let path = Path::new(s);
let name = Name::new(&path, FileType::File); let name = Name::new(&path, FileType::File);
let output = name.render(&Colors::new(color::Theme::Default), &Icons::new(icon::Theme::Default)); let output = name.render(
&Colors::new(color::Theme::Default),
&Icons::new(icon::Theme::Default),
);
assert_eq!(display.get_visible_width(&output), *l); assert_eq!(display.get_visible_width(&output), *l);
} }
} }