No flags found
Use flags to group coverage reports by test type, project and/or folders.
Then setup custom commit statuses and notifications for each flag.
e.g., #unittest #integration
#production #enterprise
#frontend #backend
71fdb5e
... +0 ...
5a2ae4a
Use flags to group coverage reports by test type, project and/or folders.
Then setup custom commit statuses and notifications for each flag.
e.g., #unittest #integration
#production #enterprise
#frontend #backend
20 | 20 | use crate::repr::ContinuousRepresentation; |
|
21 | 21 | use crate::style::*; |
|
22 | 22 | use crate::svg_render; |
|
23 | + | use crate::text_render; |
|
23 | 24 | ||
24 | 25 | /// Representation of any plot with points in the XY plane, visualized as points and/or with lines |
|
25 | 26 | /// in-between. |
173 | 174 | ||
174 | 175 | fn to_text( |
|
175 | 176 | &self, |
|
176 | - | _x_axis: &axis::ContinuousAxis, |
|
177 | - | _y_axis: &axis::ContinuousAxis, |
|
178 | - | _face_width: u32, |
|
179 | - | _face_height: u32, |
|
177 | + | x_axis: &axis::ContinuousAxis, |
|
178 | + | y_axis: &axis::ContinuousAxis, |
|
179 | + | face_width: u32, |
|
180 | + | face_height: u32, |
|
180 | 181 | ) -> String { |
|
181 | - | "".into() |
|
182 | + | let face_lines = if let Some(line_style) = &self.line_style { |
|
183 | + | unimplemented!("Text rendering does not yet support line plots") |
|
184 | + | } else { |
|
185 | + | (0..face_height) |
|
186 | + | .map(|_| " ".repeat(face_width as usize)) |
|
187 | + | .collect::<Vec<String>>() |
|
188 | + | .join("\n") |
|
189 | + | }; |
|
190 | + | let face_points = if let Some(point_style) = &self.point_style { |
|
191 | + | text_render::render_face_points( |
|
192 | + | &self.data, |
|
193 | + | x_axis, |
|
194 | + | y_axis, |
|
195 | + | face_width, |
|
196 | + | face_height, |
|
197 | + | &point_style, |
|
198 | + | ) |
|
199 | + | } else { |
|
200 | + | (0..face_height) |
|
201 | + | .map(|_| " ".repeat(face_width as usize)) |
|
202 | + | .collect::<Vec<String>>() |
|
203 | + | .join("\n") |
|
204 | + | }; |
|
205 | + | text_render::overlay(&face_lines, &face_points, 0, 0) |
|
182 | 206 | } |
|
183 | 207 | } |
Files | Coverage |
---|---|
src | -0.83% 61.94% |
tests/test_no_data.rs | 100.00% |
Project Totals (14 files) | 62.68% |
5a2ae4a
71fdb5e