Also, the code should probably not fail, and instead do nothing if ```self.table.size() <= new_capacity``` and otherwise round up to the next power of two.

As it is, this interface seems terrible since it requires all caller to add boilerplate to do exactly that themselves.