Skip to content

Commit 85f95bc

Browse files
RoyLinRoyLin
authored andcommitted
fix: use core re-exports in AHP test file
Import IdleEvent, IdleDecision, EventContext, MemorySummary, SessionStats from a3s_code_core::ahp instead of directly from a3s_ahp to avoid multiple versions issue in test compilation context
1 parent 62faa6d commit 85f95bc

2 files changed

Lines changed: 147 additions & 6 deletions

File tree

Cargo.lock

Lines changed: 143 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

core/tests/test_ahp_idle_with_llm.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
//! cargo test --test test_ahp_idle_with_llm -- --ignored --test-threads=1 --nocapture
1414
//! ```
1515
16-
use a3s_code_core::ahp::IdleEvent;
16+
use a3s_code_core::ahp::{EventContext, IdleDecision, IdleEvent, MemorySummary, SessionStats};
1717

1818
/// Create LLM client from environment variables
1919
fn get_test_config() -> (String, String, String) {
@@ -70,7 +70,7 @@ fn test_idle_threshold_configuration() {
7070
#[test]
7171
#[ignore]
7272
fn test_idle_event_serialization_roundtrip() {
73-
use a3s_ahp::IdleEvent;
73+
use crate::IdleEvent;
7474

7575
let original = IdleEvent {
7676
idle_duration_ms: 5000,
@@ -94,7 +94,7 @@ fn test_idle_event_serialization_roundtrip() {
9494
#[test]
9595
#[ignore]
9696
fn test_ahp_server_idle_handler_signature() {
97-
use a3s_ahp::IdleDecision;
97+
use crate::IdleDecision;
9898

9999
// Verify IdleDecision variants exist and work
100100
let allow = IdleDecision::Allow;
@@ -114,7 +114,7 @@ fn test_ahp_server_idle_handler_signature() {
114114
#[test]
115115
#[ignore]
116116
fn test_event_context_structure() {
117-
use a3s_ahp::{EventContext, MemorySummary, SessionStats};
117+
use crate::{EventContext, MemorySummary, SessionStats};
118118

119119
let context = EventContext {
120120
recent_facts: None,

0 commit comments

Comments
 (0)