@@ -18,7 +18,7 @@ func TestInitTaskStructure(t *testing.T) {
1818
1919 // Check directories were created
2020 dirs := []string {
21- "tasks/features " ,
21+ "tasks/issues " ,
2222 "tasks/config" ,
2323 "tasks/analysis" ,
2424 "tasks/mindstorm" ,
@@ -32,19 +32,13 @@ func TestInitTaskStructure(t *testing.T) {
3232 t .Errorf ("Directory not created: %s" , dir )
3333 }
3434 }
35-
36- // Check example file was created
37- examplePath := filepath .Join (tempDir , "tasks" , "example-feature.md" )
38- if _ , err := os .Stat (examplePath ); os .IsNotExist (err ) {
39- t .Error ("example-feature.md not created" )
40- }
4135}
4236
4337func TestInitTaskStructurePreservesExisting (t * testing.T ) {
4438 tempDir := t .TempDir ()
4539
4640 // Create existing directory
47- existingDir := filepath .Join (tempDir , "tasks" , "features " )
41+ existingDir := filepath .Join (tempDir , "tasks" , "issues " )
4842 os .MkdirAll (existingDir , 0755 )
4943 existingFile := filepath .Join (existingDir , "existing.md" )
5044 os .WriteFile (existingFile , []byte ("existing content" ), 0644 )
@@ -78,7 +72,7 @@ func TestCreateFeature(t *testing.T) {
7872 t .Fatalf ("CreateFeature failed: %v" , err )
7973 }
8074
81- featurePath := filepath .Join (tempDir , "tasks" , "features " , "my-feature.md" )
75+ featurePath := filepath .Join (tempDir , "tasks" , "issues " , "my-feature.md" )
8276 if _ , err := os .Stat (featurePath ); os .IsNotExist (err ) {
8377 t .Error ("Feature file not created" )
8478 }
@@ -89,7 +83,7 @@ func TestCreateFeature(t *testing.T) {
8983 t .Fatalf ("CreateFeature with extension failed: %v" , err )
9084 }
9185
92- anotherPath := filepath .Join (tempDir , "tasks" , "features " , "another.md" )
86+ anotherPath := filepath .Join (tempDir , "tasks" , "issues " , "another.md" )
9387 if _ , err := os .Stat (anotherPath ); os .IsNotExist (err ) {
9488 t .Error ("Feature file with extension not created" )
9589 }
@@ -107,13 +101,13 @@ func TestCreateFeatureWithSpaces(t *testing.T) {
107101 }
108102
109103 // Check file was created with dashes instead of spaces
110- featurePath := filepath .Join (tempDir , "tasks" , "features " , "make-script-issue.md" )
104+ featurePath := filepath .Join (tempDir , "tasks" , "issues " , "make-script-issue.md" )
111105 if _ , err := os .Stat (featurePath ); os .IsNotExist (err ) {
112106 t .Error ("Feature file with normalized name not created" )
113107 }
114108
115109 // Check file with spaces does NOT exist
116- wrongPath := filepath .Join (tempDir , "tasks" , "features " , "make script issue.md" )
110+ wrongPath := filepath .Join (tempDir , "tasks" , "issues " , "make script issue.md" )
117111 if _ , err := os .Stat (wrongPath ); ! os .IsNotExist (err ) {
118112 t .Error ("Feature file with spaces should not exist" )
119113 }
@@ -130,7 +124,7 @@ func TestCreateFeatureWithContent(t *testing.T) {
130124 t .Fatalf ("CreateFeature with content failed: %v" , err )
131125 }
132126
133- featurePath := filepath .Join (tempDir , "tasks" , "features " , "custom-content.md" )
127+ featurePath := filepath .Join (tempDir , "tasks" , "issues " , "custom-content.md" )
134128 content , err := os .ReadFile (featurePath )
135129 if err != nil {
136130 t .Fatalf ("Failed to read feature file: %v" , err )
@@ -159,7 +153,7 @@ func TestCreateFeatureWithUnderscores(t *testing.T) {
159153 }
160154
161155 // Check file was created with dashes instead of underscores
162- featurePath := filepath .Join (tempDir , "tasks" , "features " , "my-feature-name.md" )
156+ featurePath := filepath .Join (tempDir , "tasks" , "issues " , "my-feature-name.md" )
163157 if _ , err := os .Stat (featurePath ); os .IsNotExist (err ) {
164158 t .Error ("Feature file with dashes (normalized from underscores) not created" )
165159 }
@@ -242,7 +236,7 @@ func TestDeleteFeature(t *testing.T) {
242236 mgr .CreateFeature ("to-delete" , "" )
243237
244238 // Verify it exists
245- featurePath := filepath .Join (tempDir , "tasks" , "features " , "to-delete.md" )
239+ featurePath := filepath .Join (tempDir , "tasks" , "issues " , "to-delete.md" )
246240 if _ , err := os .Stat (featurePath ); os .IsNotExist (err ) {
247241 t .Fatal ("Feature file not created for deletion test" )
248242 }
@@ -274,7 +268,7 @@ func TestDeleteFeatureWithSpaces(t *testing.T) {
274268 }
275269
276270 // Verify it's gone
277- featurePath := filepath .Join (tempDir , "tasks" , "features " , "delete-me.md" )
271+ featurePath := filepath .Join (tempDir , "tasks" , "issues " , "delete-me.md" )
278272 if _ , err := os .Stat (featurePath ); ! os .IsNotExist (err ) {
279273 t .Error ("Feature file still exists after deletion with spaces" )
280274 }
@@ -302,7 +296,7 @@ func TestGetFeaturePath(t *testing.T) {
302296 if err != nil {
303297 t .Fatalf ("GetFeaturePath failed: %v" , err )
304298 }
305- expectedPath := filepath .Join (tempDir , "tasks" , "features " , "test-feature.md" )
299+ expectedPath := filepath .Join (tempDir , "tasks" , "issues " , "test-feature.md" )
306300 if path != expectedPath {
307301 t .Errorf ("Path mismatch. Got %s, expected %s" , path , expectedPath )
308302 }
@@ -328,7 +322,7 @@ func TestGetFeaturePathWithSpaces(t *testing.T) {
328322 if err != nil {
329323 t .Fatalf ("GetFeaturePath with spaces failed: %v" , err )
330324 }
331- expectedPath := filepath .Join (tempDir , "tasks" , "features " , "my-test-feature.md" )
325+ expectedPath := filepath .Join (tempDir , "tasks" , "issues " , "my-test-feature.md" )
332326 if path != expectedPath {
333327 t .Errorf ("Path mismatch with spaces. Got %s, expected %s" , path , expectedPath )
334328 }
0 commit comments