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

497 Коммитов

Автор SHA1 Сообщение Дата
Bernhard Urban 4061adc2a4 [interp] fix mixed mode in Release configuration (#5230)
* [mtouch] do not strip assemblies when interpreter is used

* [xharness] add release mixed-mode configuration

* [xharness] enable debug mixed-mode config for mscorlib

* [mtouch] add link to mono issue
2018-12-11 17:51:05 +01:00
Rolf Bjarne Kvinge 55837e3d80
[xharness] Handle Process.HasExited throwing exceptions. (#5239)
Apparently Process.HasExited may throw exceptions, so handle those gracefully
(by ignoring them completely):

    Unhandled Exception:
     System.AggregateException: One or more errors occurred. (No process is associated with this object.) ---> System.InvalidOperationException: No process is associated with this object.
       at System.Diagnostics.Process.EnsureState (System.Diagnostics.Process+State state) [0x00018] in <d012d9eca6d14975a47488863de2f4c6>:0
       at System.Diagnostics.Process.get_HasExited () [0x0000b] in <d012d9eca6d14975a47488863de2f4c6>:0
       at (wrapper remoting-invoke-with-check) System.Diagnostics.Process.get_HasExited()
       at xharness.Process_Extensions+<>c__DisplayClass2_0.<RunAsync>b__2 () [0x00001] in <285dbdcf9e034cd496a3fef953fac640>:0
       at System.Threading.CancellationToken.ActionToActionObjShunt (System.Object obj) [0x00000] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.CancellationCallbackInfo.ExecutionContextCallback (System.Object obj) [0x00007] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.ExecutionContext.RunInternal (System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, System.Object state, System.Boolean preserveSyncCtx) [0x00071] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.ExecutionContext.Run (System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, System.Object state, System.Boolean preserveSyncCtx) [0x00000] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.ExecutionContext.Run (System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, System.Object state) [0x0002b] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.CancellationCallbackInfo.ExecuteCallback () [0x00024] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.CancellationTokenSource.CancellationCallbackCoreWork (System.Threading.CancellationCallbackCoreWorkArguments args) [0x00042] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.CancellationTokenSource.ExecuteCallbackHandlers (System.Boolean throwOnFirstException) [0x000c0] in <96207d0baa204f48a53ad6be05f5ecba>:0
        --- End of inner exception stack trace ---
       at System.Threading.CancellationTokenSource.ExecuteCallbackHandlers (System.Boolean throwOnFirstException) [0x00132] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.CancellationTokenSource.NotifyCancellation (System.Boolean throwOnFirstException) [0x0005f] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.CancellationTokenSource.Cancel (System.Boolean throwOnFirstException) [0x00006] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.CancellationTokenSource.Cancel () [0x00000] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at xharness.AppRunner+<>c__DisplayClass73_0.<RunAsync>b__0 (System.Object v) [0x00029] in <285dbdcf9e034cd496a3fef953fac640>:0
       at System.Threading.QueueUserWorkItemCallback.WaitCallback_Context (System.Object state) [0x00007] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.ExecutionContext.RunInternal (System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, System.Object state, System.Boolean preserveSyncCtx) [0x00071] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.ExecutionContext.Run (System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, System.Object state, System.Boolean preserveSyncCtx) [0x00000] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem () [0x00021] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.ThreadPoolWorkQueue.Dispatch () [0x00074] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback () [0x00000] in <96207d0baa204f48a53ad6be05f5ecba>:0
     ---> (Inner Exception #0) System.InvalidOperationException: No process is associated with this object.
       at System.Diagnostics.Process.EnsureState (System.Diagnostics.Process+State state) [0x00018] in <d012d9eca6d14975a47488863de2f4c6>:0
       at System.Diagnostics.Process.get_HasExited () [0x0000b] in <d012d9eca6d14975a47488863de2f4c6>:0
       at (wrapper remoting-invoke-with-check) System.Diagnostics.Process.get_HasExited()
       at xharness.Process_Extensions+<>c__DisplayClass2_0.<RunAsync>b__2 () [0x00001] in <285dbdcf9e034cd496a3fef953fac640>:0
       at System.Threading.CancellationToken.ActionToActionObjShunt (System.Object obj) [0x00000] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.CancellationCallbackInfo.ExecutionContextCallback (System.Object obj) [0x00007] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.ExecutionContext.RunInternal (System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, System.Object state, System.Boolean preserveSyncCtx) [0x00071] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.ExecutionContext.Run (System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, System.Object state, System.Boolean preserveSyncCtx) [0x00000] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.ExecutionContext.Run (System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, System.Object state) [0x0002b] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.CancellationCallbackInfo.ExecuteCallback () [0x00024] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.CancellationTokenSource.CancellationCallbackCoreWork (System.Threading.CancellationCallbackCoreWorkArguments args) [0x00042] in <96207d0baa204f48a53ad6be05f5ecba>:0
       at System.Threading.CancellationTokenSource.ExecuteCallbackHandlers (System.Boolean throwOnFirstException) [0x000c0] in <96207d0baa204f48a53ad6be05f5ecba>:0 <---
2018-12-07 15:07:21 +01:00
Rolf Bjarne Kvinge 544925738d
[xharness] Implement Process.WaitForExitAsync and use it instead of creating background threads. (#5207)
Using fewer threads is always good.
2018-11-30 16:49:03 +01:00
Rolf Bjarne Kvinge 8a81607279
[xharness] No need to spawn to kill, when we can just P/Invoke the corresponding function. (#5199)
* [xharness] No need to spawn to kill, when we can just P/Invoke the corresponding function.

* Revert accidental changes.
2018-11-29 19:36:04 +01:00
Rolf Bjarne Kvinge ae13240b20
[xharness] Don't recursively print diagnostics for processes when printing diagnostics times out in the first place. Fixes maccore#1163. (#5198)
Recursively printing diagnostics can leave us with _many_ lldb processes, each
pretty much hanging, and the system overloaded, which, in the worst case
scenario, would require a hard reboot.

Most commonly the "only" thing that happens is an OutOfMemoryException when
the OS eventually tells xharness NO to launching new processes.

Fixes https://github.com/xamarin/maccore/issues/1163.
2018-11-29 16:33:57 +01:00
Rolf Bjarne Kvinge 95a4b9a2a1
[xharness] Write intermediate html reports to disk when running in server mode too. (#5193)
That way the report is still available even if xharness dies.

Also improve report generation to write directly to a temporary file on disk,
instead of writing to memory and then writing to disk (improves memory usage).
2018-11-28 15:02:30 +01:00
Rolf Bjarne Kvinge 170711596d
[xharness] Create a timestamped log directory instead of timestamping every file inside it. (#5192)
Only for server mode right now, since otherwise it would break links for CI builds.
2018-11-28 11:59:01 +01:00
Rolf Bjarne Kvinge 8618db251c
[xharness] Show device/simulator loading in progress in the web UI. (#5186) 2018-11-27 17:02:39 +01:00
Rolf Bjarne Kvinge 943e7eafd5
[xharness] Add support for stopping queued tasks in the web UI. (#5185) 2018-11-27 14:59:44 +01:00
Manuel de la Pena 61b2038b3d
[Xharness] Add a workaround to not build the xunit tests when not needed. (#5156)
* [Xharness] Add a workaround to not build the xunit tests when not needed.

This is a workaround that does not use reflection to build the bcl test
projects. We need this until we have complete support of using mono as
an SDK.
2018-11-23 16:02:15 +01:00
Manuel de la Pena 3618cefc5a
[Harness] Reduce the noise in the make files. Fixes xamarin/maccore#1156 (#5154)
* [Harness] Reduce the noise in the make files.

The Makefile.cs code generates a lot of noise becuase it tries to build
a make rule for the new BCL tests, these rules do not work and can be
ignored.

Fixes issue: https://github.com/xamarin/maccore/issues/1156
2018-11-21 13:28:06 +01:00
Rolf Bjarne Kvinge f91e8fb811
Use a full path to xibuild. (#5140)
* Use a full path to xibuild.

Use a full path to xibuild everywhere, since it's easier than making sure PATH
is correct every time we want to invoke xibuild.

Also remove the xbuild-in-place script, it's not used anymore.

* Fix xibuild path lookup.

* [xammac_tests] Remove unneeded csproj changes.
2018-11-20 12:14:16 -05:00
Rolf Bjarne Kvinge 50bb4912e1
Revert "[xharness] Only build the BCL tests when we need them. (#5139)" (#5149)
This reverts commit 7277bbcd2b, it breaks building & running the new BCL tests.
2018-11-20 07:06:37 -05:00
Rolf Bjarne Kvinge 7277bbcd2b
[xharness] Only build the BCL tests when we need them. (#5139)
Only build the BCL tests when we need them, because we can't build them when
we're running the device tests (because we don't have a built source tree in
that case).

Since the test assemblies are required when generating the BCL projects, this
means we also delay creating the BCL projects until we need them.
2018-11-19 09:07:35 -05:00
Bernhard Urban f15233f3db [tests] enable msorlib with interpreter (#5122) 2018-11-19 07:18:12 -05:00
Ankit Jain f865694f86 Move tests to use new tool xibuild and thus fix msbuild tests (#5128)
* xibuild: New wrapper tool to run msbuild or managed executables

MSBuild supports fallback paths for projects imported using
`$(MSBuildExtensionsPath)`, but these must be specified explicitly in
the app.config of the main executable. There was a PR to allow use of
properties for this in the app.config, but that was not accepted
upstream.

This is required for being able to:

1. build projects with msbuild against the in-tree XI/XM build output
2. and to run nunit tests against the same.

For this we introduce a new tool, `xibuild`, based on XA's `xabuild`.
This supports the fallback paths to be specified via the environment variable
`MSBuildExtensionsPathFallbackPathsOverride`[1].
It essentially operates in 3 modes:

1. `xibuild -c /path/to/foo.exe`
	Generates /path/to/foo.exe.config with the fallback paths inserted into that.

2. `xibuild -- /v:diag /path/to/project.csproj`
	Runs msbuild with the arguments after `--` with a custom app.config based on
	`MSBuild.dll.config`, with the fallback paths correctly inserted.
	This is in a temporary file and the original config file is not touched.

3. `xibuild -t -- /path/to/managed_tool.exe args`
	Generates `/path/to/managed_tool.exe.config` based on `MSBuild.dll.config` with
	the fallback paths inserted, and runs `managed_tool.exe` with the arguments.
	The default is to overwrite the config file.
	But there is also a switch to merge it with an existing config file.

--
1. Value of the environment variable $MSBuildExtensionsPathFallbackPathsOverride
is prepended to any existing list of search paths in `MSBuild.dll.config`, IOW,
it takes precedence. So, the order of lookup becomes:

  - Value of the property `$(MSBuildExtensionsPath)`
  - Value of the environment variable `$MSBuildExtensionsPathFallbackPathsOverride`
  - /Library/Frameworks/Mono.framework/External/xbuild on macOS

* Integrate use of `xibuild` with the tests

Update all uses of `msbuild` and invocations of tools like nunit that
might depend on using the in-tree builds to use `xibuild`.

* xibuild: Move help descriptions to OptionSet itself.
2018-11-16 14:24:35 -05:00
Manuel de la Pena 505006952c
[Tests] Add a new iOS app to run the xunit and nunit tests (#4914)
Mono know provides a set of testing assemblies that contain the tests to be ran in each of the supported platforms. This commit adds the following:

1. Two different runners that can be used to execute NUnit and xUnit tests.
2. The necessary  glue to get xharness to run the new tests and report the results.
3. A new test that will ensure that if mono adds new tests, xharness will report failures if the tests are not run or not ignored.
2018-11-16 13:31:40 -05:00
Rolf Bjarne Kvinge ab2f931da6
[tests] Increase the timeout for 'Mac Binding Projects' from the default 5m to 15m. Fixes maccore#1125. (#5105)
Fixes https://github.com/xamarin/maccore/issues/1125.
2018-11-08 18:22:26 +01:00
Rolf Bjarne Kvinge fa440cf01c
[xharness] Make sure we don't run 'nuget restore' for tests-mac.sln multiple times in parallel. Fixes maccore#1122. (#5104)
Make sure we don't run 'nuget restore' for test-mac.sln multiple times in
parallel by creating a separate make target that runs 'nuget restore', and
making every build-mac-* target depend on that target.

Fixes https://github.com/xamarin/maccore/issues/1122.
2018-11-08 15:36:56 +01:00
Rolf Bjarne Kvinge 3835e1dafb
[tests] Point MSBuild to the right Xamarin.Mac location when building packaged Xamarin.Mac tests. Fixes maccore#1115. (#5090)
* [tests] Point MSBuild to the right Xamarin.Mac location when building packaged Xamarin.Mac tests. Fixes maccore#1115.

Fixes https://github.com/xamarin/maccore/issues/1115.

* [xharness] Ensure all makefile targets set the proper environment variables.
2018-11-07 09:34:16 +01:00
Rolf Bjarne Kvinge 27688e8d5b
[xharness] Fix the generation of the Mac makefile to export the right variables to use the locally build Xamarin.Mac. (#5087) 2018-11-06 15:06:58 +01:00
Bernhard Urban b9170ae434 [tests] enable monotouch-test with --interpreter=-mscorlib on Jenkins (#5051)
aka. mixed mode
2018-11-06 13:22:17 +01:00
Sebastien Pouliot 917214828d
[xharness] Log the environment variables in the execution logs (#5045)
While trying to debug an msbuild unit tests it was not possible to
successfully copy/paste the command from the execution log and
run it in a shell.

It's not that hard to run xharness and figure it out - but the
same can happen on bots (which could be harder).

So that little change prints out the host and xharness changes
to the environment variables to make copy/pasters life even
lazier :)
2018-10-26 13:34:08 -04:00
Bernhard Urban 9688c42e2d Bump mono and enable monotouch-test with interpreter (#5023)
* Bump Mono 2018-06

Commit list for mono/mono:

* mono/mono@c0fe724379 [aot] Reenable recursion checking when initing shared got entries (#11295)
* mono/mono@f55f7e53e3 [interp] use unsigned conversion for nuint (#11285)
* mono/mono@5986920bdb [2018-06] [arm64] Remove the limitation on the number of nullable arguments for dyncalls (#11266)
* mono/mono@665a308c39 [WinForms] Propagate the flags from DrawTextInternal to MeasureTextInternal (#11251)
* mono/mono@5ed4143b4f [2018-06] Crash Reporter V2 (#11162)
* mono/mono@f0db92c2b6 [interp] Implement interpreter entry trampolines on amd64 (#10978) (#11165)
* mono/mono@c1f1a7bfed [ci] Move OSX .pkg build to a separate bot pool
* mono/mono@d80ced607b [aot] Ensure shared got entries are initialized before loading methods (#11225)
* mono/mono@d07c626a74 [pkg] Add preinstall which removes existing Mono of the same version (#11209)
* mono/mono@cda3acc57c [sdks] futimens and futimes symbols are missing on anything earlier than 10.13 (#11174)
* mono/mono@226e91a064 Bump xunit-binaries

Diff: 2343f26706...c0fe724379

* [tests] enable monotouch-test with --interpreter on Jenkins
2018-10-24 15:24:22 -04:00
Rolf Bjarne Kvinge d899d4fb70
Remove bitrotted support for a separate mono submodule for watchOS support. (#5022)
Unce upon a time we used a separate mono submodule for watchOS support, to make
development of watchOS support easier (we referenced mono/master, to avoid
backporting fixes for watchOS support through various release branches in
mono).

This only worked until our watchOS support became stable, since then we had to
start using a stable version of mono for watchOS support.

This means that our build support for using a separate mono clone for watchOS
support is no longer needed; and in any case it's broken because of build
changes done later.
2018-10-22 16:14:26 +02:00
Rolf Bjarne Kvinge 250fd976a4
Merge pull request #4111 from radical/msbuild-port
[msbuild] Move from xbuild to msbuild
2018-10-15 16:55:53 +02:00
Rolf Bjarne Kvinge 904be25c25
[xharness] Generate a system variant of dont link, and run it using the oldest mono version we support in Jenkins. Fixes #4121. (#4968)
This is an addition to the tests we already run on older macOS bots (and as such will not execute on our PR bots).

Fixes https://github.com/xamarin/xamarin-macios/issues/4121.
2018-10-15 16:51:46 +02:00
Rolf Bjarne Kvinge 745c18cc73 Merge remote-tracking branch 'origin/master' into msbuild-port 2018-10-11 07:31:58 +02:00
Jo Shields 6f2ebedb74 Bump to mono:2018-06 (#4277)
* Bump to mono:2018-06

* Bump mono

* Updates compression to work with the public span

* Bump mono

* Fixes pointer check logic in Deflater

* Bump mono

* Fixes pointer check logic in Deflater

* Bump mono

* Bump Mono

* [runtime] always use `mono_jit_set_aot_mode` (#4491)

`mono_jit_set_aot_only` is deprecated and accidentally broke with
https://github.com/mono/mono/pull/7887

This should fix device tests with `mono-2018-06`

* Testing with Zoltan's patch

* Include libmono-system-native on Xamarin.Mac

* Bump Mono

Commit list for mono/mono:

* mono/mono@7bcda192a0 Bump llvm to release_60/fc854b8ec5873d294b80afa3e6cf6a88c5c48886. (#9786). (#9804)
* mono/mono@23e95ec7ad Apply F# portable pdb debug fix for pinvokes & bump (#9797)
* mono/mono@295f6d32af [2018-06] [MacOS] On Mac, use the copyfile API to copy files (#9696)

Diff: 7d5f4b6136...7bcda192a0

* Revert 4bacab3d5c, it doesn't fix the ios aot problems.

* Bump mono

* [tests] Adjust the MT0137 test for mcs change in behavior.

Starting with mono 5.16 mcs will now add assembly references when the assembly
is only used in attributes (this was already the case for csc in both 5.14 and
5.16, so it seems to be a compatibility change).

Adjust the MT0137 test accordingly.

* [msbuild] Fix parsing of json parser errors to handle trailing periods in the error message.

Fixes this test:

    1) Test Failure : Xamarin.iOS.Tasks.Bug60536.TestACToolTaskCatchesJsonException
         ColumnNumber
      Expected: 2
      But was:  0

* Bump mono

* [builds] Install the old llvm binaries into the LLVM36 directory and make the 32 bit builds use that.

* Bump mono

* Bump mono

* [jenkins] Don't give VSTS a fake branch. (#4667)

Something in VSTS changed, and now fake branch names don't work anymore.

So instead use real branch names (and for pull requests I've created a
'pull-request' branch we can use).

* Assembly.LoadFile accepts only absolute path

* [linker] Add new Facade (System.Threading.Tasks.Extensions).

Fixes these MTouch test failures:

    1. Xamarin.Linker.SdkTest.iOS_Unified :   Facades
      Expected:
      But was:  < "System.Threading.Tasks.Extensions" >

    2. Xamarin.Linker.SdkTest.tvOS :   Facades
      Expected:
      But was:  < "System.Threading.Tasks.Extensions" >

    3. Xamarin.Linker.SdkTest.watchOS :   Facades
      Expected:
      But was:  < "System.Threading.Tasks.Extensions" >

* [mono-sdks] Necessary changes to unify the LLVM provisioning for both iOS and Android. (#4732)

* Bump Mono

* [mtouch] add mixed-mode support (#4751)

* [mtouch] add --interp-mixed option

When enabling this option, mtouch will AOT compile `mscorlib.dll`.  At
runtime that means every method that wasn't AOT'd will be executed by
the runtime interpreter.

* [mtouch] Add support to --interpreter to list the assemblies to (not) interpret.

* [msbuild] Simplify interpreter code to use a single variable.

* Fix whitespace.

* [mtouch] Move mtouch-specific code to mtouch-specific file.

* [msbuild] An empty string is a valid value for 'Interpreter', so make it a non-required property.

* [mtouch] Add sanity check for aot-compiling interpreted assemblies.

* Bump Mono

* [linker] Updates SDKs facades list

* Bump mono

* [msbuild] Adds facades which might override default nuget version to framework list

The collision resolver task reads them from here https://github.com/dotnet/sdk/blob/master/src/Tasks/Common/ConflictResolution/FrameworkListReader.cs

* Bump to a VSfM version that can build XM Classic projects.
2018-10-10 11:02:28 -04:00
Rolf Bjarne Kvinge 1f5ba0b5c0
[xharness] Improve logging a bit. (#4952)
* [xharness] Improve logging a bit.

* Use timestamp in more log paths.
* Create numbered log subdirectories to make things nicer to look at in a
  terminal (thousands of subdirectories can be annoying to shift through; this
  way there's an additional subdirectory level).

* Avoid string interpolation when not needed.
2018-10-10 08:05:26 +02:00
Rolf Bjarne Kvinge e4db45ed63
[xharness] Add length consistency check when capturing a log file. (#4951)
Sometimes files just shrink, and we must cope.

Two possible causes I can think of:

* System log rotation.
* We erase a simulator when trying to capture its system log.

There are probably many more causes, but two is more than enough to make sure
we don't fail when it happens.
2018-10-09 15:53:51 +02:00
Rolf Bjarne Kvinge 232f9ecc8b
[xharness] Verify that there's at least 1GB of space left before trying to build or run each test. (#4937)
If there's not enough space, then fail the test.

This might help https://github.com/xamarin/maccore/issues/965 (test run hangs).
2018-10-08 07:32:50 +02:00
Chris Hamons 183cb81583
Disable known failing device tests using xharness (#4884)
- Add the ability to have Build Only tests - https://github.com/xamarin/maccore/issues/1076
- Set mini and the extensions as build only
2018-10-03 08:33:30 -05:00
Vincent Dondain 2174ec41a2 Merge branch 'xcode10' 2018-09-18 14:12:39 -04:00
Rolf Bjarne Kvinge 5a75130899
[xharness] Implement getting a reader for captured logs. (#4764)
Fixes an exception that might occur if the code that generates the html report
tries to process such logs (by trying to read them).
2018-09-06 16:13:49 +02:00
Rolf Bjarne Kvinge bbb8a41ef8
[xharness] Automatically pass -Os to the native linker when building watchOS extensions with the linker disabled. (#4757)
This works around https://github.com/xamarin/xamarin-macios/issues/4689 for our own unit tests.

This also requires bumping the build timeout, because unfortunately using -Os
makes builds *much, much* slower.
2018-09-06 10:16:53 +02:00
Rolf Bjarne Kvinge f0ac7594a8
[xharness] Add project configurations to run & debug Makefile generation. (#4739)
This also required a minor fix to allow relative directories as the root
directory.
2018-09-03 07:56:44 +02:00
Rolf Bjarne Kvinge 6f686a7729
[xharness] Don't try to run aggregated tasks when none of the contained tasks built successfully. (#4706)
Fixes this HarnessException when all simulator tasks for an aggregated run
simulator task fails to build (i.e. there is nothing to run):

    Harness exception for 'Tests for iOS_Unified32': System.InvalidOperationException: Sequence contains no elements
        at System.Linq.Enumerable.First[TSource] (System.Collections.Generic.IEnumerable`1[T] source) [0x0000b] in /Users/builder/jenkins/workspace/build-package-osx-mono/2018-04/external/bockbuild/builds/mono-x64/external/corefx/src/System.Linq/src/System/Linq/First.cs:16
        at xharness.AggregatedRunSimulatorTask+<ExecuteAsync>d__9.MoveNext () [0x00312] in /work/maccore/master/xamarin-macios/tests/xharness/Jenkins.cs:3582
        --- End of stack trace from previous location where exception was thrown ---
        at xharness.TestTask+<RunInternalAsync>d__92.MoveNext () [0x00113] in /work/maccore/master/xamarin-macios/tests/xharness/Jenkins.cs:2352
2018-08-29 17:42:28 +02:00
Rolf Bjarne Kvinge 41c719d2ab
[xharness] Fix failure message when nunit test times out. (#4708)
Fixes an issue where MTouch test would seemingly fail immediately:

    Failure: Execution timed out after 0 minutes.

when it's just saying that it failed out after [2 hours and] 0 minutes.

Fix it by showing the total number of minutes in the failure message.
2018-08-28 17:18:02 +02:00
Rolf Bjarne Kvinge bf4015bfbd
[xharness] Detect another scenario where failing to pair devices, and try again with a new watch device. Fixes maccore#961. (#4702)
Fixes https://github.com/xamarin/maccore/issues/961.
2018-08-28 07:41:22 +02:00
Rolf Bjarne Kvinge ea4909034b
[xharness] Be resilient when trying to copying contents from an inexistent file. (#4676)
Should fix this (or at the very least not prevent xharness from writing out the report):

    21:07:30.3947450 Failed to write log: System.IO.FileNotFoundException: Could not find file '/Users/builder/Library/Logs/CoreSimulator/6DA2ED3C-B1FA-4D0B-9DD6-113E5F9A1381/system.log'.
    File name: '/Users/builder/Library/Logs/CoreSimulator/6DA2ED3C-B1FA-4D0B-9DD6-113E5F9A1381/system.log'
        at System.IO.__Error.WinIOError (System.Int32 errorCode, System.String maybeFullPath) [0x00207] in /Users/builder/jenkins/workspace/build-package-osx-mono/2018-02/external/bockbuild/builds/mono-x64/mcs/class/referencesource/mscorlib/system/io/__error.cs:188
        at System.IO.FileInfo.get_Length () [0x00038] in /Users/builder/jenkins/workspace/build-package-osx-mono/2018-02/external/bockbuild/builds/mono-x64/mcs/class/referencesource/mscorlib/system/io/fileinfo.cs:171
        at xharness.CaptureLog.Capture () [0x0004a] in /Users/builder/jenkins/workspace/xamarin-macios/xamarin-macios/tests/xharness/Log.cs:334
        at xharness.CaptureLog.Flush () [0x00008] in /Users/builder/jenkins/workspace/xamarin-macios/xamarin-macios/tests/xharness/Log.cs:373
        at xharness.Jenkins.GenerateReportImpl (System.IO.Stream stream, System.IO.StreamWriter markdown_summary) [0x017db] in /Users/builder/jenkins/workspace/xamarin-macios/xamarin-macios/tests/xharness/Jenkins.cs:2012
        at xharness.Jenkins.GenerateReport (System.Boolean only_if_ci) [0x00075] in /Users/builder/jenkins/workspace/xamarin-macios/xamarin-macios/tests/xharness/Jenkins.cs:1313
2018-08-22 16:54:19 +02:00
Rolf Bjarne Kvinge 1d0e058636
[xharness] Replace existing content in TCC.db. Might fix maccore#951. (#4666)
There seems to be an issue where adding stuff to the TCC.db might fail
partially. In that case we try again, but we try to add every entry once more,
which now might fail due to existing entries.

So always replace when adding new entries in TCC.db. Also dump the database
when done to help debugging if it turns out this doesn't fix maccore#915.

Might fix https://github.com/xamarin/maccore/issues/951.
2018-08-21 19:11:23 +02:00
Rolf Bjarne Kvinge 965e1f7bcc Merge remote-tracking branch 'origin/xcode10' into xcode10-rebase-15.8 2018-08-16 17:09:30 +02:00
Sebastien Pouliot 605b992c62
Bump for beta 6 (#4613) 2018-08-15 13:23:31 -04:00
Vincent Dondain eec95e881c Merge branch 'd15-8' into xcode10-rebase-15.8 2018-08-13 21:04:56 -04:00
Rolf Bjarne Kvinge 9d65e42f58 Fix testing 32-bit XM apps. Fixes maccore issue 884. (#4555)
* [jenkins] Only XM apps with variations are Classic/32-bit apps, so adjust ignore logic accordingly. Fixes maccore issue 884.

Fixes https://github.com/xamarin/maccore/issues/884.

* [mmp] Fix passing -stdlib=libc++ to clang.

* [tests] Fix 32-bit XM issues.

* [xharness] Add support for building 32-bit XM apps by using Xcode 9.4.

* [xharness] Since xharness can now build 32-bit mac apps, enable them by default.

* Remove debug code.

* Remove unused variable.
2018-08-03 17:06:23 -04:00
Rolf Bjarne Kvinge 06d74108af Remove debug spew. 2018-07-27 17:41:47 +02:00
Rolf Bjarne Kvinge 50e05547aa [xharness] Process Import elements, but don't add LogicalName to them. 2018-07-27 17:40:29 +02:00
Rolf Bjarne Kvinge afcad3b4ba [xharness] Set the right variable to point msbuild to our locally built xbuild targets. 2018-07-27 11:41:23 +02:00
Rolf Bjarne Kvinge 19d9a64d02 [xharness] Don't add LogicalName beneath Import elements, it doesn't work with MSBuild. 2018-07-27 11:40:53 +02:00