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

3489 Коммитов

Автор SHA1 Сообщение Дата
Sebastien Pouliot 2bfbc8a834
[tests] Fix mac-apitest on High-Sierra (#3064)
MetalPerformanceShadersLibrary is new in macOS 10.13 and only available
for 64bits.

from https://wrench.internalx.com/Wrench/WebServices/Download.aspx?workfile_id=19778531

    Tests run: 248, Passed: 238, Errors: 0, Failures: 1, Inconclusive: 0
      Not run: 9, Invalid: 0, Ignored: 9, Skipped: 0
    Elapsed time: 00:00:11.3800000

    Errors and Failures:

    1) ExpectedLibrariesAreLoaded (Xamarin.Mac.Tests.EveryFrameworkSmokeTests.ExpectedLibrariesAreLoaded)
       MetalPerformanceShadersLibrary (/System/Library/Frameworks/MetalPerformanceShaders.framework/MetalPerformanceShaders) failed to load but this was not expected
      at Xamarin.Mac.Tests.EveryFrameworkSmokeTests.ExpectedLibrariesAreLoaded () [0x000c5] in /Users/builder/data/lanes/5665/74d2dcad/source/xamarin-macios/tests/apitest/src/EveryFrameworkSmokeTest.cs:99
      at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&)
      at System.Reflection.MonoMethod.Invoke (System.Object obj, System.Reflection.BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00032] in /Library/Frameworks/Xamarin.Mac.framework/Versions/4.1.1.45/src/mono/mcs/class/corlib/System.Reflection/MonoMethod.cs:305
