mirror of
https://github.com/facebook/sapling.git
synced 2024-10-09 16:31:02 +03:00
hgcommands: setup fail points
Summary: Setup fail points so `FAILPOINTS` can work. Reviewed By: andll Differential Revision: D29888940 fbshipit-source-id: 4e6f98ed0a1c1410d6992f92ff810b5ef64ba76e
This commit is contained in:
parent
8cb3d3dd75
commit
08c596b72e
@ -20,6 +20,7 @@ eagerepo = { path = "../eagerepo" }
|
||||
edenapi = { path = "../edenapi" }
|
||||
edenfs_client = { path = "../edenfs-client" }
|
||||
encoding = { path = "../encoding" }
|
||||
fail = { version = "0.4", features = ["failpoints"] }
|
||||
flate2 = { version = "1.0", features = ["rust_backend", "tokio"], default-features = false }
|
||||
fsyncglob = { path = "../fsyncglob" }
|
||||
hg-http = { path = "../hg-http" }
|
||||
|
@ -14,6 +14,7 @@ use clidispatch::io::IO;
|
||||
use clidispatch::{dispatch, errors};
|
||||
use clientinfo::ClientInfo;
|
||||
use configparser::config::ConfigSet;
|
||||
use fail::FailScenario;
|
||||
use hg_http::HgHttpConfig;
|
||||
use once_cell::sync::Lazy;
|
||||
use parking_lot::Mutex;
|
||||
@ -69,6 +70,7 @@ pub fn run_command(args: Vec<String>, io: &IO) -> i32 {
|
||||
Ok(res) => res,
|
||||
};
|
||||
|
||||
let scenario = FailScenario::setup();
|
||||
setup_eager_repo();
|
||||
|
||||
// This is intended to be "process start". "exec/hgmain" seems to be
|
||||
@ -169,6 +171,8 @@ pub fn run_command(args: Vec<String>, io: &IO) -> i32 {
|
||||
// so we need to flush now.
|
||||
blackbox::sync();
|
||||
|
||||
scenario.teardown();
|
||||
|
||||
exit_code
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user