added qunit and some tests