Skip to content

Commit

Permalink
Merge pull request #2324 from ehuss/redundant-imports
Browse files Browse the repository at this point in the history
Fix redundant imports.
  • Loading branch information
ehuss authored Feb 24, 2024
2 parents e8b8f34 + 0cc439e commit 504900d
Show file tree
Hide file tree
Showing 7 changed files with 3 additions and 8 deletions.
1 change: 0 additions & 1 deletion src/book/book.rs
Original file line number Diff line number Diff line change
Expand Up @@ -339,7 +339,6 @@ impl Display for Chapter {
#[cfg(test)]
mod tests {
use super::*;
use std::io::Write;
use tempfile::{Builder as TempFileBuilder, TempDir};

const DUMMY_SRC: &str = "
Expand Down
3 changes: 1 addition & 2 deletions src/book/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ use log::{debug, error, info, log_enabled, trace, warn};
use std::io::Write;
use std::path::PathBuf;
use std::process::Command;
use std::string::ToString;
use tempfile::Builder as TempFileBuilder;
use toml::Value;
use topological_sort::TopologicalSort;
Expand Down Expand Up @@ -605,7 +604,7 @@ fn preprocessor_should_run(
mod tests {
use super::*;
use std::str::FromStr;
use toml::value::{Table, Value};
use toml::value::Table;

#[test]
fn config_defaults_to_html_renderer_if_empty() {
Expand Down
1 change: 0 additions & 1 deletion src/book/summary.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ use memchr::Memchr;
use pulldown_cmark::{DefaultBrokenLinkCallback, Event, HeadingLevel, Tag, TagEnd};
use serde::{Deserialize, Serialize};
use std::fmt::{self, Display, Formatter};
use std::iter::FromIterator;
use std::ops::{Deref, DerefMut};
use std::path::{Path, PathBuf};

Expand Down
2 changes: 1 addition & 1 deletion src/cmd/test.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use super::command_prelude::*;
use crate::get_book_dir;
use clap::builder::NonEmptyStringValueParser;
use clap::{Arg, ArgAction, ArgMatches, Command};
use clap::ArgAction;
use mdbook::errors::Result;
use mdbook::MDBook;
use std::path::PathBuf;
Expand Down
2 changes: 1 addition & 1 deletion src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ use std::io::Read;
use std::path::{Path, PathBuf};
use std::str::FromStr;
use toml::value::Table;
use toml::{self, Value};
use toml::Value;

use crate::errors::*;
use crate::utils::{self, toml_ext::TomlExt};
Expand Down
1 change: 0 additions & 1 deletion src/theme/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,6 @@ fn load_file_contents<P: AsRef<Path>>(filename: P, dest: &mut Vec<u8>) -> Result
mod tests {
use super::*;
use std::fs;
use std::path::PathBuf;
use tempfile::Builder as TempFileBuilder;

#[test]
Expand Down
1 change: 0 additions & 1 deletion src/utils/fs.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
use crate::errors::*;
use log::{debug, trace};
use std::convert::Into;
use std::fs::{self, File};
use std::io::Write;
use std::path::{Component, Path, PathBuf};
Expand Down

0 comments on commit 504900d

Please sign in to comment.