TestHashTable

Also some minor casting changes in HashTable so it would work during
runtime.

(TODO comment deletion in Sorter)