some tests added and added logic for a few methods in deque class