CocoaPods / fourflusher

A library for interacting with Xcode simulators.
MIT License
33 stars 15 forks source link

Check if device model exist #9

Closed RomanTruba closed 7 years ago

RomanTruba commented 7 years ago

Fix for #8

benasher44 commented 7 years ago

Looks good! Can you add a spec?

RomanTruba commented 7 years ago

@benasher44 sorry, i don't know how.

benasher44 commented 7 years ago

The first step is to figure out what it is in the JSON output from xcrun simctl list -j devices causes this bug. Once you have that, you can make a json file with this output in spec/fixtures. And then in spec/unit_spec.rb, you can copy the sample that does something similar (inject the sample json from a file).

benasher44 commented 7 years ago

This fix should have a CHANGELOG entry as well.

RomanTruba commented 7 years ago

@benasher44 I added a test device, and updated specs. I think, it will be better, if you add an entry to changelog.

benasher44 commented 7 years ago

@Dreddik I can add it, but I'm just curious. What's your concern about modifying the CHANGELOG? You're not expected to do anything about the version or anything like that. You can just add your change to the master section under bug fixes (replacing "None").

benasher44 commented 7 years ago

Looks good. Nice work! going to wait on CI to pass, and then I think we're all set!

RomanTruba commented 7 years ago

Rubocop informed about complexity, refactored to avoid.

RomanTruba commented 7 years ago

God, please, allow this last commit to be passed.

benasher44 commented 7 years ago

@Dreddik thanks for your contribution!