|
| 1 | +{ |
| 2 | + "max_submission_size" : 1000000, |
| 3 | + "testcases" : [ |
| 4 | + |
| 5 | + // *************** COMPILATION ***************** |
| 6 | + { |
| 7 | + "type" : "Compilation", |
| 8 | + "title" : "Compilation", |
| 9 | + //Note the two step compilation. |
| 10 | + "command" : ["cmake .", "make"], |
| 11 | + "executable_name" : "a.out", |
| 12 | + "points" : 1 |
| 13 | + }, |
| 14 | + // *************** TEST CASES ***************** |
| 15 | + { |
| 16 | + "title" : "Graphics program 1", |
| 17 | + "command" : "./a.out -input sierpinski_triangle.txt -size 400 -iters 0 -cubes", |
| 18 | + //*************** Actions ********************* |
| 19 | + //Actions allow you to interface GUI programs |
| 20 | + //via submitty. Note that in order to run such |
| 21 | + //applications, it is required that you have |
| 22 | + //set up a "Submitty with a screen;" a machine |
| 23 | + //running submitty with a monitor. This machine |
| 24 | + //must also run only one grading thread at a |
| 25 | + //time. For more information, please visit the |
| 26 | + //submitty wiki. |
| 27 | + "actions" : [ |
| 28 | + //It is recommended that the first action be a delay to allow student |
| 29 | + //programs additional time to initialize. Actions are taken beginning |
| 30 | + //at window load time. Note that all actions are padded with a .1 sec |
| 31 | + //delay. |
| 32 | + "delay 1", |
| 33 | + //The click and drag delta command moves a specific distance from the |
| 34 | + //current mouse position. For additional information about actions |
| 35 | + //and their syntax, please view the submitty wiki. |
| 36 | + "click and drag delta 100 0", |
| 37 | + //This program uses many unecessarily delays. Experiment by removing |
| 38 | + //them. |
| 39 | + "delay 1", |
| 40 | + "click and drag delta -100 0", |
| 41 | + "delay 1", |
| 42 | + "click and drag delta 0 100", |
| 43 | + "delay 1", |
| 44 | + "click and drag delta 0 -100", |
| 45 | + "delay 1", |
| 46 | + "click and drag delta 1000 0", |
| 47 | + "delay 1", |
| 48 | + "click and drag delta -1000 0", |
| 49 | + "delay 1", |
| 50 | + "click and drag delta 0 160", |
| 51 | + "delay 1", |
| 52 | + "click and drag delta 0 -160", |
| 53 | + "delay 1", |
| 54 | + "click and drag delta 300 300", |
| 55 | + "delay 1", |
| 56 | + //moves the mouse to 0,0 (upper left) on the window. |
| 57 | + "origin", |
| 58 | + "delay 1", |
| 59 | + //Centers the mouse on the screen |
| 60 | + "center", |
| 61 | + "delay 1", |
| 62 | + "mouse move 10 200", |
| 63 | + "delay 1", |
| 64 | + "click and drag 10 10 150 150", |
| 65 | + "delay 1", |
| 66 | + "click and drag 160 160", |
| 67 | + //takes a screenshot, labeled sequentially starting from 0. |
| 68 | + "screenshot", |
| 69 | + //In the provided application, q indicates a program quit. |
| 70 | + "type 'q'"], |
| 71 | + "points" : 1, |
| 72 | + "validation": [ |
| 73 | + { |
| 74 | + //In this validation example, we merely check that the screenshot |
| 75 | + //taken above exists. |
| 76 | + "actual_file": "0.png", |
| 77 | + "description": "screenshot a", |
| 78 | + "method": "fileExists", |
| 79 | + "show_actual": "always", |
| 80 | + "show_message": "always" |
| 81 | + } |
| 82 | + ] |
| 83 | + }, |
| 84 | + { |
| 85 | + "title" : "Graphics program 1", |
| 86 | + "command" : "./a.out -input sierpinski_triangle.txt -size 400 -iters 0 -cubes", |
| 87 | + "actions" : [ |
| 88 | + "type 'm'", |
| 89 | + "click and drag delta 50 -125", |
| 90 | + "delay 1", |
| 91 | + "screenshot", |
| 92 | + "type 'q'" |
| 93 | + ], |
| 94 | + "points" : 1, |
| 95 | + "validation": [ |
| 96 | + { |
| 97 | + "actual_file": "0.png", |
| 98 | + "description": "screenshot a", |
| 99 | + "method": "fileExists", |
| 100 | + "show_actual": "always", |
| 101 | + "show_message": "always" |
| 102 | + } |
| 103 | + ] |
| 104 | + } |
| 105 | + ] |
| 106 | +} |
0 commit comments