mapbox / MapboxGeocoder.swift

Address search and reverse geocoding in Swift or Objective-C on iOS, macOS, tvOS, and watchOS
https://www.mapbox.com/geocoding/
ISC License
131 stars 48 forks source link

Fix tests #21

Closed friedbunny closed 8 years ago

friedbunny commented 8 years ago

Tests fail locally and on Bitrise.

fatal error: unexpectedly found nil while unwrapping an Optional value

* thread #1: tid = 0x17b6195, 0x00000001124c3158 libswiftCore.dylib`function signature specialization <Arg[0] = Exploded, Arg[1] = Exploded, Arg[2] = Dead, Arg[3] = Dead> of Swift._fatalErrorMessage (Swift.StaticString, Swift.StaticString, Swift.StaticString, Swift.UInt) -> () + 40, queue = 'com.apple.main-thread', stop reason = EXC_BAD_INSTRUCTION (code=EXC_I386_INVOP, subcode=0x0)
    frame #0: 0x00000001124c3158 libswiftCore.dylib`function signature specialization <Arg[0] = Exploded, Arg[1] = Exploded, Arg[2] = Dead, Arg[3] = Dead> of Swift._fatalErrorMessage (Swift.StaticString, Swift.StaticString, Swift.StaticString, Swift.UInt) -> () + 40
  * frame #1: 0x000000010fc8dfd8 MapboxGeocoder`MBGeocoder.reverseGeocodeLocation(location=0x00007fb7755e8600, completionHandler=0x000000010fc020e0 Geocoder (Swift)`Geocoder__Swift_.ViewController.(mapView (__ObjC.MKMapView, regionDidChangeAnimated : Swift.Bool) -> ()).(closure #1) at ViewController.swift:52, self=0x00007fb775570f50) -> ()) -> () + 840 at MapboxGeocoder.swift:47
    frame #2: 0x000000010fc01fbd Geocoder (Swift)`ViewController.mapView(mapView=0x00007fb772712320, animated=false, self=0x00007fb77260a650) -> () + 541 at ViewController.swift:61
    frame #3: 0x000000010fc0261b Geocoder (Swift)`@objc ViewController.mapView(MKMapView, regionDidChangeAnimated : Bool) -> () + 75 at ViewController.swift:0
    frame #4: 0x00000001106a1115 MapKit`-[MKMapView _didChangeRegionMidstream:] + 826
    frame #5: 0x00000001106a5cfd MapKit`-[MKMapView mapLayer:didChangeRegionAnimated:] + 91
friedbunny commented 8 years ago

Updated the Bitrise workflow. Suspect my local test failures are related to using Xcode 7.3 beta.

friedbunny commented 8 years ago

Actually, mmm... it's using the example project in the test runner. Need to substitute the access token again. Or make it not.