added opening up of array to add method and tests for that method