2017-11-29 14:16:27 -05:00
Rolf Bjarne Kvinge 7fd2b67759
[xharness] Make it possible to select from the command line whether tests requiring system permissions should be executed or not. (#3053) (#3062) 2017-11-29 15:57:15 +01:00
Alex Soto 74d2dcadfb
[tests] Fix introspection tests for macOS (#3054)
* [tests] Fix introspection tests for macOS

It seems that apple forgot to ship SSLSetALPNProtocols and SSLCopyALPNProtocols in macOS
there are already radars filled about this https://bugs.swift.org/browse/SR-6131
So this test will fail once Apple fixes this issue. when this happens we need to do two things, reenable
the API and reenable the [Get|Set]AlpnProtocols tests, the one insides 'StreamDefaults' for the mac.

* Implement feedback
2017-11-28 17:27:20 -06:00
Rolf Bjarne Kvinge f21f48b727 [tests] Enable xammac-tests on wrench. (#3056)
Wrench runs `wrench-mac-xammac_tests`, but since there were no such target,
make would execute the `wrench-%` target, which is disabled when iOS is
disabled.

Thus this strange behavior would be seen on wrench for xammac tests when iOS
is disabled:

    /Applications/Xcode92-beta2.app/Contents/Developer/usr/bin/make -C /Users/builder/data/lanes/5665/d2b1b757/source/xamarin-macios/tests wrench-mac-xammac_tests
    git clean -xfdq
    iOS tests have been disabled [wrench-mac-xammac_tests]

By creating the `wrench-mac-xammac_tests` target, we'll end up doing the right
thing instead.
2017-11-28 16:10:56 -05:00
Timothy Risi 87f9e23989 [MetalPerformanceShaders] Xcode 9 bindings (#3005)
* [MetalPerformanceShaders] Activate bindings for Xamarin.Mac and add n… (#2816)

* [MetalPerformaceShaders] Several MPSCnnKernel properties should be readonly (#2938)

The subclasses versions of the properties need Override, cannot be removed since it would break visibility for iOS 10

* Remove some [Model] attributes that sholdn't be needed

* Fix introspection test crashes

* More introspection fixes

* NN does not need to be PascalCased

Remove unneeded Models and BaseTypes

* PR Whitespace fixes and renamings

* Paste fail

* More fixes from PR comments

* [MPS] Adds new intro test, fixes ctors and xtro output

* Removes duplicated availability attributes.
* Removes obsoleted API from macOS since mps is new to it.
* Fixes xtro output.
* Adds missing API.
* Fixes parameterless ctors, some of them do not really work, found
  by our new intro test and disabled the one that seem to not make
  sense due to the presence of DesignatedInitializers.
* Fixes a selector typo.
* Adds new `ShouldNotExposeDefaultCtorTest` to intro.

ShouldNotExposeDefaultCtorTest
==============================

This test checks for types with a parameterless ctor that are subclasses
of `NSObject` and then cheks if the BaseType of said objects also expose
a parameterless ctor (all in .NET land), if this is not the case it reports
them and so they can manually audited. Also this test has the ability to
print alloc/init ObjC code by setting `genObjCTestCode` to `true` so you can
take this code into an Xcode project and easily tests the ctors.

It seems that xtro (sharpie) does not have a complete picture of when a ctor
must be exposed hence the hability to generate this code and manually test.

Right now this test is just enabled for MPS since it is the scope of this PR.
In the future it should be enabled for all other frameworks and the output be
manually audited.

* [MPS] Fixes premature collection possible in bindings (bug 59547) and implements feedback.

https://bugzilla.xamarin.com/show_bug.cgi?id=59547

* Fixes premature collection possible in bindings im MPSKernel.cs
* Fixes MPSImageHistogramTest from using deprecated API.
* Removes renamed selectors and typos from ApiSelectorTest and ApiTypoTest.

* [MPS] Reenable Copy API and DesignatedInitializer xtro feedback

* Implement more feedback

* More feedback
2017-11-28 14:29:05 -06:00
Alex Soto d2b1b7578a
[HealthKit] Fix availability metadata on HKWorkoutRoute in order to fix intro in i 2017-11-27 16:46:20 -06:00
Sebastien Pouliot 4ad96b03fa
[security] Add bindings for Xcode 9 (#3043)
Also covers the missing enum value (added in xcode9) from
https://bugzilla.xamarin.com/show_bug.cgi?id=59278
2017-11-26 09:53:04 -05:00
Sebastien Pouliot f0915df335
[coreimage] Fix the pointer used in CIVector(nfloat[]) until the native call completes (#3038)
However there's a small window between the time we get a pointer
and the call to the native selector where the memory is not fixed.
During this time the GC can move the memory resulting in hard to
diagnose crashes.

Note: `initWithValues:count:` copies the provided memory so what
happens afterward is not an issue.
2017-11-24 09:55:11 -05:00
Timothy Risi da591eae51 [mac-introspection] Use en-US for ApiTypoTest, fix typo failures (#3018)
Also disables typo check for XM classic because:

`We have 823 typos!`

I'm not sure why but switching to the new API, which specify `en_US`,
seems to report more errors.

Unified API are already fixed and I don't see value in adding _ignore_
entries for classic (we don't add classic-only API anyway) so this
just makes then test built/executed for XAMCORE_2_0
2017-11-22 20:52:10 -05:00
Sebastien Pouliot a2d9c80cb5
[homekit] Expose weakly-typed API since the constants are extensible. Fixed #60303 (#3025)
This is a case of NSString enum extensibility - even if this framework does not use the usual `NS_EXTENSIBLE_STRING_ENUM` macro (which is recent and have not been applied for all framework / headers).

Minimally we need to provide alternative, weakly typed, `NSString`-based API wherever the (extensible) enums types are used. Not the best API (even if we can minimize it's use with `[EditorBrowsable (EditorBrowsableState.Advanced)]`) but C# enums can't be extended this way.

Also, even if less urgent, we need to make the enum-generated helper aware of the extensibility so they do not throw, making it easier to mix strongly and weakly typed code (instead of choosing one over the other).

Taking the first step for `xcode92` with the enum-backed constants in HomeKit, i.e.
* HMAccessoryCategoryType
* HMCharacteristicType
* HMServiceType
* HMSignificantEvent

Reference
https://bugzilla.xamarin.com/show_bug.cgi?id=60303

* [tests] WeakSignificantEvent is a weakly typed alternative (not a weak argument semantic)
2017-11-21 20:50:33 -05:00
Sebastien Pouliot aee2c96d9e kick a new build on jenkins (and publish it) 2017-11-20 11:36:20 -05:00
Vincent Dondain f307f377a1 [coreimage] Add new Image Dictionary Keys
- Fixes bug #59296: [coreimage] Some `kCI*`keys are not bound
  (https://bugzilla.xamarin.com/show_bug.cgi?id=59296)
- Generate a StrongDictionary for `CIImageInitializationOptions` to avoid manual code.
- Move `CGImageProperties Properties { get; set; }` to parent type `CIImageInitializationOptions` (avoid 2 strong dictionaries).
  Reason:
  Even though the headers give us an indication of which constructors should use some CIImage keys it's hard to apply that
  to all constructors consistently.
  We could have 1 strong dictionary per constructor (duplicate members) with just the exact members we know it supports (based on headers) however
  it's better to have a single strong dictionary and document the options because A might be available only in X today and Y next too next year.
- Fix `DictionaryContainer`'s `GetStrongDictionary` to return null
and not throw if target StrongDictionary is not yet set.

Basically:

```
var options = new CIImageInitializationOptionsWithMetadata ();
            Assert.That (options.Dictionary.Count, Is.EqualTo (0), "Count");
```

Would throw:

```
System.Reflection.TargetInvocationException : Exception has been thrown by the target of an invocation.
  ----> System.ArgumentNullException : Value cannot be null.
```
2017-11-19 14:42:01 -05:00
Vincent Dondain fc7f6ce1be [coreimage] Add EditorBrowsableState.Advanced to CIImage's NSDictionary .ctor 2017-11-19 14:42:01 -05:00
Sebastien Pouliot 9453395bae Kick a new build so it gets published publicly thru jenkins 2017-11-17 15:40:39 -05:00
Vincent Dondain 30a057ddc0
[CoreImage] Update filters for Xcode 9 (#2974)
- Fixes bug #57350: Review new CoreImage filters added in Xcode 9
(https://bugzilla.xamarin.com/show_bug.cgi?id=57350).
- Adds `AVCameraCalibrationData` and `CIBarcodeDescriptor` to `generator-filters`.
- Fixes `ApiCoreImageFiltersTest`'s `GenerateBinding` to use valid `[CoreImageFilterProperty]`.
- In `CheckManagedFilters` generate code of SuperClass when detected so it's easier to bind.
2017-11-16 16:38:14 -05:00
Sebastien Pouliot f4fc3d0be0
[monotouch-test] Fix ContactStoreTest for watchOS (#3006)
Backport/merge of PR #306 to avoid random failures on bots.
Should fix https://github.com/xamarin/maccore/issues/577
2017-11-14 16:10:19 -05:00
Vincent Dondain 311fe265f8
[storekit] Fix SKCloudServiceSetupOptions strong dictionary's 'Action' (#2998)
- Fixes bug #59928: SKCloudServiceSetupViewController.LoadAsync() does not work correctly when passed an SKCloudServiceSetupOptions object instead of a manually-created NSDictionary
(https://bugzilla.xamarin.com/show_bug.cgi?id=59928)
2017-11-14 10:12:58 -05:00
Rolf Bjarne Kvinge 6f8cb8e9e8
[xharness] Try to fix apparently impossible infinite loop. Might fix bug #59208. (#3004)
https://bugzilla.xamarin.com/show_bug.cgi?id=59208
2017-11-14 15:11:52 +01:00
Sebastien Pouliot e05048f182
Merge latest d15-5 (#3002)
* Updated reference to mono/mono@950ea65 (#2975)

* [macos] Fix AVCaptureDepthDataOutput on HS and 10.13 typo (#2977)

* [tests] Remove merge dupe for 'Hlg' typo
2017-11-14 08:51:41 -05:00
Alex Soto f2ae295b9b
[AVKit] Update to Xcode 9.2 Beta 2 (#2995)
* [AVKit] Update to Xcode 9.2 Beta 2

* Implement feedback

* Fix typo

* Fix breaking change 🙈 oops!

Also throw something so the code path just doesn't do anything

* Idk what happened, fixing breaking change now for reals 🙃
2017-11-13 10:45:04 -06:00
Sebastien Pouliot c90c32b2b3
[apidiff] Update XML references from latest d15-5 build (#2999) 2017-11-13 11:44:28 -05:00
Sebastien Pouliot c0ceb65b74
[mediaplayer] Update up to Xcode 9.2 beta 2 (#2994) 2017-11-13 09:17:35 -05:00
Sebastien Pouliot 58b6f6eca3
[corebluetooth] Update up to Xcode 9.2 beta 2 (#2990)
Add a new constant.

This was added in Xcode 9.2 SDK for iOS and tvOS - even if the constant
is marked as existing for a while (iOS 6) but that turned out to be incorrect

This was added for watchOS in the *final* Xcode 9.1 SDK.

This has not _yet_ been exposed in the macOS SDK.
2017-11-10 15:47:13 -05:00
Sebastien Pouliot e21a5b9a75
[xharness] Fix clearing simulator state. Fixes #60229 and #58951. (#2904) (#2993)
Fix clearing the simulator state by properly finding the correct simulators
from tasks that will actually run, and not from potentially ignored/failed
tasks (which won't have necessarily simulators).

https://bugzilla.xamarin.com/show_bug.cgi?id=58951
https://bugzilla.xamarin.com/show_bug.cgi?id=60229
2017-11-10 15:38:19 -05:00
Alex Soto 4ab10b0c3a
[AVFoundation] Update up to Xcode 9.2 Beta 2 (#2978)
* [AVFoundation] Update up to Xcode 9.2 Beta 2

* implement feedback
2017-11-10 14:19:38 -06:00
Alex Soto 4c00387fdc
[HomeKit] Update up to Xcode 9.2 Beta 2 (#2981)
* [HomeKit] Update up to Xcode 9.2 Beta 2

* Fix feedback
2017-11-10 11:18:24 -06:00
Alex Soto 637e950426
[SceneKit] Update up to Xcode 9.2 Beta 2 (#2985)
* [SceneKit] Update up to Xcode 9.2 Beta 2

* implement feedback
2017-11-10 11:16:55 -06:00
Alex Soto 651a3f73e8
[CoreML] Update up to Xcode 9.2 Beta 2 (#2979)
* [CoreML] Update up to Xcode 9.2 Beta 2

* Add global::
2017-11-09 15:27:21 -06:00
Sebastien Pouliot 1d393f9df5
[coreanimation] Update up to Xcode 9.2 beta 2 (#2973) 2017-11-09 15:51:24 -05:00
Sebastien Pouliot 53ff499b26
[watchos][watchkit] Update up to Xcode 9.2 beta 2 (#2988) 2017-11-09 15:50:28 -05:00
Sebastien Pouliot eeb8f823af
[uikit] Update to Xcode 9.2 beta 2 (#2991) 2017-11-09 15:44:53 -05:00
Sebastien Pouliot bb05a29b6b
[localauthentication] Update up to Xcode 9.2 beta 2 (#2989)
... which adds some existing (iOS) API to macOS.
Also provide a better enum name for FaceId [1]

[1] https://bugzilla.xamarin.com/show_bug.cgi?id=60537
2017-11-09 15:39:33 -05:00
Alex Soto 36bcb4dbde
[StoreKit] Update up to Xcode 9.2 Beta 2 (#2986) 2017-11-09 08:55:11 -06:00
Alex Soto 26703bc311
[Intents] Update up to Xcode 9.2 Beta 2 (#2982)
* [Intents] Update up to Xcode 9.2 Beta 2

* Fix message
2017-11-09 08:45:25 -06:00
Alex Soto f2da9cde6b
[xtro] Re-enable InputMethodKit in xtro tests, fixes bug 57241 (#2987)
https://bugzilla.xamarin.com/show_bug.cgi?id=57241
2017-11-09 08:41:06 -06:00
Alex Soto f5c5b794a4
[PDFKit] Update up to Xcode 9 Beta 2 (#2983) 2017-11-08 20:31:55 -06:00
Alex Soto 1d13a065f7
[ReplayKit] Update up to Xcode 9.2 Beta 2 (#2984) 2017-11-08 20:29:47 -06:00
Alex Soto 9e23972076
[HealthKit] Update up to Xcode 9.2 Beta 2 (#2980) 2017-11-08 20:26:51 -06:00
Sebastien Pouliot 548d0d2192
[passkit] Update up to Xcode 9.2 beta 2 (#2972)
Update (again) a typo in a constant
2017-11-08 14:42:38 -05:00
Sebastien Pouliot 3916b8fc8d
Merge pull request #2970 from spouliot/xcode92-beta2
Bump Xcode and versions for 9.2 beta 2
2017-11-08 09:12:44 -05:00
Sebastien Pouliot 526160d12d [tests] Fix XM build for monotouch/xammac-tests 2017-11-07 22:45:31 -05:00
Sebastien Pouliot f702512483 [tests] Handle a 2nd case where ContactStoreTest.GetUnifiedContacts can fail on bots 2017-11-07 20:52:35 -05:00
Sebastien Pouliot e68acf1caa [tests] Handle possible access denied in ContactStoreTest.GetUnifiedContacts
For some reason this happens with the watchOS 4.2 simulator on our
Jenkins bots (but not locally for me).

The test is updated to ignore errors as depending on the sim default
content does not seems possible.
2017-11-07 15:35:10 -05:00
Sebastien Pouliot 93118069ee [tests] Fix monotouch-tests to execute without failure with xcode 9.2 beta 2 2017-11-07 14:48:16 -05:00
Sebastien Pouliot e3d4846811 [test][dontlink] Simplify 'Autorelease' test not to depend on version specific return values 2017-11-07 13:25:17 -05:00
Sebastien Pouliot 54d9faf0b0 [tests] HMHomeAccessControl conformance to NS[Secure]Coding is not documented 2017-11-07 12:04:19 -05:00
Sebastien Pouliot d424ed7dd1 [contacts] CNContactFormatter now conforms to NSSecureCoding 2017-11-07 12:03:42 -05:00
Sebastien Pouliot d19b089343 Bump Xcode and versions for 9.2 beta 2 2017-11-07 11:19:09 -05:00
Sebastien Pouliot bf28681e0d
Merge pull request #2961 from timrisi/SceneKitFix
[macOS] Fix Introspection and API tests (#2891)
2017-11-06 16:29:18 -05:00
Sebastien Pouliot 48274ee882
[apidiff] Update API references to XI 11.3 (xcode9 support) (#2959) 2017-11-06 13:21:30 -05:00