clean_dev_dirs/config/
execution.rs

1//! Execution configuration for cleanup operations.
2//!
3//! This module defines the options that control how cleanup operations are executed,
4//! including dry-run mode and interactive selection.
5
6/// Configuration for cleanup execution behavior.
7///
8/// This struct provides a simplified interface to execution-related options,
9/// controlling how the cleanup process runs.
10#[derive(Clone)]
11pub struct ExecutionOptions {
12    /// Whether to run in dry-run mode (no actual deletion)
13    pub dry_run: bool,
14
15    /// Whether to use interactive project selection
16    pub interactive: bool,
17}
18
19#[cfg(test)]
20mod tests {
21    use super::*;
22
23    #[test]
24    fn test_execution_options_creation() {
25        let exec_opts = ExecutionOptions {
26            dry_run: true,
27            interactive: false,
28        };
29
30        assert!(exec_opts.dry_run);
31        assert!(!exec_opts.interactive);
32    }
33
34    #[test]
35    fn test_execution_options_clone() {
36        let original = ExecutionOptions {
37            dry_run: true,
38            interactive: false,
39        };
40        let cloned = original.clone();
41
42        assert_eq!(original.dry_run, cloned.dry_run);
43        assert_eq!(original.interactive, cloned.interactive);
44    }
45}