X-Git-Url: https://git.giacomolli.uk/onechat/blobdiff_plain/6e7c7f3d47f086b9d59fe40b91fb071e1528684e..49566fe4e40a18434320829c5cb6a6eff1b4ec78:/prompt_test.go diff --git a/prompt_test.go b/prompt_test.go index f1fe8f8..043cc99 100644 --- a/prompt_test.go +++ b/prompt_test.go @@ -77,7 +77,7 @@ func TestPromptWithoutInstructionsHasNoClause(t *testing.T) { func TestAgentToolsAreStrictAndStable(t *testing.T) { tools := promptTools() - require.Equal(t, []string{"zoom", "date", "shell", "read", "write", "edit", "spawn", "tell", "whatsapp_find", "whatsapp_send"}, promptToolNames(tools)) + require.Equal(t, []string{"zoom", "date", "shell", "read", "write", "edit", "spawn", "tell", "whatsapp_find", "whatsapp_send", "schedule_set", "schedule_list", "schedule_remove"}, promptToolNames(tools)) require.Equal(t, []string{"zoom", "date", "shell", "read", "write", "edit"}, promptToolNames(promptSubagentTools())) for _, tool := range tools { @@ -85,7 +85,7 @@ func TestAgentToolsAreStrictAndStable(t *testing.T) { properties := schema["properties"].(map[string]any) require.True(t, tool.Strict, tool.Name) require.Equal(t, false, schema["additionalProperties"], tool.Name) - require.Equal(t, slices.Sorted(maps.Keys(properties)), schema["required"], tool.Name) + require.ElementsMatch(t, slices.Collect(maps.Keys(properties)), schema["required"], tool.Name) } first, err := json.Marshal(tools)