README.md 1.55 KB
Newer Older
Markus Klinik's avatar
Markus Klinik committed
1
2
3
4
# Java Automatic Feedback

Rascal implementation of a simple rule checker for student Java assignments.

Markus Klinik's avatar
README    
Markus Klinik committed
5
6
7


## Running the rule checker
Markus Klinik's avatar
Markus Klinik committed
8
9
10
11
12
13
14

1. Download the latest rascal-shell-unstable.jar from the rascal website and
   put it next to the run.sh script
   http://update.rascal-mpl.org/console/rascal-shell-unstable.jar

1. Run the script

Markus Klinik's avatar
Markus Klinik committed
15
        $ ./run.sh <two-digit-assignment-nr> <absolute-path-to-student-project>
Markus Klinik's avatar
Markus Klinik committed
16
17
18
   
   For example

Markus Klinik's avatar
Markus Klinik committed
19
20
21
22
        $ ./run.sh 02 /home/mkl/radboud/teaching/object-orientation/oo-grading-2019/assignment02/thout/70827-16116\ -\ Asgn\ CS\ Group\ 125\ -\ Jordy\ Schoolmeesters\ -\ Feb\ 10\,\ 2019\ 22_55/
        Version: 0.13.0-SNAPSHOT
        error("All I/O should happen in the view class",|java+class:///a2/Gallows|)
        error("Always explicitly specify access modifiers: public, protected, or private",|java+field:///a2/User/input|)
Markus Klinik's avatar
README    
Markus Klinik committed
23
24


Markus Klinik's avatar
README    
Markus Klinik committed
25
26


Markus Klinik's avatar
README    
Markus Klinik committed
27
28
29
30
31
32
33
34
35
36
37
38
39
## Running the test cases

There are some test projects and test cases to check that the rules give
correct error messages. To run the tests, use the test script. The test script
looks for all files `*Spec.rsc` and executes them

        $ ./test.sh

To run only specific files, specify them on the command line.

        $ ./test.sh Assignment02RulesSpec.rsc Assignment03RulesSpec.rsc


Markus Klinik's avatar
README    
Markus Klinik committed
40
41
42
43
44
45
46
47
48
49


## Developing the rules

To develop rascal code, use eclipse-rcp. Follow the instructions here:
https://www.rascal-mpl.org/start/




Markus Klinik's avatar
README    
Markus Klinik committed
50
51
52
53
54
## References

- Rascal official website https://www.rascal-mpl.org/
- Rascal github https://github.com/usethesource/rascal
- Rascal documentation http://tutor.rascal-mpl.org/Rascal/Rascal.html