Skip to content

Commit 03d588d

Browse files
holdenoutpetertseng
authored andcommitted
kindergarten-garden: add canonical data (#770)
Closes #565 Notes: * The default students indicated in the README are assumed, and alternate students are indicated as input when appropriate. * While some tracks tested all 12 students for the full garden, it only seemed necessary to include a few tests here.
1 parent f4b16d2 commit 03d588d

File tree

1 file changed

+124
-0
lines changed

1 file changed

+124
-0
lines changed
Lines changed: 124 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,124 @@
1+
{
2+
"exercise": "kindergarten-garden",
3+
"version": "1.0.0",
4+
"comments": [
5+
"Garden can be created with just a diagram or a diagram and students."
6+
],
7+
"cases": [
8+
{
9+
"description": "partial garden",
10+
"cases": [
11+
{
12+
"description": "garden with single student",
13+
"property": "plants",
14+
"diagram": "RC\nGG",
15+
"student": "Alice",
16+
"expected": ["radishes", "clover", "grass", "grass"]
17+
},
18+
{
19+
"description": "different garden with single student",
20+
"property": "plants",
21+
"diagram": "VC\nRC",
22+
"student": "Alice",
23+
"expected": ["violets", "clover", "radishes", "clover"]
24+
},
25+
{
26+
"description": "garden with two students",
27+
"property": "plants",
28+
"diagram": "VVCG\nVVRC",
29+
"student": "Bob",
30+
"expected": ["clover", "grass", "radishes", "clover"]
31+
},
32+
{
33+
"description": "multiple students for the same garden with three students",
34+
"cases": [
35+
{
36+
"description": "second student's garden",
37+
"property": "plants",
38+
"diagram": "VVCCGG\nVVCCGG",
39+
"student": "Bob",
40+
"expected": ["clover", "clover", "clover", "clover"]
41+
},
42+
{
43+
"description": "third student's garden",
44+
"property": "plants",
45+
"diagram": "VVCCGG\nVVCCGG",
46+
"student": "Charlie",
47+
"expected": ["grass", "grass", "grass", "grass"]
48+
}
49+
]
50+
}
51+
]
52+
},
53+
{
54+
"description": "full garden",
55+
"cases": [
56+
{
57+
"description": "first student's garden",
58+
"property": "plants",
59+
"diagram": "VRCGVVRVCGGCCGVRGCVCGCGV\nVRCCCGCRRGVCGCRVVCVGCGCV",
60+
"student": "Alice",
61+
"expected": ["violets", "radishes", "violets", "radishes"]
62+
},
63+
{
64+
"description": "second student's garden",
65+
"property": "plants",
66+
"diagram": "VRCGVVRVCGGCCGVRGCVCGCGV\nVRCCCGCRRGVCGCRVVCVGCGCV",
67+
"student": "Bob",
68+
"expected": ["clover", "grass", "clover", "clover"]
69+
},
70+
{
71+
"description": "second to last student's garden",
72+
"property": "plants",
73+
"diagram": "VRCGVVRVCGGCCGVRGCVCGCGV\nVRCCCGCRRGVCGCRVVCVGCGCV",
74+
"student": "Kincaid",
75+
"expected": ["grass", "clover", "clover", "grass"]
76+
},
77+
{
78+
"description": "last student's garden",
79+
"property": "plants",
80+
"diagram": "VRCGVVRVCGGCCGVRGCVCGCGV\nVRCCCGCRRGVCGCRVVCVGCGCV",
81+
"student": "Larry",
82+
"expected": ["grass", "violets", "clover", "violets"]
83+
}
84+
]
85+
},
86+
{
87+
"description": "non-alphabetical student list",
88+
"cases": [
89+
{
90+
"description": "first student's garden",
91+
"property": "plants",
92+
"students": ["Samantha", "Patricia", "Xander", "Roger"],
93+
"diagram": "VCRRGVRG\nRVGCCGCV",
94+
"student": "Patricia",
95+
"expected": ["violets", "clover", "radishes", "violets"]
96+
},
97+
{
98+
"description": "second student's garden",
99+
"property": "plants",
100+
"students": ["Samantha", "Patricia", "Xander", "Roger"],
101+
"diagram": "VCRRGVRG\nRVGCCGCV",
102+
"student": "Roger",
103+
"expected": ["radishes", "radishes", "grass", "clover"]
104+
},
105+
{
106+
"description": "third student's garden",
107+
"property": "plants",
108+
"students": ["Samantha", "Patricia", "Xander", "Roger"],
109+
"diagram": "VCRRGVRG\nRVGCCGCV",
110+
"student": "Samantha",
111+
"expected": ["grass", "violets", "clover", "grass"]
112+
},
113+
{
114+
"description": "fourth (last) student's garden",
115+
"property": "plants",
116+
"students": ["Samantha", "Patricia", "Xander", "Roger"],
117+
"diagram": "VCRRGVRG\nRVGCCGCV",
118+
"student": "Xander",
119+
"expected": ["radishes", "grass", "clover", "violets"]
120+
}
121+
]
122+
}
123+
]
124+
}

0 commit comments

Comments
 (0)