edition: move core ripgrep to Rust 2018
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
use hay::{SHERLOCK, SHERLOCK_CRLF};
|
||||
use util::{Dir, TestCommand, sort_lines};
|
||||
use crate::hay::{SHERLOCK, SHERLOCK_CRLF};
|
||||
use crate::util::{Dir, TestCommand, sort_lines};
|
||||
|
||||
// See: https://github.com/BurntSushi/ripgrep/issues/1
|
||||
rgtest!(f1_sjis, |dir: Dir, mut cmd: TestCommand| {
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
use std::time;
|
||||
|
||||
use serde_derive::Deserialize;
|
||||
use serde_json as json;
|
||||
|
||||
use hay::{SHERLOCK, SHERLOCK_CRLF};
|
||||
use util::{Dir, TestCommand};
|
||||
use crate::hay::{SHERLOCK, SHERLOCK_CRLF};
|
||||
use crate::util::{Dir, TestCommand};
|
||||
|
||||
#[derive(Clone, Debug, Deserialize, PartialEq, Eq)]
|
||||
#[serde(tag = "type", content = "data")]
|
||||
|
||||
@@ -3,11 +3,11 @@ macro_rules! rgtest {
|
||||
($name:ident, $fun:expr) => {
|
||||
#[test]
|
||||
fn $name() {
|
||||
let (dir, cmd) = ::util::setup(stringify!($name));
|
||||
let (dir, cmd) = crate::util::setup(stringify!($name));
|
||||
$fun(dir, cmd);
|
||||
|
||||
if cfg!(feature = "pcre2") {
|
||||
let (dir, cmd) = ::util::setup_pcre2(stringify!($name));
|
||||
let (dir, cmd) = crate::util::setup_pcre2(stringify!($name));
|
||||
$fun(dir, cmd);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
use hay::SHERLOCK;
|
||||
use util::{Dir, TestCommand, cmd_exists, sort_lines};
|
||||
use crate::hay::SHERLOCK;
|
||||
use crate::util::{Dir, TestCommand, cmd_exists, sort_lines};
|
||||
|
||||
// This file contains "miscellaneous" tests that were either written before
|
||||
// features were tracked more explicitly, or were simply written without
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
use hay::SHERLOCK;
|
||||
use util::{Dir, TestCommand};
|
||||
use crate::hay::SHERLOCK;
|
||||
use crate::util::{Dir, TestCommand};
|
||||
|
||||
// This tests that multiline matches that span multiple lines, but where
|
||||
// multiple matches may begin and end on the same line work correctly.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
use hay::SHERLOCK;
|
||||
use util::{Dir, TestCommand, sort_lines};
|
||||
use crate::hay::SHERLOCK;
|
||||
use crate::util::{Dir, TestCommand, sort_lines};
|
||||
|
||||
// See: https://github.com/BurntSushi/ripgrep/issues/16
|
||||
rgtest!(r16, |dir: Dir, mut cmd: TestCommand| {
|
||||
|
||||
@@ -1,8 +1,3 @@
|
||||
extern crate serde;
|
||||
#[macro_use]
|
||||
extern crate serde_derive;
|
||||
extern crate serde_json;
|
||||
|
||||
// Macros useful for testing.
|
||||
#[macro_use]
|
||||
mod macros;
|
||||
|
||||
Reference in New Issue
Block a user