Added  tests for new issues


It contains some new tests (system ) from branch sam-1.2 also
Please review it.