unit testing, using Jasmine, writing splice function from scratch