isValid + tests

Added:
- isValid + basic tests