diff --git a/README.mdwn b/README.mdwn index b58ea9e0f1bf6d39f9cacd3aa7f374c4cfe4642a..9b1fe4060632e8dc4896b20fbb0c3c6e7ff7d951 100644 --- a/README.mdwn +++ b/README.mdwn @@ -7,7 +7,7 @@ It's heavily inspired by Sisyphus (and uses some of its code). See the `preproc` __Please contribute test cases and improve the existing ones.__ -__Semantic test cases that are executable (and terminate) should be placed in the `exec` folder or sub folder.__ +__Semantic test cases that are executable (and terminate) should be placed in the `exec` folder or sub folder and should follow the style recommendations from end of this document.__ __Exec test cases can now use the import statement to import other classes. See the exec test case folder and the `preproc` folder for more information__ @@ -190,6 +190,24 @@ All contributions are reviewed but should be accepted in general (even if this m Issues regarding tests, the test runner or the preprocessor are also appreciated. +MiniJava style recommendations +------------------------------ + +### General +- All code should be valid Java code +- All functionality that could be useful for other test cases should be extracted into an importable files +- Such importable files should be placed in a folder (or sub folder) of `lib` +- Classes and methods should be documented with Javadocs if there name isn't self explanatory + +### Class member +- The name of private class members should start with and underscore +- Instance variables should be initialized (if needed) in the `init` method + +### Class +- The constructor functionality should be implemented in an `init` method that returns `this` at the end +- If you need multiple constructors, implement a basic constructor in the `init` method and implement the other constructors via `initX` methods + + Licence ------- MIT, see LICENCE file for more information.