jGleitz / JUnit-KIT

Tests for the Tasks of the Programming Lecture for first semesters at the Karlsruhe Institute for Technology, winter semester 14/15. Among the tests themselves, this repository contains helpfull classes for testing unknown implementations.
GNU General Public License v2.0
7 stars 7 forks source link

Added tests for invalid commands #148

Closed RomanLangrehr closed 9 years ago

RomanLangrehr commented 9 years ago

Fixes #134 The tests should be complete.

pcworld commented 9 years ago

An error recovery test would be useful too (we had something similar in final1): Provoke an error and then assure the program still responds correctly to commands, by using print command or so (in case of create we could also make sure that the specified ant was not actually created). We can also create a new issue for this if this is out of scope for this pull request.

RomanLangrehr commented 9 years ago

That's a good idea, but I appreciate very much, creating a new issue for that.

RomanLangrehr commented 9 years ago

By the way: ed847ed fixes all your issues.

I'd somewhere (not necessarily in this ^ method) add tests that test e.g. create (i.e. with just a trailing space)

I did this in wrongWhitespaceTest() for all argument commands (cause it's the same with the commands like escape or direction....)

jGleitz commented 9 years ago

Apart from some unnecessary lines which make things hard to read, I really like this! It's a very detailed test and should cover at least 95% of all cases!

RomanLangrehr commented 9 years ago

If the input file doesn't matter, please don't reassign it before the test run

Fixed

This does not work, it should be \u00e4.

Fixed

jGleitz commented 9 years ago

Thanks. I think we can merge, can't we?

pcworld commented 9 years ago

+1