Граф коммитов

1260 Коммитов

Автор SHA1 Сообщение Дата
Sebastien Pouliot 52ffb2b251 Merge branch 'cycle8' into xcode8 2016-07-18 14:34:12 -04:00
Sebastien Pouliot 24b5dfbcb9 [tests] Disable PassLibraryTest.Default on watchOS as it hangs the process (#412)
Jul 15 15:44:26 castor monotouchtest[42732]: [default] [ERROR] error while getting ubiquityIdentityToken: Error Domain=NSCocoaErrorDomain Code=4099 "The connection to service named com.apple.bird.token was invalidated." UserInfo={NSDebugDescription=The connection to service named com.apple.bird.token was invalidated.}

^ the above is printed several times after this
2016-07-18 08:35:53 -04:00
Sebastien Pouliot f38d545d31 [tests] Ensure monotouch-test runs fine down to iOS 6.1 (#411)
* Mostly missing checks

* FontTest: Apple never fixed that and the way we link now, without
  dlsym, makes the test crash

dyld: lazy symbol binding failed: Symbol not found: _CTFontCreateWithFontDescriptorAndOptions
  Referenced from: /var/mobile/Applications/6025D222-F50E-46E0-8BF5-9C45D4C7DACB/monotouchtest.app/monotouchtest
  Expected in: /System/Library/Frameworks/CoreText.framework/CoreText
2016-07-15 18:10:30 -04:00
Vincent Dondain 2dfe8fe400 [mediaplayer] Update for iOS 10 beta 1 - Part 2 (#406) 2016-07-15 13:19:25 -04:00
Sebastien Pouliot d2c1b63ec0 Fix monotouch-tests failures on older iOS versions (#401)
Tested with iOS 7.1 on an iPad 3

- Dynamic registrar needs to ignore new CBManager base class;
- CGImageMetadataTag.Value returns a mutable array on iOS10;
- MPMediaItem properties needed 9.2 / 10.0 check;
- MSMessage not available before Xcode 8;
- Metal not available before Xcode 6;
- MetalPerformanceShaders not available before Xcode 7;
2016-07-14 22:00:52 -04:00
Rolf Bjarne Kvinge 63811c85e5 [registrar] Use the correct parameters when generating category methods. Fixes #42489. (#385)
Category methods are exposed like extension methods, and the first parameter
specifies the class, which means we need to skip the first type when generating
the ObjC signature.

https://bugzilla.xamarin.com/show_bug.cgi?id=42489
2016-07-14 15:33:21 -04:00
Rolf Bjarne Kvinge 724308cb0d [registrar] Forward-declare ObjC classes. Fixes #42454. (#395)
There can be circular dependencies between Objective-C classes,
so make sure we don't fail compilation when that occurs by
forward declaring any Objective-C classes/protocols.

The test case in question does not contain a circular dependency,
but the same issue occurs due to types not being generated in the
correct order (a correct order could be constructed for the test
case, but there's no general solution since circular dependencies
can exist).

https://bugzilla.xamarin.com/show_bug.cgi?id=42454
2016-07-14 15:28:57 -04:00
Rolf Bjarne Kvinge ddfad1bc88 [registrar] Use the correct parameters when generating category methods. Fixes #42489. (#396)
Category methods are exposed like extension methods, and the first parameter
specifies the class, which means we need to skip the first type when generating
the ObjC signature.

https://bugzilla.xamarin.com/show_bug.cgi?id=42489
2016-07-14 18:42:30 +02:00
Rolf Bjarne Kvinge e6fc5a15d0 [runtime] Parse unions in objc encodings correctly. Fixes #42452. (#394)
Unions are defined as follows:

    (name=type...)

and we were not correctly parsing the 'name=' part.

https://bugzilla.xamarin.com/show_bug.cgi?id=42452
2016-07-14 18:03:02 +02:00
Vincent Dondain 23386a9217 [mediaplayer] Update for iOS 10 beta 1 - Part 1 (#386)
- Includes tests.
- Add availability flags.
- Turn new fields into properties.
- Verify bindings on iOS 9.3.
- Added protection in MPNowPlayingInfoCenter if native fields
  are not available (depending on the iOS version).
2016-07-14 08:45:30 -04:00
Sebastien Pouliot f085b17b36 [tests] Add missing version check on AUViewController tests. Fixes #42440 (#393)
Type was introduced in iOS 9, so it fails on earlier versions.

https://bugzilla.xamarin.com/show_bug.cgi?id=42440
2016-07-13 23:10:35 -04:00
Sebastien Pouliot b4ac7238b8 [tests] Add missing version check on AUViewController tests. Fixes #42440 (#393)
Type was introduced in iOS 9, so it fails on earlier versions.

https://bugzilla.xamarin.com/show_bug.cgi?id=42440
2016-07-13 23:04:18 -04:00
Sebastien Pouliot cf27c2e7a8 Merge branch 'cycle8' into xcode8 2016-07-13 16:43:00 -04:00
Vincent Dondain dd79e15f3b [monotouch-test] Fix permissions in Info.plist (#388) 2016-07-12 20:34:49 -04:00
Rolf Bjarne Kvinge a7a0bb4f05 [registrar] Forward-declare ObjC classes. Fixes #42454. (#387)
There can be circular dependencies between Objective-C classes,
so make sure we don't fail compilation when that occurs by
forward declaring any Objective-C classes/protocols.

The test case in question does not contain a circular dependency,
but the same issue occurs due to types not being generated in the
correct order (a correct order could be constructed for the test
case, but there's no general solution since circular dependencies
can exist).

https://bugzilla.xamarin.com/show_bug.cgi?id=42454
2016-07-12 20:34:18 -04:00
Rolf Bjarne Kvinge 249cf2f402 [runtime] Parse unions in objc encodings correctly. Fixes #42452. (#382)
Unions are defined as follows:

    (name=type...)

and we were not correctly parsing the 'name=' part.

https://bugzilla.xamarin.com/show_bug.cgi?id=42452
2016-07-12 20:19:06 -04:00
Sebastien Pouliot 7c6181dc66 [tests] Fix UIColor unit tests (in classic only) (#366)
Does not affect the Jenkins bots (which don't run classic tests) but
fails on wrench (who still runs them right now). There's a difference
in how equality is checked between classic and unified and that expose
a, not really important, change in iOS10.
2016-07-08 16:54:24 -04:00
Sebastien Pouliot afb3ea1e3f Bump Xcode version to beta 2 (#349)
Fix issues with monotouch-tests with beta2

* TLSMaximumSupportedProtocol returns Unknown, which also means default,
  instead of SslProtocol.Tls_1_2

* Setting NSZone.Name crash the app

* The MDLMesh tests are broken in a different way than beta1

* [callkit] Disable CTCallCenter default ctor as it breaks introspection

> [FAIL] Default constructor not allowed for CoreTelephony.CTCallCenter : SIGILL

The exception, that we catch, puts the process in an unstable state.

This cause weird results and crash later (wrong dispatch queue on main
thread) when testing MapKit.

Crashed Thread:        0  tid_a07  Dispatch queue: CTCallCenter

Exception Type:        EXC_BAD_ACCESS (SIGABRT)
Exception Codes:       KERN_INVALID_ADDRESS at 0x0000000000000004
Exception Note:        EXC_CORPSE_NOTIFY

VM Regions Near 0x4:
-->
    __TEXT                 0000000000097000-00000000004d2000 [ 4332K] r-x/rwx SM=COW  /Users/USER/Library/Developer/CoreSimulator/Devices/9446B344-62A2-42A8-A8EE-9FE7AC6BA5C8/data/Containers/Bundle/Application/81183608-DADF-4226-B7FE-4B43759D679A/introspection.app/introspection

Application Specific Information:
BUG IN CLIENT OF LIBDISPATCH: dispatch_barrier_sync called on queue already owned by current thread
abort() called
CoreSimulator 278 - Device: iPhone 5 - Runtime: iOS 10.0 (14A5297c) - DeviceType: iPhone 5

Some beta2 adjustments (removals) to get green tests and be able to merge it so bindings of beta2 can start

* [tests] NEFlowMetaData conformance to NSSecureCoding and NSCopying is new in beta2 (and check fails on OSX 10.11)

* [uikit] Add [UIScrollView|UITableViewController].refreshControl to fix monotouch-test build

UIRefreshControlHosting was removed in beta2 but we still need the
refreshControl property on UIScrollView and UITableViewController
to build monotouch-test
2016-07-07 13:10:24 -04:00
Vincent Dondain c8c27a01b2 [coretext] Update for iOS 10 beta1 (#346) 2016-07-05 16:49:59 -04:00
Sebastien Pouliot 5388f5d02f [coregraphics] Added new CGColorSpace API from iOS 10 beta 1 (#337)
Also updated unit tests.
2016-07-04 21:57:30 -04:00
Alex Soto 42b6cf57f1 [DictionaryContainer] Add support for CGRect/CGPoint/CGSize and CMTime
* Added support in DictionaryContainer for CGRect/CGPoint/CGSize and CMTime
* Added support for [StrongDictionary] using CGRect/CGPoint/CGSize and CMTime
* Added tests using DictionaryContainers for CGRect/CGPoint/CGSize and CMTime
2016-07-03 11:11:06 -05:00
Rolf Bjarne Kvinge 81a8e7aee7 [Foundation] NSUbiquitousKeyValueStore is not available on watchOS. (#333)
* [Foundation] NSUbiquitousKeyValueStore is not available on watchOS.

Fixes an issue found by the introspection tests when running on a
watchOS device.

* [monotouch-test] Fix watchOS build with regards to NSUbiquitousKeyValueStore changes.
2016-06-30 03:47:13 -07:00
Sebastien Pouliot 8b5a06df3d [coregraphics] Re-enable CGColorConverterCreateSimple API and tests (#325)
This was added in iOS 9.3 SDK but only worked on the simulator as the
calls were not present on the device libraries.

This is fixed in iOS 10 beta 1.

https://trello.com/c/Rwko9Wef/37-24734681-cgcolorconvertercreatesimple-is-missing-for-device-builds
2016-06-29 20:03:06 -04:00
Rolf Bjarne Kvinge 1bc24751d0 [monotouch-test] Fix watchOS build. (#317) 2016-06-29 06:28:30 -07:00
Rolf Bjarne Kvinge 7e773080a9 Merge remote-tracking branch 'origin/master' into xcode8 2016-06-29 10:23:03 +02:00
Rolf Bjarne Kvinge 464aab3789 [monotouch-test] Fix ContactStoreTest.GetUnifiedContacts to not completely ignore the second half of the test. (#307) 2016-06-28 15:04:36 -07:00
Rolf Bjarne Kvinge 5b3fcd002f [monotouch-test] Fix ContactStoreTest for watchOS. (#306) 2016-06-28 15:00:53 -07:00
Sebastien Pouliot e3ac382fc7 [corevideo] Small update for iOS 10 beta 1 (#280)
* [corevideo] Small update for iOS 10 beta 1

and tests for 4CC to enums conversion
2016-06-28 16:25:24 -04:00
Rolf Bjarne Kvinge d3b8de52d6 [monotouch-test] Try to fix UrlSessionTest.CreateDataTaskAsync by uploading using POST. (#304)
Also use https instead of http to avoid a network roundtrip
(since http://www.xamarin.com just redirects to https).

This will hopefully fix this random test failure:

    [FAIL] UrlSessionTest.CreateDataTaskAsync : CreateUploadTask a
2016-06-28 13:33:59 -04:00
Rolf Bjarne Kvinge 67cf4c1ccd [monotouch-test] Update ModelIO tests to use Xcode versioning. 2016-06-28 16:34:10 +02:00
Rolf Bjarne Kvinge 1a1958f52d Merge remote-tracking branch 'origin/master' into xcode8 2016-06-28 12:44:08 +02:00
Alex Soto 2b51bf257b [NS(mutable)Dictionary] Fix bug 41343 - NSDictionary<TKey, TValue>.FromObjectsAndKeys keys and values are twisted up (#281)
https://bugzilla.xamarin.com/show_bug.cgi?id=41343

* NSDictionary<TKey, TValue>.FromObjectsAndKeys keys and values are twisted up
* Fixed it in XAMCORE_4_0
* Obsoleted the 2 existing methods
* introduced FromObjectsAndKeys (TValue [] objects, TKey [] keys, nint count)
* Added unit tests with different types for TKey and TValue
2016-06-27 20:38:14 -04:00
Rolf Bjarne Kvinge 7e78269b3c [monotouch-test] Fix a few ModelIO tests according to iOS 10 behavior. (#286) 2016-06-27 15:48:51 -04:00
Rolf Bjarne Kvinge e2c2dc1061 [monotouch-test] Move version-checking code to a shared file. 2016-06-27 13:07:37 +02:00
Rolf Bjarne Kvinge d9610117a1 [monotouch-test] Ignore NSDataTest.Https on watchOS devices, the API doesn't work. 2016-06-27 13:07:37 +02:00
Rolf Bjarne Kvinge 343502ef52 [monotouch-test] Disable RuntimeTest.FinalizationRaceCondition/ResurrectedObjectsDisposedTest on watchOS/device, they use too much memory for the device. 2016-06-27 13:07:37 +02:00
Rolf Bjarne Kvinge d8b4fff4e3 [monotouch-test] Disable test that uses TcpClient on watchOS, since TcpClient doesn't work on watchOS. 2016-06-27 13:07:37 +02:00
Rolf Bjarne Kvinge 8a4178b141 [monotouch-test] Fix registrar/trampoline tests according to watchOS ABI. 2016-06-27 13:07:37 +02:00
Rolf Bjarne Kvinge 26b1c27b81 [monotouch-test] Disable NSUbiquitousKeyValueStore test, since it doesn't work on watchOS. 2016-06-27 13:07:37 +02:00
Rolf Bjarne Kvinge df640e61cd [monotouch-test] Disable test that uses TcpListener, since TcpListener doesn't work on watchOS. 2016-06-27 13:07:37 +02:00
Rolf Bjarne Kvinge e0e5824ce2 [monotouch-test] Set a timeout for UrlSessionTest so that the requests time out before the test itself. 2016-06-27 13:07:37 +02:00
Rolf Bjarne Kvinge 43da4642f1 [monotouch-test] Implement a non-GUI version of TestRuntime.RunAsync that works on watchOS. 2016-06-27 13:07:37 +02:00
Rolf Bjarne Kvinge b4bb30c13c [monotouch-test] Adjust tests according to watchOS behavior. 2016-06-27 13:07:37 +02:00
Rolf Bjarne Kvinge 0a8c6e3342 [tests] Check versions using Xcode version instead of platform version.
This is required to match API to the required platform version,
since our platforms have different version numbers.
2016-06-27 13:07:37 +02:00
Timothy Risi c94d0e7b70 Merge branch 'master' into xcode8 2016-06-23 10:45:09 -08:00
Vincent Dondain ca718991df [introspection] Fix bindings so the tests pass (#254)
- Added missing NSCopying, NSCoding and NSSecureCoding.
- Filled radar://26939747 with Apple - https://trello.com/c/6aIzLH4a
2016-06-22 17:32:00 -04:00
Sebastien Pouliot 004fe2f8d8 [tests][monotouch] More adjustments for iOS10 related failures/changes (#239)
* [tests][monotouch] More adjustments for iOS10 related failures/changes

- some might be Apple bugs and need to be reverted later

* Fix more failures on monotouch-tests wrt iOS 10

* MutableContactTest.cs: Wrong assert was changed (which is why each one
  needs it's own unique string)

* TrustTest.cs: Fixed as results vary on < iOS9, iOS9 and iOS10

* NetworkReachabilityTest.cs: Fixed as results vary on < iOS9, iOS9 and iOS10

Those

[FAIL] UserDefaultsTest.Ctor_UserName : System.NullReferenceException : Object reference not set to an instance of an object
[FAIL] UserDefaultsTest.SetString : StringForKey-2

are due to

http://stackoverflow.com/questions/37840288/ios-10-nsuserdefaults-does-not-work

and should disappear once the bots are rebooted.
2016-06-22 16:28:27 -04:00
Rolf Bjarne Kvinge c560fee268 [registrar] Managed characters are equivalent to shorts in native code. (#259)
Fixes NSCharacterSetTest.NSMutableCharacterSet_TestStaticSets when
running with the P/Invoke wrapper (for exceptions) enabled (i.e.
watchOS), since otherwise the wrapper would truncate char parameters
to byte.
2016-06-22 05:47:13 -07:00
Vincent Dondain aae5a73543 [messages] New framework in iOS 10.0 beta1 (#190) 2016-06-21 08:56:38 -04:00
Sebastien Pouliot 1659e121f0 Merge branch 'master' into xcode8 2016-06-20 20:48:14 -04:00
Sebastien Pouliot ebbc8addcc [tests] Some fix for monotouch-test needed wrt iOS 10 (#236)
* Adjust ever changing AddressFormatingTest for iOS 10, which does
  not output the country;

* Adjust Contact's ICNKeyDescriptor internal check;

* CLBeaconRegion.ProximityUuid does not return the original instance
  anymore, but a different one with the same uuid;

* Add a small delta for Vector3 comparison in ModelIO tests;

* Adjust MapKit tests for pin color change and MapRect corner case;

* SecKeyTest with corner cases now pass (they failed before);

* SecPolicyIdentifier.AppleIDValidation does not report the OID it's
  created from (migration?)

Note: some might be bugs that Apple will fix in later seeds
2016-06-19 09:32:01 -07:00
Rolf Bjarne Kvinge 1e62987a29 [CoreGraphics] Fix CGRect.Inflate to work correctly, and add tests. Fixes #41684. (#225)
https://bugzilla.xamarin.com/show_bug.cgi?id=41684
2016-06-17 10:45:58 -07:00
Manuel de la Pena f1e758c9e0 [Fix] Ensure NSExpression tests do run in the device ensuring that all members of the type are preserved.] 2016-06-17 11:19:07 +02:00
Rolf Bjarne Kvinge bdf7ca8429 [tests] Bump min deployment target to 6.0. (#208) 2016-06-15 19:12:48 -07:00
Alex Soto 69740e78ed [AudioUnit] Fix some breaking changes (#173)
commit 1f207bd3f3df363cb5a74e59b93acd8eb6e1fec2 in xamarin/maccore
introduced some breaking changes, this fixes them
2016-06-10 13:20:33 -04:00
Rolf Bjarne Kvinge bf806525f6 [monotouch-test] Simplify test case to make it compile on all platforms. (#163) 2016-06-09 20:03:18 +02:00
Rolf Bjarne Kvinge fac7270eb8 [registrar] Rewrite ctor's super call to invoke objc_msgSendSuper directly. Fixes #41319. (#159)
There's a clang bug [2] where if a selector is marked as unavailable,
it's marked as unavailable for every class, not just the class where
the unavailable selector is.

This means that we can't do `[super initWithCoder:x]` anywhere,
because `initWithCoder:` is marked as unavailable for UIActivityViewController.

So instead rewrite the call to super to call objc_msgSendSuper
directly, circumventing clang's broken availability checks.

[1] https://bugzilla.xamarin.com/show_bug.cgi?id=41319
[2] https://llvm.org/bugs/show_bug.cgi?id=28058
2016-06-09 17:18:35 +02:00
Rolf Bjarne Kvinge 4a714f3c43 Make logic not depend on the checkout directory being named 'xamarin-macios'. (#129) 2016-06-06 12:18:52 +02:00
Rolf Bjarne Kvinge db68e69a1d [runtime] Support binding NSObjects as IntPtr. Fixes #41132. (#103)
Support binding NSObjects as IntPtr. This is usually not
a problem, because when we fetch the ObjC signature for a
method, we usually get the signature as exported by us,
(in which case a parameter bound as 'IntPtr' would be treated
as 'void *' in the dynamic registrar) *except* when the
selector corresponds with a protocol the type implements,
in which case we get the signature as defined in the protocol.

https://bugzilla.xamarin.com/show_bug.cgi?id=41132
2016-05-31 11:58:27 +02:00
Rolf Bjarne Kvinge ecfdea9508 [tests] Import 2016-05-26 15:06:52 +02:00