1+ use crate :: { human, json, Error , Render } ;
12use termcolor:: ColorSpec ;
2- use { human, json, Error , Render } ;
33
44/// Construct a new, empty span
55pub fn span ( ) -> Span {
@@ -54,7 +54,7 @@ macro_rules! span {
5454
5555#[ derive( Default ) ]
5656pub struct Span {
57- items : Vec < Box < Render > > ,
57+ items : Vec < Box < dyn Render > > ,
5858 fg : Option < :: termcolor:: Color > ,
5959 bg : Option < :: termcolor:: Color > ,
6060 bold : bool ,
@@ -126,8 +126,8 @@ impl Render for Span {
126126#[ cfg( test) ]
127127mod test {
128128 use super :: span;
129- use components:: text;
130- use { human, json, Error , Render } ;
129+ use crate :: components:: text;
130+ use crate :: { human, json, Error , Render } ;
131131
132132 #[ test]
133133 fn renders_span_children ( ) -> Result < ( ) , Error > {
@@ -149,7 +149,7 @@ mod test {
149149 #[ test]
150150 fn test_colored_output ( ) -> Result < ( ) , Error > {
151151 let test_target = human:: test_with_color ( ) ;
152- let out = :: new ( ) . add_target ( test_target. target ( ) ) ?;
152+ let out = crate :: new ( ) . add_target ( test_target. target ( ) ) ?;
153153
154154 out. print ( span ( ) . add_item ( "hello" ) . fg ( "green" ) ?. bg ( "blue" ) ?) ?;
155155 out. flush ( ) ?;
@@ -164,7 +164,7 @@ mod test {
164164 #[ test]
165165 fn test_bold_output ( ) -> Result < ( ) , Error > {
166166 let test_target = human:: test_with_color ( ) ;
167- let out = :: new ( ) . add_target ( test_target. target ( ) ) ?;
167+ let out = crate :: new ( ) . add_target ( test_target. target ( ) ) ?;
168168
169169 out. print ( span ( ) . add_item ( "hello" ) . bold ( true ) ?) ?;
170170 out. flush ( ) ?;
@@ -179,7 +179,7 @@ mod test {
179179 #[ test]
180180 fn test_intense_output ( ) -> Result < ( ) , Error > {
181181 let test_target = human:: test_with_color ( ) ;
182- let out = :: new ( ) . add_target ( test_target. target ( ) ) ?;
182+ let out = crate :: new ( ) . add_target ( test_target. target ( ) ) ?;
183183
184184 out. print ( span ( ) . add_item ( "hello" ) . fg ( "green" ) ?. intense ( true ) ?) ?;
185185 out. flush ( ) ?;
@@ -194,7 +194,7 @@ mod test {
194194 #[ test]
195195 fn test_underline_output ( ) -> Result < ( ) , Error > {
196196 let test_target = human:: test_with_color ( ) ;
197- let out = :: new ( ) . add_target ( test_target. target ( ) ) ?;
197+ let out = crate :: new ( ) . add_target ( test_target. target ( ) ) ?;
198198
199199 out. print ( span ( ) . add_item ( "hello" ) . underline ( true ) ?) ?;
200200 out. flush ( ) ?;
0 commit comments