Refactor test, add GUI