fix: resolve CI/CD issues - remove unused dependencies and imports

- Remove unused thiserror dependency from Cargo.toml
- Remove unused imports (Text, Tabs, Widget, Event, KeyCode, KeyEventKind) from tui/mod.rs
- Remove unused imports (File, Write) from export/mod.rs
- Remove unused pub use ComplexityDistribution from core/analyzer.rs
This commit is contained in:
Developer
2026-02-05 15:56:58 +00:00
parent 1da735b646
commit 98e8df8906
23 changed files with 2880 additions and 0 deletions

View File

@@ -0,0 +1,47 @@
use assert_cmd::Command;
use std::path::PathBuf;
#[test]
fn test_cli_help() {
let mut cmd = Command::cargo_bin("techdebt-tracker-cli").unwrap();
cmd.arg("--help")
.assert()
.success();
}
#[test]
fn test_cli_version() {
let mut cmd = Command::cargo_bin("techdebt-tracker-cli").unwrap();
cmd.arg("--version")
.assert()
.success();
}
#[test]
fn test_init_command() {
let temp_dir = tempfile::tempdir().unwrap();
let temp_path = temp_dir.path().to_path_buf();
let mut cmd = Command::cargo_bin("techdebt-tracker-cli").unwrap();
cmd.arg("init")
.arg("--path")
.arg(&temp_path)
.assert()
.success();
let config_path = temp_path.join("techdebt.yaml");
assert!(config_path.exists());
let content = std::fs::read_to_string(&config_path).unwrap();
assert!(content.contains("patterns:"));
assert!(content.contains("languages:"));
}
#[test]
fn test_analyze_command_nonexistent_path() {
let mut cmd = Command::cargo_bin("techdebt-tracker-cli").unwrap();
cmd.arg("analyze")
.arg("/nonexistent/path")
.assert()
.failure();
}