Tests with resources now working

And both Dictionary and Bag have bugs - bag has an easy one, but Dictionary seems to take up too much space - maybe it's just me.