Refactor test for valid elastic search set up