Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 25 additions & 16 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ repository = "https://github.com/aroff/fastskill"
[workspace.dependencies]
# aikit-sdk for agent metadata file resolution
aikit-sdk = { git = "https://github.com/goaikit/aikit", branch = "main" }
# aikit-evals provides the generic eval runner infrastructure
aikit-evals = { git = "https://github.com/goaikit/aikit", branch = "main" }

# Async runtime
tokio = { version = "1.0", features = ["rt-multi-thread", "net", "fs", "io-util", "macros", "process"] }
Expand Down
39 changes: 39 additions & 0 deletions crates/fastskill-cli/src/commands/init.rs
Original file line number Diff line number Diff line change
Expand Up @@ -480,7 +480,20 @@ mod tests {

#[tokio::test]
async fn test_execute_init_with_all_args() {
let _lock = fastskill_core::test_utils::DIR_MUTEX
.lock()
.unwrap_or_else(|e| e.into_inner());
let temp_dir = TempDir::new().unwrap();
let original_dir = std::env::current_dir().ok();
struct DirGuard(Option<std::path::PathBuf>);
impl Drop for DirGuard {
fn drop(&mut self) {
if let Some(dir) = &self.0 {
let _ = std::env::set_current_dir(dir);
}
}
}
let _guard = DirGuard(original_dir);
std::env::set_current_dir(temp_dir.path()).unwrap();

let args = InitArgs {
Expand All @@ -505,7 +518,20 @@ mod tests {

#[tokio::test]
async fn test_execute_init_with_invalid_version() {
let _lock = fastskill_core::test_utils::DIR_MUTEX
.lock()
.unwrap_or_else(|e| e.into_inner());
let temp_dir = TempDir::new().unwrap();
let original_dir = std::env::current_dir().ok();
struct DirGuard(Option<std::path::PathBuf>);
impl Drop for DirGuard {
fn drop(&mut self) {
if let Some(dir) = &self.0 {
let _ = std::env::set_current_dir(dir);
}
}
}
let _guard = DirGuard(original_dir);
std::env::set_current_dir(temp_dir.path()).unwrap();

let args = InitArgs {
Expand All @@ -532,7 +558,20 @@ mod tests {
// Note: This test verifies that skill ID validation works
// The ID is derived from directory name, so we can't easily test invalid IDs here
// Invalid ID validation happens when the directory name is invalid
let _lock = fastskill_core::test_utils::DIR_MUTEX
.lock()
.unwrap_or_else(|e| e.into_inner());
let temp_dir = TempDir::new().unwrap();
let original_dir = std::env::current_dir().ok();
struct DirGuard(Option<std::path::PathBuf>);
impl Drop for DirGuard {
fn drop(&mut self) {
if let Some(dir) = &self.0 {
let _ = std::env::set_current_dir(dir);
}
}
}
let _guard = DirGuard(original_dir);
std::env::set_current_dir(temp_dir.path()).unwrap();

let args = InitArgs {
Expand Down
11 changes: 1 addition & 10 deletions crates/fastskill-evals/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,8 @@ categories = ["development-tools::testing"]

[dependencies]
fastskill-core = { path = "../fastskill-core", default-features = false, features = ["filesystem-storage"] }
aikit-sdk.workspace = true
tokio.workspace = true
async-trait.workspace = true
serde.workspace = true
serde_json.workspace = true
aikit-evals.workspace = true
toml.workspace = true
thiserror.workspace = true
base64.workspace = true
num_cpus.workspace = true
tracing.workspace = true
tempfile.workspace = true

[dev-dependencies]
tempfile.workspace = true
Expand Down
Loading
Loading