Skip to content

Commit 170ca51

Browse files
CopilotMossaka
andcommitted
Fix test compilation errors by adding missing environment_vars parameter
Co-authored-by: Mossaka <5447827+Mossaka@users.noreply.github.com>
1 parent 7e8ea3e commit 170ca51

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

crates/wassette/src/wasistate.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -734,7 +734,8 @@ permissions:
734734
memory: "512Mi"
735735
"#;
736736
let policy = PolicyParser::parse_str(yaml_content).unwrap();
737-
let template = create_wasi_state_template_from_policy(&policy, plugin_dir).unwrap();
737+
let env_vars = HashMap::new(); // Empty environment for test
738+
let template = create_wasi_state_template_from_policy(&policy, plugin_dir, &env_vars).unwrap();
738739

739740
assert_eq!(template.memory_limit, Some(512 * 1024 * 1024));
740741
assert!(template.store_limits.is_some());
@@ -761,7 +762,8 @@ permissions:
761762
assert_eq!(memory_limit, Some(1024 * 1024 * 1024)); // 1 GiB in bytes
762763

763764
// Test that WASI state template is created with memory limit
764-
let template = create_wasi_state_template_from_policy(&policy, plugin_dir).unwrap();
765+
let env_vars = HashMap::new(); // Empty environment for test
766+
let template = create_wasi_state_template_from_policy(&policy, plugin_dir, &env_vars).unwrap();
765767
assert_eq!(template.memory_limit, Some(1024 * 1024 * 1024));
766768
assert!(template.store_limits.is_some());
767769

0 commit comments

Comments
 (0)