tox refactor