@@ -101,6 +101,54 @@ func TestChainloopAIAgentConfigCrafter_Validation(t *testing.T) {
101101 },
102102 wantErr : false ,
103103 },
104+ {
105+ name : "valid cursor config" ,
106+ data : & aiagentconfig.Evidence {
107+ SchemaVersion : string (schemavalidators .AIAgentConfigVersion0_1 ),
108+ Agent : aiagentconfig.Agent {Name : "cursor" },
109+ ConfigHash : "def456" ,
110+ CapturedAt : "2026-03-13T10:00:00Z" ,
111+ ConfigFiles : []aiagentconfig.ConfigFile {
112+ {
113+ Path : ".cursor/rules/coding.md" ,
114+ SHA256 : "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855" ,
115+ Size : 20 ,
116+ Content : "IyBDb2RpbmcgUnVsZXM=" ,
117+ },
118+ },
119+ },
120+ wantErr : false ,
121+ },
122+ {
123+ name : "valid cursor with multiple file types" ,
124+ data : & aiagentconfig.Evidence {
125+ SchemaVersion : string (schemavalidators .AIAgentConfigVersion0_1 ),
126+ Agent : aiagentconfig.Agent {Name : "cursor" },
127+ ConfigHash : "ghi789" ,
128+ CapturedAt : "2026-03-13T10:00:00Z" ,
129+ ConfigFiles : []aiagentconfig.ConfigFile {
130+ {
131+ Path : ".cursor/rules/react.mdc" ,
132+ SHA256 : "abc123" ,
133+ Size : 15 ,
134+ Content : "cnVsZXM=" ,
135+ },
136+ {
137+ Path : ".cursor/agents/reviewer.md" ,
138+ SHA256 : "def456" ,
139+ Size : 10 ,
140+ Content : "YWdlbnQ=" ,
141+ },
142+ {
143+ Path : "AGENTS.md" ,
144+ SHA256 : "789abc" ,
145+ Size : 8 ,
146+ Content : "YWdlbnRz" ,
147+ },
148+ },
149+ },
150+ wantErr : false ,
151+ },
104152 {
105153 name : "missing required fields" ,
106154 data : & aiagentconfig.Evidence {},
0 commit comments