Refactor tests to create and use a bundle