JonathanWThom/opener

This thing needs some tests

Closed this issue · 1 comments

I'm wondering what the best way to do this is though, since the commands run on the operating system. It would be annoying if it actually opened and closed applications, and wouldn't work on every environment (since they would all need to have the same apps, or app).

I know that we'd definitely want to use a fake applications.json file. Is there a way to create a "fake" application that is opened (and tested for such) and then removed? Not sure.

Or perhaps, we just want to make sure that exec.Run() is called on the right things, and that's enough. We don't need to test that the Go method works.

The scope of this is pretty small right now, but as it grows it would be nice to make sure the functionality behaves as expected.

I've got a path forward for this, starting with 5cc05db.