I wish to test a Ruby command line application with Aruba and Cucumber. The application has a switch to create a dot file (such as .my_app) in the current user's home folder. I prefer not to have the application create the file in the user's home folder when running the Aruba tests.
I'm looking for a method to create a temporary working directory inside the step definitions that will create the temporary folder and modify a path flag when the command line application is run. Or is there some functionality built in Aruba that already provides something like this?
A sample test:
Feature: Initialize for user
Scenario: Create a dot file in the user's home directory
When I run `touch ~/.my_test_file`
Then a file named "~/.my_test_file" should exist