replace subtaskInfo map with list for stepik
[idea/community.git] / python / educational-core / student / testData / stepic / 3.json
1 {
2   "meta": {
3     "page": 1,
4     "has_next": false,
5     "has_previous": false
6   },
7   "steps": [
8     {
9       "id": 98626,
10       "lesson": 13416,
11       "position": 1,
12       "status": "ready",
13       "block": {
14         "name": "pycharm",
15         "text": "\nTraditionally the first program you write in any programming language is <code>\"Hello World!\"</code>.\n<br><br>\nIntroduce yourself to the World.\n<br>\n",
16         "video": null,
17         "animation": null,
18         "options": {
19           "test": [
20             {
21               "text": "from test_helper import run_common_tests, failed, passed, get_answer_placeholders\n\n\ndef test_ASCII():\n    windows = get_answer_placeholders()\n    for window in windows:\n        all_ascii = all(ord(c) < 128 for c in window)\n        if not all_ascii:\n            failed(\"Please use only English characters this time.\")\n            return\n    passed()\n\n\ndef test_is_alpha():\n    window = get_answer_placeholders()[0]\n    is_multiline = window.find(\"\\n\")\n    if is_multiline != -1:\n        window = window[:is_multiline-1]\n    splitted = window.split()\n    for s in splitted:\n        if not s.isalpha():\n            failed(\"Please use only English characters this time.\")\n            return\n\n    passed()\n\n\nif __name__ == '__main__':\n    test_ASCII()\n    run_common_tests(\"You should enter your name\")\n    test_is_alpha()\n\n\n",
22               "name": "tests.py"
23             }
24           ],
25           "files": [
26             {
27               "placeholders": [
28                 {
29                   "hint": "[\"Type your name here.\"]",
30                   "offset": 32,
31                   "length": 14,
32                   "subtask_infos": [
33                     {
34                       "index": 0,
35                       "hints": [
36                         "Type your name here."
37                       ],
38                       "possible_answer": "Liana"
39                     },
40                     {
41                       "index": 1,
42                       "hints": [],
43                       "possible_answer": "miss X"
44                     }
45                   ]
46                 }
47               ],
48               "text": "print(\"Hello, world! My name is type your name\")\n",
49               "name": "hello_world.py"
50             }
51           ],
52           "title": "Our first program",
53           "format_version": 2,
54           "last_subtask_index": 1
55         },
56         "subtitle_files": []
57       },
58       "actions": {
59         "submit": "#"
60       },
61       "progress": "77-98626",
62       "subscriptions": [
63         "31-77-98626",
64         "30-77-98626"
65       ],
66       "instruction": null,
67       "session": null,
68       "instruction_type": null,
69       "viewed_by": 46,
70       "passed_by": 2433,
71       "correct_ratio": 0.7805243445692884,
72       "worth": null,
73       "is_solutions_unlocked": false,
74       "solutions_unlocked_attempts": 3,
75       "has_submissions_restrictions": false,
76       "max_submissions_count": 3,
77       "create_date": "2016-04-11T15:25:39Z",
78       "update_date": "2016-08-03T11:05:13Z",
79       "discussions_count": 0,
80       "discussion_proxy": "77-98626-1",
81       "discussion_threads": [
82         "77-98626-1"
83       ]
84     }
85   ]
86 }