Further work

- added tests
- added check for only accepting buttons