74 lines
1.2 KiB
JSON
74 lines
1.2 KiB
JSON
{
|
|
"function": "newGame",
|
|
"cases": [
|
|
{
|
|
"name": "seed-0",
|
|
"args": [
|
|
0
|
|
],
|
|
"expected": {
|
|
"width": 20,
|
|
"height": 20,
|
|
"snake": [
|
|
{
|
|
"x": 10,
|
|
"y": 10
|
|
},
|
|
{
|
|
"x": 9,
|
|
"y": 10
|
|
},
|
|
{
|
|
"x": 8,
|
|
"y": 10
|
|
}
|
|
],
|
|
"dir": "Right",
|
|
"nextDir": "Right",
|
|
"apple": {
|
|
"x": 18,
|
|
"y": 13
|
|
},
|
|
"seed": 1831565813,
|
|
"score": 0,
|
|
"status": "Playing",
|
|
"frame": 0
|
|
}
|
|
},
|
|
{
|
|
"name": "seed-42",
|
|
"args": [
|
|
42
|
|
],
|
|
"expected": {
|
|
"width": 20,
|
|
"height": 20,
|
|
"snake": [
|
|
{
|
|
"x": 10,
|
|
"y": 10
|
|
},
|
|
{
|
|
"x": 9,
|
|
"y": 10
|
|
},
|
|
{
|
|
"x": 8,
|
|
"y": 10
|
|
}
|
|
],
|
|
"dir": "Right",
|
|
"nextDir": "Right",
|
|
"apple": {
|
|
"x": 1,
|
|
"y": 9
|
|
},
|
|
"seed": 1831565855,
|
|
"score": 0,
|
|
"status": "Playing",
|
|
"frame": 0
|
|
}
|
|
}
|
|
]
|
|
}
|