MCPcopy Create free account
hub / github.com/AI45Lab/Code / test_llm_cost_record_zero_tokens

Function test_llm_cost_record_zero_tokens

core/src/telemetry.rs:842–856  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

840
841 #[test]
842 fn test_llm_cost_record_zero_tokens() {
843 let record = LlmCostRecord {
844 model: "test-model".to_string(),
845 provider: "test".to_string(),
846 prompt_tokens: 0,
847 completion_tokens: 0,
848 total_tokens: 0,
849 cost_usd: Some(0.0),
850 timestamp: chrono::Utc::now(),
851 session_id: None,
852 };
853 assert_eq!(record.prompt_tokens, 0);
854 assert_eq!(record.completion_tokens, 0);
855 assert_eq!(record.total_tokens, 0);
856 }
857
858 #[test]
859 fn test_llm_cost_record_clone() {

Callers

nothing calls this directly

Calls 1

nowFunction · 0.85

Tested by

no test coverage detected