added tests and synchonizer
almost complete yet