Working decorator with some tests

addition to: 91d4f46