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

8388 Коммитов

Автор SHA1 Сообщение Дата
Rolf Bjarne Kvinge 03cf7bb1c0
[msbuild] Remove Jeff as a code owner. (#8688) 2020-05-27 16:31:29 +02:00
Rolf Bjarne Kvinge af1323f4c5
[xharness] Always capture stdout/stderr from the simulator to actual files. (#8689)
This avoids confusion when tests are run locally using 'make runner' (and
would print the simulator's stdout/stderr to the terminal) versus when run on
bots (and would write the simulator's stdout/stderr to separate files that
would show up in the html report).
2020-05-27 15:31:20 +02:00
Rolf Bjarne Kvinge a3516c33aa
[xharness] Add crash reports to a logs collection we care about. (#8690)
Add crash reports to a logs collection we care about, instead of to a logs
collection that's promptly forgotten.

This makes sure crash reports actually show up in the html report.
2020-05-27 15:27:32 +02:00
Rolf Bjarne Kvinge 732847bd85
[jenkins] Use the existing DOTNET_NUPKG_DIR variable when looking for built nugets. (#8691) 2020-05-27 15:10:29 +02:00
Rolf Bjarne Kvinge 9fcda89ead [msbuild] Fix typo in the watchOS logic. 2020-05-27 10:23:52 +02:00
Connor Adsit 47f74578b3
satisfy the type-checking gods (#8680) 2020-05-27 08:49:37 +02:00
Rolf Bjarne Kvinge 7b834babca
[jenkins] Don't try to upload any packaged Xamarin.Mac tests if there aren't any or they failed to compile. (#8678) 2020-05-27 08:33:46 +02:00
Manuel de la Pena 488bce571e
[Harness] Refactor Hml generation. (#8686)
This is a step towards trying to make the modification of the html
easier for other team members, the are just to small logical changes:

1. Removed the GenerateReportImpl to a HtmlReportWriter.
2. Do not make the HtmlReportWriter call the Marckdown one, the are
independent.

There is room for improvement, since there are some collections
re-calculated. That change will come once we have this out of the way.

At some point, we ought to be able to make changes in the html just be
as hard as they should be (html + css, we are not experts on that).
2020-05-26 22:11:09 -04:00
Manuel de la Pena a512056c95
[Harness] Make sure that the error knowledgebase is used in device runs. (#8682)
The knowledgebase was just added in the simulator case, not in the
device. That meant that the tcp error was not reported.

Also added another possible case of tcp errors to be picked up and be
shown as a known error (device throws a diff error when on airplane
mode).

fixes: https://github.com/xamarin/xamarin-macios/issues/8659
2020-05-26 17:58:44 -04:00
Manuel de la Pena 6dfcd88fbd
[.gitignore] Ignore the json that is created on a device crash on xharness. (#8683)
Those files can be found when we test crashes locally and should not be
added to the project.
2020-05-26 16:34:22 -04:00
Sebastien Pouliot e819d09658
[corefoundation] Safer NativeObject (#8667)
Do not allow calling `CFRetain` or `CFRelease` on a null handle as this
will crash the process, instead use `GetCheckedHandle` so a managed (and
catchable) `ObjectDisposedException` can be thrown.

Make `GetCheckedHandle` public so subclasses (outside the platform
assembly) can use it - it's already recommended in some `[Obsolete]`
attributes (but was not made available).

Move the `ObjectDisposedException` thrower into a new `ThrowHelper`
class. This will allow sharing it (to be re-used in future PR).

Add unit tests for `NativeObject`.
2020-05-26 12:09:26 -04:00
Rolf Bjarne Kvinge 8c1f33bde7
[tools] Ignore generator.csproj when comparing generated code. (#8675)
Fixes an issue where generator.csproj would show up as a new file when
comparing generated output.

This probably regressed in 4b917ad2de.
2020-05-26 16:20:53 +02:00
Rolf Bjarne Kvinge 4f2d580426 [msbuild] Don't touch AssemblySearchPaths when building with net5.
We're supposed to resolve assemblies the standard/system way.
2020-05-26 14:49:31 +02:00
Rolf Bjarne Kvinge 91aa4e733a [msbuild] Don't include System.Drawing.Common.dll when building using net5.
There's no System.Drawing.Common.dll in net5.
2020-05-26 14:49:31 +02:00
Rolf Bjarne Kvinge 6e48c5a83a [msbuild] Don't import Microsoft.CSharp.targets if we're building using net5.
It's already imported.
2020-05-26 14:49:31 +02:00
Rolf Bjarne Kvinge cf1f8af55a [msbuild] Don't inject our existing build logic into the *DependsOn variables when building using net5. 2020-05-26 14:49:31 +02:00
Rolf Bjarne Kvinge 0aea29cf0a [dotnet] Import the existing targets files. 2020-05-26 14:49:31 +02:00
Rolf Bjarne Kvinge 6920817232 [dotnet/msbuild] Add existing targets files to the net5 NuGets. 2020-05-26 14:49:31 +02:00
Rolf Bjarne Kvinge 7c61734bd8
[msbuild] Fix pdb generation, ship the pdb and improve build logic. (#8672)
* The ILRepack package uses a 4-year old version of Mono.Cecil, which does not
  support portable pdbs. Work is in progress to use a newer version of
  Mono.Cecil (https://github.com/gluck/il-repack/pull/236), but this is taking
  some time (the PR is over a year old). In the meantime, switch to the
  ILRepack.MSBuild.Task package, which ships a forked and updated ILRepack.exe
  executable. This means the assembly merging process will produce a working
  pdb for the merged assembly, which in turn means we'll get stack traces with
  source code location.
* Update the makefile to ship the pdbs we produce. Also don't copy files into
  a temporary build/ directory, since it's not needed. This avoids an
  intermediate file copy.
2020-05-26 14:49:21 +02:00
Rolf Bjarne Kvinge 73e6ef0eff
[ObjCRuntime] Remove Classic code. (#8670)
Removing Classic code left us with a manually written Messaging class with a
single LIBOBJC_DYLIB field (in fact three identical versions for iOS+tvOS,
watchOS and macOS) + generator code to generate that field for third-party
libraries, so I just removed the three manually written files and made the
generator always generate the field.
2020-05-26 14:29:58 +02:00
Rolf Bjarne Kvinge c363d1baf1
[ObjCRuntime] Use _NSConcreteStackBlock instead of _NSStackBlock. (#8671)
_NSConcreteStackBlock is documented in http://clang.llvm.org/docs/Block-ABI-Apple.html.

It's not an actual Objective-C class, so we have to use dlsym to find its pointer.
2020-05-26 14:29:41 +02:00
Sebastien Pouliot 6449ac2561
[generator] Remove non-required `needs_null_check` check (#8668)
This is already checked earlier in the `foreach` loop so we already know
it to be `true` at this later stage.
2020-05-26 08:28:36 -04:00
Manuel de la Pena 17e413fa7b
[Harness] Move the logic to reload the simulators outside Jenkins. (#8658)
Following other PRs, try to reduce the work of the Jenkins class to
orchestrate the different classes and move any other logic to classes
with a single concern. Add tests for the new class.
2020-05-25 20:03:04 -04:00
Manuel de la Pena efd7fa6d46
[Harness] Move the resource manager implementation out of Jenkins. (#8660)
Move the resource management out of Jenkins. Add tests to the new class.
2020-05-25 16:10:50 -04:00
Rolf Bjarne Kvinge f0aa8ea4ec
[dotnet] Add a KnownFrameworkReference node to the targets to tell the .NETCore build system about us. (#8665)
Also add another nuget source to get Mono's net5 runtime packs.

This makes the tests/dotnet/MySingleView test app:

* Compile managed code successfully, referencing Xamarin.iOS.dll.
* Resolve the correct targeting and runtime packs (aka Mono).

The compiled result is not put into an .app bundle as iOS expects, so the
result isn't actually executable.
2020-05-25 17:38:35 +02:00
Sebastien Pouliot 33e757ccad
[addressbook] Remove unneeded ARCH_32 use (#8664) 2020-05-25 11:09:04 -04:00
Manuel de la Pena 98016a760e
[Harness] Move the periodic command execution logic out of Jenkins. (#8657)
Move the logic out, Jenkins class should just orchestrate all the diff
tasks but should not know how they are executed.
2020-05-25 10:00:57 -04:00
Rolf Bjarne Kvinge 98788f8558
[dotnet] Add the Sdk build files to the Sdk NuGet. (#8644)
Also add a very simple net5 test app (which doesn't build yet).

Current (expected) build result:

    > xamarin-macios/tests/dotnet/MySingleView $ dotnet build
    Microsoft (R) Build Engine version 16.7.0-preview-20258-02+26f6d1d87 for .NET
    Copyright (C) Microsoft Corporation. All rights reserved.

      Determining projects to restore...
    xamarin-macios/tests/dotnet/MySingleView/MySingleView.csproj : error NU1102: Unable to find package Microsoft.NETCore.App.Runtime.ios-x64 with version (= 5.0.0-preview.6.20264.1)
    xamarin-macios/tests/dotnet/MySingleView/MySingleView.csproj : error NU1102:   - Found 1 version(s) in nuget.org [ Nearest version: 5.0.0-preview.4.20251.6 ]
    xamarin-macios/tests/dotnet/MySingleView/MySingleView.csproj : error NU1102:   - Found 1 version(s) in Nuget Official [ Nearest version: 5.0.0-preview.4.20251.6 ]
    xamarin-macios/tests/dotnet/MySingleView/MySingleView.csproj : error NU1102:   - Found 0 version(s) in local-dotnet-feed
    xamarin-macios/tests/dotnet/MySingleView/MySingleView.csproj : error NU1102:   - Found 0 version(s) in Dotnet arcade
      Failed to restore xamarin-macios/tests/dotnet/MySingleView/MySingleView.csproj (in 951 ms).

This fails because the .NET build logic isn't being told that it should look
for the mono runtime packs instead of the .NET Core runtime packs.
2020-05-25 15:22:29 +02:00
Rolf Bjarne Kvinge d10a387ffa
[tests] Port cecil-tests to new-style csproj. (#8663)
Also switch xharness to build the csproj instead of running the makefile to
build the tests, because that way xharness is able to automatically use the
correct NUnit runner depending on the NUnit version the tests are using.
2020-05-25 14:47:20 +02:00
Rolf Bjarne Kvinge b601c5c62a
[xharness] Make AppBundleInformationParser.ParseFromProject async and make it take an ILog and a IProcessManager. (#8662)
This will be required in a later PR.
2020-05-25 14:47:10 +02:00
Rolf Bjarne Kvinge e73bf6cb29
[xharness] Don't use the MSBuild xml namespace when processing sdk-style projects. (#8647)
* [xharness] Don't use the MSBuild xml namespace when processing sdk-style projects.

The sdk-style projects don't use MSBuild's xml namespace, which means that it
will be added to every node we create if we use it.

* Fix merge conflict resolution failure.
2020-05-25 11:42:41 +02:00
Rolf Bjarne Kvinge 641a26e64b
[mmp] Use the GetPlatformFrameworkDirectory function to avoid duplicating code. (#8648) 2020-05-25 09:34:22 +02:00
Rolf Bjarne Kvinge eb3c1eeb0f
[xharness] Fix showing unit test failure list and summary when there are many failing tests. (#8649)
We'd check for more than 100 tests in the wrong location, and completely break
out of showing anything at all.
2020-05-25 09:34:01 +02:00
Manuel de la Pena 465ba9b2e7
[Harness] Move the Markdown code out of Jenkins + tests. (#8651)
Move the generation of the markdown out and add tests. Make sure that
the report writes the expected results and specially that it shows the
known issues.
2020-05-21 23:56:30 -04:00
Alex Soto fa171af71a
[master] Bump API diff to latest released stable (#8654) 2020-05-21 20:46:59 -04:00
Rolf Bjarne Kvinge 4166908f3c
[linker] Fix typo in comment. (#8646) 2020-05-21 18:49:30 +02:00
Manuel de la Pena ea514286ba
[Harness] Move the definition of the tasks outside of the jenkins class. (#8635)
Create some enumerables that will state the tests to run, that way, if
new tests need to be added, there will not be a need to edit the
jenkins class.

Add tests to ensure that all the tests are added. That away we will make
sure that tests are not removed by accident.
2020-05-21 12:48:05 -04:00
Alex Soto 5dc1b55dc6
[master] Merge Xcode11.5 Support and include provisionator changes (#8643)
New commits in xamarin/maccore:

* xamarin/maccore@4bfce64847 Update README.md
* xamarin/maccore@24682998f7 [devops] Enhance Xcode renaming script (#2206)
* xamarin/maccore@e03f16b862 [Localization][Mlaunch] Fix watchos timeout issue (#2196)

Diff: ad1696d6f3..4bfce64847
2020-05-21 12:16:33 -04:00
Rolf Bjarne Kvinge ac6258678c
[jenkins] Timeout the tests on older macOS bots after 15 minutes. (#8637)
Prevents deadlocks from holding up everything for hours:
https://jenkins.internalx.com/blue/organizations/jenkins/macios/detail/master/1583/pipeline/271/
2020-05-21 17:27:53 +02:00
Jonathan Peppers 2c43f9c62a
[msbuild] missing localization comments - part 2 (#8631)
Fixes: https://github.com/xamarin/xamarin-macios/issues/8494

Added a missing `<comment/>` field for `E0085`.
2020-05-21 08:11:46 -05:00
Rolf Bjarne Kvinge d5c17c8425
[msbuild] Simplify Makefile logic a little bit. (#8642)
* [msbuild] Remove unusued variable in Makefile.

* [msbuild] Simplify localization a little bit in the Makefile.
2020-05-21 15:09:10 +02:00
Sebastien Pouliot 6ecce641a2
[linker] Remove code to deal with ExportedTypes (#8632)
This is now supported by upstream mono/linker
2020-05-21 08:44:48 -04:00
Manuel de la Pena 406026cd1a
[Harness] When we have a known issue, add it to the markdown. (#8633)
If we have a knonw issue, lets add the message and the link to the
markdown so that the monitoring person does not need to look at the
html page.

fixes: https://github.com/xamarin/xamarin-macios/issues/8625
2020-05-20 21:58:09 -04:00
Connor Adsit 39aa2ff42a
Merge pull request #8630 from xamarin/cadsit-page-github-manifest-download
page through github statuses for manifest URL
2020-05-20 15:03:13 -04:00
Rolf Bjarne Kvinge 4bd68fd653 Fix code style. 2020-05-20 19:59:04 +02:00
Sebastien Pouliot 4cc33f4d80
[src] Use `Runtime.NSLog` instead of `System.Console.WriteLine` (#8626)
inside the product assemblies [1]. The latter brings a lot [2] of the BCL
into the application for, eventually, ending up back to `NSLog` anyway

Also include a, cecil-based, test to ensure we don't regress.

[1] except for Xamarin.Mac.dll since there's a workaround for a
Sierra (only) bug

[2] https://gist.github.com/spouliot/c63343c1a76f4e49248be3a2c7aa25ed
2020-05-20 13:38:44 -04:00
cadsit c3676e77b6 Check to see if the content has values (rather than being the empty string) 2020-05-20 13:36:19 -04:00
cadsit 12e644a6d9 page through github statuses for manifest URL 2020-05-20 13:06:02 -04:00
Rolf Bjarne Kvinge 518a95b61b
[src] Put the implementation assemblies for our product assemblies in the NuGet runtime packages. (#8628)
This is the current structure:

        Microsoft.iOS.Runtime.<rid>
        └─── data
        │    └─── RuntimeList.xml
        └─── runtimes
        │    └─── <rid>
        │    │    └─── lib
        │    │    │    └─── net5.0
        │    │    │    │    └─── Xamarin.iOS.dll
        │    │    │    │    └─── Xamarin.iOS.pdb

and likewise for tvOS, watchOS and macOS.

Also fix the nuget packaging to include the reference/implementation
assemblies in FrameworkList.xml and RuntimeList.xml.
2020-05-20 18:39:18 +02:00
Rolf Bjarne Kvinge 249bbc97d5
[src] Put the reference assemblies for our product assemblies in the NuGet reference package. (#8627)
This is the current structure:

	Microsoft.iOS.Ref
	└─── data
	│    └─── FrameworkList.xml
	└─── ref
	│    └─── net5.0
	│    │    └─── Xamarin.iOS.dll

and likewise for tvOS, watchOS and macOS.
2020-05-20 15:07:13 +02:00