decy_debugger/
step_debugger.rs1use std::path::Path;
6
7pub fn interactive_step_through(file_path: &Path, _verbose: bool) {
9 println!("═══ Interactive Step-Through Debugger ═══");
10 println!("File: {}", file_path.display());
11 println!();
12 println!("Note: Interactive mode coming in future release.");
13 println!("For now, use:");
14 println!(" decy debug --visualize-ast <file>");
15 println!(" decy debug --visualize-hir <file>");
16 println!(" decy debug --visualize-ownership <file>");
17}
18
19#[cfg(test)]
20mod tests {
21 use super::*;
22 use std::path::PathBuf;
23
24 #[test]
28 fn test_interactive_step_through_with_valid_path() {
29 let path = PathBuf::from("/tmp/test.c");
30 interactive_step_through(&path, false);
32 }
33
34 #[test]
35 fn test_interactive_step_through_with_verbose_flag() {
36 let path = PathBuf::from("/tmp/test.c");
37 interactive_step_through(&path, true);
39 }
40
41 #[test]
42 fn test_interactive_step_through_with_nonexistent_file() {
43 let path = PathBuf::from("/nonexistent/path/to/file.c");
44 interactive_step_through(&path, false);
46 }
47
48 #[test]
49 fn test_interactive_step_through_with_empty_path() {
50 let path = PathBuf::from("");
51 interactive_step_through(&path, false);
53 }
54
55 #[test]
56 fn test_interactive_step_through_with_special_characters() {
57 let path = PathBuf::from("/path/with spaces/and-dashes/file_name.c");
58 interactive_step_through(&path, false);
60 }
61
62 #[test]
63 fn test_interactive_step_through_with_unicode_path() {
64 let path = PathBuf::from("/home/用户/测试文件.c");
65 interactive_step_through(&path, false);
67 }
68
69 #[test]
70 fn test_interactive_step_through_with_relative_path() {
71 let path = PathBuf::from("./relative/path/test.c");
72 interactive_step_through(&path, false);
74 }
75
76 #[test]
77 fn test_interactive_step_through_with_dot_path() {
78 let path = PathBuf::from(".");
79 interactive_step_through(&path, false);
81 }
82}