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

64 Коммитов

Автор SHA1 Сообщение Дата
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
Rolf Bjarne Kvinge 7ea03b8dd8
[jenkins] Hide the list of packages by default. (#8595)
* [jenkins] Hide the list of packages by default.

The list of packages got big with the NuGet packages, and we usually don't
want to see the whole thing, so hide it by default.

* Add newline to fix markdown parsing.
2020-05-14 15:47:47 +02:00
Rolf Bjarne Kvinge 5834572741
Create and publish .NET NuGet packages. (#8576)
Create the various NuGet packages to support .NET 5+. The packages are
currently empty (and not very useful), but the actual content will come later.

The current set of NuGet packages are (this list is duplicated for each
platform: iOS, tvOS, watchOS and macOS):

* Microsoft.iOS.Sdk: currently contains the basic MSBuild targets files for an
  MSBuild Project SDK. Will eventually contain all the build logic. Might also
  eventually contain other tools (mlaunch, bgen, etc.), but these might also
  end up in a different package.
* Microsoft.iOS.Ref: will contain the Xamarin.iOS.dll reference assembly.
* Microsoft.iOS.Runtime.[RID]: will contain architecture-specific files
  (libxamarin*.dylib, the Xamarin.iOS.dll implementation assembly, etc.):

The NuGets built on CI are automatically published to a NuGet feed.

The versioning for the NuGet packages required a few changes: OS bumps are now
changed in Make.versions instead of Make.config (this is explained in the
files themselves as well).
2020-05-13 15:23:29 +02:00
Rolf Bjarne Kvinge 024538e1ba
[jenkins] Don't show multiple identical failed stages. (#8560) 2020-05-11 14:27:55 +02:00
Rolf Bjarne Kvinge 1457f8666d
[jenkins] Add support for specifying custom labels using a file. (#8549)
This makes it possible to select what should be done on CI when building a
commit on internal Jenkins (as opposed to when building a pull request, in
which case labels can be set on the pull request).
2020-05-08 15:44:41 +02:00
Rolf Bjarne Kvinge 81f019a59e
[jenkins] Provide a login keychain password when installing provisioning profiles. (#8456)
This seems to fix an issue where the login keychain would somehow end up
locked, which would break provisioning.
2020-04-27 08:32:36 +02:00
Rolf Bjarne Kvinge aa45a2d6e7
[jenkins] State all the time where we're working on. (#8447)
It's annoying to have to track it down all the time when something goes wrong.
2020-04-23 10:10:50 +02:00
Rolf Bjarne Kvinge 936ec3c3fc
[jenkins] Fix error reporting for the 'Generate Workspace Info' stage. (#8442)
* Set the 'currentStage' variable upon entry so that reporting reports any
  problems in the correct stage.
* Rewrite the 'getRedirect()' exception message to not use an undefined
  variable (content).
2020-04-22 08:49:04 +02:00
Rolf Bjarne Kvinge 151342ba23
[jenkins] Add a timeout to the final tasks as well. (#8390)
This makes it so that if something goes wrong when publishing results and it
ends up stuck, the job won't stay hung for days until we realize what's
happening.
2020-04-16 09:47:03 +02:00
Rolf Bjarne Kvinge 105dc14dd7
[jenkins] Add missing parenthesis in text. (#8135) 2020-03-18 16:22:57 +01:00
Rolf Bjarne Kvinge 9b63357612
Limit GitHub comments to 32768 characters. (#8084)
GitHub has a limit of twice that for comments, but 32k should be more than
enough to say what we want to say.
2020-03-11 19:56:50 +01:00
Sebastien Pouliot afe664fd95
[jenkins] Switch to use the catalina bot group (#7819) 2020-02-07 13:02:15 -05:00
Manuel de la Pena 18d05d1e30
[Jenkins] Fix JenkinsFile groovy. (#7732) 2020-01-21 13:34:47 -05:00
Rolf Bjarne Kvinge f8951f092e
[jenkins] Fix a couple of issues. (#7726)
* Fix fetching author's name + email for failure reporting by running git in
  the directory where the repo actually is.
* Don't fail the build if we fail to generate/upload artifacts.json, instead
  show the failure everywhere and continue as if nothing happened. There seems
  to be a random issue with GitHub where a network request fails, and there's
  no need for that to fail the entire build.
2020-01-21 06:59:57 +01:00
Manuel de la Pena baf3d117f5
[VSTS] Bump maccore and ensure that the status can be posted. (#7718)
Bump maccore so that a status is posted when the device tests cannot be
scheduled. Update the JenkinsFile to make sure that the required token
is passed to the launch.sh script.
2020-01-15 17:06:19 -05:00
Rolf Bjarne Kvinge d94d2f1ae6
[Jenkins] Make it possible to trigger device tests from PRs built on internal Jenkins. (#7424) 2019-11-13 22:07:20 +01:00
Rolf Bjarne Kvinge e23362854e
[tests] Add make target to manually launch a device test run for the current commit. (#7282)
* [tests] Add make target to manually launch a device test run for the current commit.

* Upload a manifest that can be found using only the hash, and use it to find the packages.
2019-11-07 22:41:24 +01:00
Connor Adsit 0f7213d481 Notarization tweaks (take 2) (#7287)
* Only notarize CI builds; timeout after 90 min

* Update jenkins/Jenkinsfile

Co-Authored-By: Rolf Bjarne Kvinge <rolf@xamarin.com>

* Don't upload notarized pkgs if it fails

* Update jenkins/Jenkinsfile

Co-Authored-By: Manuel de la Pena <mandel@microsoft.com>
2019-10-24 07:48:50 +02:00
Rolf Bjarne Kvinge e919ae7f7a Revert "Only notarize CI builds; timeout after 90 min (#7280)"
This reverts commit cd396d63cc.
2019-10-23 08:10:47 +02:00
Connor Adsit cd396d63cc Only notarize CI builds; timeout after 90 min (#7280)
* Only notarize CI builds; timeout after 90 min

* Update jenkins/Jenkinsfile

Co-Authored-By: Rolf Bjarne Kvinge <rolf@xamarin.com>
2019-10-23 07:46:55 +02:00
Rolf Bjarne Kvinge 303aa0a649 Merge remote-tracking branch 'origin/xcode11' into master-xcode11 2019-09-13 18:35:18 +02:00
Rolf Bjarne Kvinge 0008c20abf
Implement notarization. (#6928)
* Add a dummy x86_64 slice to all our native libraries that don't have one. (#6848)

Apple's notarization tool has a bug where they incorrectly flag Mach-O
binaries without an x86_64 slice, so make sure all our libraries have one.

* Jenkinsfile notarization (#6869)

* Add in notarization script for xamarin.mac/xamarin.iOS

* Flatten the list to get rid of the braces

* Add in keychain password

* Add login.keychain back in to access codesigning certificates

* Always sign pkgs, upload notarized copies

* Enable ios notarization and make notarized pkgs public

* Make notarization non-fatal

* Publish GH statuses for notarized PKGs

* Don't forget to declare URI variables for notarized pkgs

* report proper package links

* [jenkins] Improve package reporting.

* Use dummy function name which our tests won't complain about.
2019-09-09 00:34:11 -07:00
Connor Adsit c384add291 Jenkinsfile notarization (#6869)
* Add in notarization script for xamarin.mac/xamarin.iOS

* Flatten the list to get rid of the braces

* Add in keychain password

* Add login.keychain back in to access codesigning certificates

* Always sign pkgs, upload notarized copies

* Enable ios notarization and make notarized pkgs public

* Make notarization non-fatal

* Publish GH statuses for notarized PKGs

* Don't forget to declare URI variables for notarized pkgs

* report proper package links

* [jenkins] Improve package reporting.
2019-09-02 03:35:14 -07:00
Rolf Bjarne Kvinge 22b8c8c169
[tests] Package Xamarin.Mac tests using 7z instead of zip. (#6583)
This makes the package 33% smaller (from 176mb to 117mb).
2019-07-22 00:30:14 -07:00
Rolf Bjarne Kvinge 121f04ce3d
[tests] Improve handling of permission dialogs. Fixes xamarin/maccore#1856. (#6544)
* macOS 10.15 starts putting up permission dialogs we can't automatically
  dismiss anymore, so start honoring the 'IncludeSystemPermissionTests' option
  for macOS tests.
* Improve the 'IncludeSystemPermissionTests' option to have three states: if
  set (either true or false), that takes precedence, but if not set, we now
  don't run any tests that require permission dialogs on macOS or on device if
  we're running in CI. Tests executed locally will still put up dialogs, both
  on macOS and on device.
* This needed a few changes to the html report, since the
  'IncludeSystemPermissionTests' is exposed in the UI and the code didn't
  handle the three different states.
* Update a few tests to check for permission to the contacts.

Fixes https://github.com/xamarin/maccore/issues/1856.
2019-07-12 07:05:57 -07:00
Rolf Bjarne Kvinge 885ed0d4b9
[jenkins] Adjust global timeout. (#6092)
We have a 13-hour timeout for running the tests [1], but that won't work if
the timeout for the entire Jenkins pipeline is lower, so adjust the timeout
for the entire Jenkins pipeline to be more than the sum of all the nested
timeouts.

[1] 94fe39b118 (diff-68c8473bbe1d4346ecff3d74522a31f8R675)
2019-05-21 21:58:42 -07:00
Manuel de la Pena 94fe39b118
[XHarness] Do use the test dlls from the mono downloads. (#6055)
This updates the project generation. We cannot yet fully remove the submodule because:

* We are missing the xunit dlls which should be added in the SDK.
* We have not yet remove all the old style tests. Would make the PR huge, better to deal with it in a diff PR.
* The xunit CoreLib tests have issues loading all the tests, needs some extra work and again, the PR is already large.

Fixes: xamarin/maccore#1199
Fixes: xamarin/maccore#1204
Fixes: xamarin/maccore#1209
Fixes: xamarin/maccore#1510
2019-05-19 14:55:14 -07:00
Manuel de la Pena 81d6225eb7
[XHarness] Fix some issues in the BCL test generator. (#5938)
We had issues in the code that adds a type found in an assembly to
ensure that it was not removed by the linker. This resulted in some
assemblies having 0 tests.

Added the needed ignore for the corlib tests and system ones.
2019-05-11 12:03:38 +02:00
Rolf Bjarne Kvinge bd457212d5
[tests] Add sample tester. (#5870)
* [tests] Add sample tester.

Add a unit project that looks for iOS/macOS/tvOS sample projects in several
repositories, and builds them all.

* [tests][sampletester] Remove known issue which has now been fixed.

* [tests] Only run sample tests on CI in Azure Devops.

* Remove the possibility of automatically running the sample tests with
  xharness (so the sample tests won't run on PR bots or internal bots when the
  'run-all-tests' label is added). It's still possible to run the sample tests
  manually from the xharness web UI.

* Automatically trigger the sample test run in Azure Devops if the
  'run-sample-tests' label is applied to a PR (and that PR is executed on
  internal Jenkins).

* Fix typo.

* Fix path.

* Verbose output to track down scheduling failure.

* Bump maccore to get improved debug spew.

Diff: f527c9c526..f89d74b165

* [tests][sampletester] Fix build for TodoWCF.
2019-04-25 17:18:43 +02:00
Rolf Bjarne Kvinge d4e41445a2
[jenkins] Set a 1h build timeout. (#5893)
Builds take approximately 30 minutes on a bot now, so 1 hour should be plenty.

This makes sure a 32-bit dialog doesn't waste 9h of bot time just sitting
there.
2019-04-12 19:06:04 +02:00
Vincent Dondain 86d1b42ad2 Merge branch 'xcode10.2' into master-merge-xcode10.2 2019-04-03 13:57:31 -04:00
Manuel de la Pena 1cb12aec0a
[Jenkins] Increase the Jenkins timeout since tests are taking longer now. (#5797) 2019-03-23 15:04:56 +01:00
Tim Miller 567b60b4f4 Add Additional Metadata Generation During Builds (#5718)
Updates the jenkinsFile to include generating ci-checkout.json and dependency-info.json.

ci-checkout.json is a list of all of the repositories included in the workspace of the project and their respective hashs.

dependency-info.json includes all of the info in ci-checkout.json, as well as a scan of the containing cs/fsproj files and their containing package and project references.
2019-03-07 08:42:13 +01:00
Rolf Bjarne Kvinge c02fdb8565 Xcode 10.2 requires macOS Mojave. 2019-01-28 06:19:26 +01:00
Rolf Bjarne Kvinge 4ea181e95b [jenkins] Don't execute the packaged XM tests on the main macOS version. (#5165)
* [jenkins] Don't execute the packaged XM tests on the main macOS version.

Don't execute the packaged XM tests on the main macOS version, since it's redundant.

It also prevents a potential test deadlock if all main bots are busy.

* Rework to make it show better in the Jenkins UI.
2019-01-28 06:17:56 +01:00
Rolf Bjarne Kvinge 0075415c39
[xharness] Add support for GitHub authentication, and use it in Jenkins. (#5380)
This makes it much less probable to hit any rate limits, because authenticated
rate limits are much higher (5000 requests/hour vs 60 requests/hour).
2019-01-11 15:48:16 +01:00
Rolf Bjarne Kvinge 61bf0db817
[tests] Run tests-docs using xharness. (#5372)
Jenkins has a limitation where you can't mark a step a failure, it has to
*fail* to be reported as such.

This means that running multiple tests, and reporting a failure if any of
those tests fail is not possible.

We run into this with the normal test run + the docs tests; where we currently
don't show a red result in the UI if any of those fail.

So incorporate the test-docs step into xharness, so that we only have one
thing to in the Jenkinsfile, which makes it possible for us to fail the test
run step properly.

This also required a few upgrades to xharness to get more info for pull
requests, since the logic to enable the docs tests is a bit more complicated
than anything else we have (if the current branch (or the target branch for a
PR) is 'master' AND xamarin mode is enabled).
2019-01-10 16:43:02 +01:00
Rolf Bjarne Kvinge 03d2b7d0b7
[jenkins] Add links to the packages in the GitHub comment. (#5301) 2018-12-20 07:34:57 +01:00
Rolf Bjarne Kvinge b21eb28b72
[jenkins] Improve rendering of failures on older macOS bots. (#5304)
Improve rendering of failures on older macOS bots by showing which bot things
failed on in the commit comment.
2018-12-20 07:34:23 +01:00
Rolf Bjarne Kvinge c8aa44beff
[jenkins] Print out the environment for debug purposes. (#5261)
This can be quite useful when writing new CI logic.
2018-12-12 15:01:03 +01:00
Rolf Bjarne Kvinge 82634c088a
[jenkins] If provisioning an old mono fails with error 56, try again a few more times. Fixes maccore#1098. (#5200)
It seems curl can randomly fail with error 56, so if that happens, try again a
few more times before giving up.

Fixes https://github.com/xamarin/maccore/issues/1098.
2018-11-29 18:37:04 +01:00
Rolf Bjarne Kvinge 94d87ddba6
[jenkins] Don't execute the packaged XM tests on the main macOS version. (#5165)
* [jenkins] Don't execute the packaged XM tests on the main macOS version.

Don't execute the packaged XM tests on the main macOS version, since it's redundant.

It also prevents a potential test deadlock if all main bots are busy.

* Rework to make it show better in the Jenkins UI.
2018-11-21 12:21:57 -05:00
Rolf Bjarne Kvinge 6f54cb7c28
Bump maccore to get fix for test-docs. (#5163)
* Bump maccore to get fix for test-docs.

Commit list for xamarin/maccore:

* xamarin/maccore@6e9b63e537 Merge pull request #1162 from rolfbjarne/docfixer-fixes
* xamarin/maccore@4cf1d63b7b [docfixer] Create project files and fix a few issues. Fixes #1118.
* xamarin/maccore@714bd73a55 [docfixer] Avoid declaring the same target twice.
* xamarin/maccore@34f4bfa339 [populate] Directories need to call Directory.Exists for existence checks.
* xamarin/maccore@341333db88 [docs] Remove truly ancient and outdated targets to publish updated docs.

Diff: 7ba9c5a962...6e9b63e537

* [jenkins] Make it possible to force docs testing by applying a label to pull requests.
2018-11-21 10:11:55 -05:00
Rolf Bjarne Kvinge abbc4698d6
[jenkins] Improve failure reporting slightly by listing 'Test docs' and 'Test run' as failing stages in the commit comment. (#5150) 2018-11-21 01:45:39 -05:00
Rolf Bjarne Kvinge 5761691c21
[jenkins] Fix slack reporting, and make it more resilient against failures. Fixes maccore#1160. (#5142)
* [jenkins] Fix getting author name+email for Slack reporting.

* [jenkins] Make slack reporting more resilient against failures. Fixes maccore#1160.

Fixes https://github.com/xamarin/maccore/issues/1160.
2018-11-20 02:55:57 -05:00
Rolf Bjarne Kvinge e3f97c56dd
[jenkins] Run the 'Test docs' step even if the 'Run tests' step failed. (#5106)
This is done by preventing the 'Run tests' failure from throwing exceptions, and instead manually set failure modes.
2018-11-08 16:24:56 +01:00
Sam Schwarz d0d28f8200 Without this added the azure links in the side panel won't work. This step can also be updated to the new pipeline syntax using the pipeline syntax generator. (#5081) 2018-11-05 19:22:24 +01: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
Connor Adsit 3f728dacac Report updateinfo for xamarin.ios and xamarin.mac in artifacts.json (#4871) (#4943)
Expose the productId and versionId in artifacts.json to autofill this information in while publishing so it's less of a manual process.
2018-10-08 09:28:42 +02:00
Connor Adsit fc0de6dee6 Report updateinfo for xamarin.ios and xamarin.mac in artifacts.json (#4871)
Expose the productId and versionId in artifacts.json to autofill this information in while publishing so it's less of a manual process.
2018-10-03 08:25:46 +02:00