diff --git a/Cargo.lock b/Cargo.lock index 32c8ba3417..b87fb9954f 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1023,6 +1023,7 @@ dependencies = [ "indexmap 2.0.0", "insta", "itertools 0.11.0", + "jj-cli", "jj-lib", "libc", "maplit", diff --git a/cli/Cargo.toml b/cli/Cargo.toml index 76d76f01c8..f40316c47c 100644 --- a/cli/Cargo.toml +++ b/cli/Cargo.toml @@ -19,10 +19,12 @@ path = "src/main.rs" [[bin]] name = "fake-editor" path = "testing/fake-editor.rs" +required-features = ["test-fakes"] [[bin]] name = "fake-diff-editor" path = "testing/fake-diff-editor.rs" +required-features = ["test-fakes"] [build-dependencies] cargo_metadata = { workspace = true } @@ -72,10 +74,13 @@ assert_matches = { workspace = true } insta = { workspace = true } test-case = { workspace = true } testutils = { workspace = true } +# https://github.com/rust-lang/cargo/issues/2911#issuecomment-1483256987 +jj-cli = { path = ".", features = ["test-fakes"], default-features = false } [features] default = ["watchman"] bench = ["dep:criterion"] packaging = [] +test-fakes = [] vendored-openssl = ["git2/vendored-openssl", "jj-lib/vendored-openssl"] watchman = ["jj-lib/watchman"]