-
Notifications
You must be signed in to change notification settings - Fork 41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WIP experimental feature for auto detection device/simulator selected in xcode #447
base: develop
Are you sure you want to change the base?
WIP experimental feature for auto detection device/simulator selected in xcode #447
Conversation
lib/run_loop/detect_aut/xcode.rb
Outdated
@@ -39,7 +41,19 @@ def find_xcodeproj | |||
end | |||
|
|||
# @!visibility private | |||
def ignore_xcodeproj?(path) | |||
def self.find_user_state_files | |||
username = Etc.getpwuid.name |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a new method to RunLoop::Environment: self.username
.
This needs rspec tests. |
lib/run_loop/detect_aut/xcode.rb
Outdated
username = Etc.getpwuid.name | ||
user_state_file_paths = [] | ||
Dir.glob("#{Dir.pwd}/**/xcuserdata/#{username}.xcuserdatad/UserInterfaceState.xcuserstate").each do |path| | ||
next if ignore_xcodeproj?(path) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ignore_xcodeproj
is an instance method. You cannot call it from a class method.
@ark-konopacki You should rebase this. If you need help; we can pair. Once you have rebased, we can discuss why the test are failing. |
@jmoody sorry for mess in PR, now tests are passing and selected device (only sim) is detected, so basically ready for review. |
@ark-konopacki We need to rebase this. Let's since next week; I will be back in Germany by Monday. Thanks! |
lib/run_loop/detect_aut/xcode.rb
Outdated
@@ -1,3 +1,5 @@ | |||
require 'etc' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Move this to inside the module definition.
module RunLoop
module DetectAUT
require "etc"
end
end
Prefer "
vs. '
.
This is looking much better! You gotta rebase it though. :) |
@jmoody Ok it is better now, but i cannot use |
Can one of the admins verify this patch? |
bf8bd08
to
958e43a
Compare
@jmoody can you please check why jenkins failing ? |
This should be rebased against develop. I think we might be able to simplify this by reading the
Maybe this could be implemented in CoreSimulator? See #647 I would ask in the community to see if there is support for this feature. |
Rebase against develop
WIP do not merge!
experimental feature for auto detection device/simulator selected in xcode described in calabash/calabash-ios#651
can be checked in calabash-ios console (should wait some time about 5 sec after changing device and running server)