Cargo fmt the rustlings application code

Signed-off-by: Eddy Petrisor <eddy.petrisor@gmail.com>
This commit is contained in:
Eddy Petrisor 2019-05-22 14:50:23 +03:00
parent 1f2ee8cb62
commit ca6bf966dd
3 changed files with 5 additions and 5 deletions

View file

@ -1,7 +1,7 @@
use serde::Deserialize; use serde::Deserialize;
use std::fmt::{self, Display, Formatter}; use std::fmt::{self, Display, Formatter};
use std::fs::{remove_file}; use std::fs::remove_file;
use std::path::{PathBuf}; use std::path::PathBuf;
use std::process::{self, Command, Output}; use std::process::{self, Command, Output};
const RUSTC_COLOR_ARGS: &[&str] = &["--color", "always"]; const RUSTC_COLOR_ARGS: &[&str] = &["--color", "always"];
@ -63,8 +63,8 @@ impl Display for Exercise {
#[cfg(test)] #[cfg(test)]
mod test { mod test {
use super::*; use super::*;
use std::path::Path;
use std::fs::File; use std::fs::File;
use std::path::Path;
#[test] #[test]
fn test_clean() { fn test_clean() {

View file

@ -1,4 +1,4 @@
use crate::exercise::{Mode, Exercise}; use crate::exercise::{Exercise, Mode};
use crate::verify::test; use crate::verify::test;
use console::{style, Emoji}; use console::{style, Emoji};
use indicatif::ProgressBar; use indicatif::ProgressBar;

View file

@ -2,7 +2,7 @@ use crate::exercise::{Exercise, Mode};
use console::{style, Emoji}; use console::{style, Emoji};
use indicatif::ProgressBar; use indicatif::ProgressBar;
pub fn verify<'a>(start_at: impl IntoIterator<Item=&'a Exercise>) -> Result<(), ()> { pub fn verify<'a>(start_at: impl IntoIterator<Item = &'a Exercise>) -> Result<(), ()> {
for exercise in start_at { for exercise in start_at {
match exercise.mode { match exercise.mode {
Mode::Test => test(&exercise)?, Mode::Test => test(&exercise)?,