Ad
  • Default User Avatar

    True, but an array can be initialized with null, then you will get NullPointerException:

    String[] test = null;

    and considering there was a test

    @Test
    public void validateNull() {
    	assertNull(SmashWords.smash(null));
    }
    

    i'd go for a null check before returning.