MCPcopy Create free account
hub / github.com/dtormoen/tsk-tsk / test_clean_project_name

Function test_clean_project_name

src/repository.rs:284–292  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

282
283 #[tokio::test]
284 async fn test_clean_project_name() {
285 // Create a temp dir with special characters in the name
286 let temp_base = TempDir::new().unwrap();
287 let project_dir = temp_base.path().join("My_Awesome Project!");
288 tokio::fs::create_dir(&project_dir).await.unwrap();
289
290 let result = detect_project_name(&project_dir).await.unwrap();
291 assert_eq!(result, "my_awesome-project");
292 }
293
294 #[tokio::test]
295 async fn test_project_name_with_dots() {

Callers

nothing calls this directly

Calls 3

create_dirFunction · 0.85
detect_project_nameFunction · 0.85
pathMethod · 0.80

Tested by

no test coverage detected