Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: clippy and general cleanup of debugger #3957

Merged
merged 2 commits into from
Jan 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion tooling/debugger/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ edition.workspace = true
license.workspace = true

[build-dependencies]
rustc_version = "0.4.0"
build-data.workspace = true

[dependencies]
Expand Down
10 changes: 0 additions & 10 deletions tooling/debugger/build.rs
Original file line number Diff line number Diff line change
@@ -1,24 +1,14 @@
use rustc_version::{version, Version};
use std::fs::File;
use std::io::Write;
use std::path::{Path, PathBuf};
use std::{env, fs};

fn check_rustc_version() {
assert!(
version().unwrap() >= Version::parse("1.71.1").unwrap(),
"The minimal supported rustc version is 1.71.1."
);
}

const GIT_COMMIT: &&str = &"GIT_COMMIT";

fn main() {
// Rebuild if the tests have changed
println!("cargo:rerun-if-changed=tests");

check_rustc_version();

// Only use build_data if the environment variable isn't set
// The environment variable is always set when working via Nix
if std::env::var(GIT_COMMIT).is_err() {
Expand Down
4 changes: 2 additions & 2 deletions tooling/debugger/tests/debug.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// Some of these imports are consumed by the injected tests
use assert_cmd::cargo::cargo_bin;

use rexpect::spawn_bash;

Check warning on line 6 in tooling/debugger/tests/debug.rs

View workflow job for this annotation

GitHub Actions / Code

Unknown word (rexpect)

test_binary::build_test_binary_once!(mock_backend, "../backend_interface/test-binaries");

Expand All @@ -28,7 +28,7 @@
dbg_session
.execute(
&format!("{} debug --program-dir {}", nargo_bin, test_program_dir),
&format!(".*\\Starting debugger.*"),
".*\\Starting debugger.*",
)
.expect("Could not start debugger");

Expand All @@ -49,7 +49,7 @@
// having successfully solved the circuit witness.
dbg_session.send_line("quit").expect("Failed to quit debugger");
dbg_session
.exp_regex(&format!(".*Circuit witness successfully solved.*"))
.exp_regex(".*Circuit witness successfully solved.*")
.expect("Expected circuit witness to be successfully solved.");
}
}
Loading