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

26 Коммитов

Автор SHA1 Сообщение Дата
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
Vincent Dondain 2174ec41a2 Merge branch 'xcode10' 2018-09-18 14:12:39 -04:00
Rolf Bjarne Kvinge 985547bd1e
[jenkins] Bump the keychain lock timeout from 2h to 6h. Fixes maccore#973. (#4733)
Our tests can take quite a while to run sometimes, and this makes sure we
don't get random failures when the tests that access the keychain are executed
at the end of the test run.

Bump maccore to get the same fix there.

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

Commit diff for maccore bump: 9937926f56...07fde84362
2018-08-31 14:39:42 +02:00
Vincent Dondain eec95e881c Merge branch 'd15-8' into xcode10-rebase-15.8 2018-08-13 21:04:56 -04:00
Rolf Bjarne Kvinge 3dcfdd47dd
[jenkins] Add support for completely skipping the public jenkins job using a label. (#4333)
This can be useful when working on the support for private jenkins, since many
of those changes can only be tested as a pull request, and they also tend to
include a lot of commits (because nothing can be tested locally).

So until whatever needs implementing for private jenkins is complete and
working, there's no need for the public bots to do anything for such pull
requests.
2018-06-26 15:50:54 +02:00
Rolf Bjarne Kvinge 3334d54a47
[jenkins] Allow codesign without permission dialogs as well. (#4220) (#4223) 2018-06-12 09:03:30 -07:00
Rolf Bjarne Kvinge ae7c72cba8 Add support for building on Jenkins. (#4159)
Add support for building on internal Jenkins.

Jenkins has been configured to build every branch on xamarin/xamarin-macios that contains a `jenkins/Jenkinsfile`, which means it will start working as soon as this PR is merged.

Results will be posted as statuses on each commit, which can be viewed using the url `https://github.com/xamarin/xamarin-macios/commits/<branch>`:

![screenshot 2018-06-01 11 12 57](https://user-images.githubusercontent.com/249268/40832932-c3b05eb0-658c-11e8-9670-8de5fcc23407.png)

* The `continuous-integration/jenkins/branch` status links to the jenkins job.
* The other two are XI and XM packages (the `Jenkins-` prefix will be removed once we officially switch from Wrench to Jenkins).

More detailed information will be added as a comment to each commit, which can be seen by clicking on the commit and scrolling to the bottom (url of the format `https://github.com/xamarin/xamarin-macios/commit/<sha1>`)

![screenshot 2018-06-01 11 14 33](https://user-images.githubusercontent.com/249268/40833014-fd8772f4-658c-11e8-8a35-5df46bfb16c7.png)

Unfortunately GitHub does not display the commit statuses when viewing a single commit, so to view those statuses you'll have to view the list of commits (the `/commits/` url). Tip: it's possible to use `<sha1>` instead of `<branch>` (and vice versa for that matter) if you're interested in the statuses of a particular commit.

Pull requests will also be built (only from contributors with write access), but by default nothing will be done (the job will exit immediately, although a green check mark will still show up). Jenkins will **not** add a comment in the pull request in this case.

However, if the label `build-package` [1] is set for a pull request, the internal jenkins job will run (it will do everything except the local xharness test run: this includes creating and publishing packages, creating various diffs, run tests on older macOS versions, test docs, etc). A detailed comment will also be added to the pull request (see below for multiple examples), which means that there will be two Jenkins comments: one for the public Jenkins which builds every PR, and one for the internal Jenkins [2].

[1] I don't quite like the name of the label, because it doesn't get even close to explain all that will actually happen, but `run-on-internal-jenkins-and-create-package` is a bit too long IMHO... Also it's non-obvious that this is the label to apply if the reason for executing on the internal jenkins is some other reason (for instance to test a maccore bump). Other ideas:

* `run-internal-jenkins`: doesn't make it obvious that a package will be created (which is probably the most common reason to want to run on internal jenkins)
* We could have multiple labels that mean the same thing: `build-package`, `internal-build`, `run-internal-jenkins`, etc, but it's redundant and I don't quite like it either.
* Any other ideas?

[2] I'm noticing now that these two look quite similar and this might end up confusing (the main difference is that the comment from the public jenkins will say **Build success/failure** and **Build comment file:** at the top. If something goes wrong the failure will also show up differently). Should this be made clearer?
2018-06-12 14:37:03 +02:00
Rolf Bjarne Kvinge f7527aaba2 [jenkins] Revert unintended change that prevents the keychain from unlocking properly. (#4158) 2018-06-12 14:37:03 +02:00
Rolf Bjarne Kvinge e0e2f93176 [jenkins] Fix scripts to be shellcheck-happy. (#4148)
A few general categories of fixes:

* Sprinkle lots of quotes everywhere.
* Don't use environment variables in the format string to printf, instead pass them as arguments.
* Don't use backticks to execute commands (it's deprecated), use the new "$(...)" syntax instead.
2018-06-12 14:37:03 +02:00
Rolf Bjarne Kvinge 96d3445ccf [tests] Make sure accessing the keychain doesn't make macOS show any dialogs. (#4141) 2018-06-12 14:37:03 +02:00
Rolf Bjarne Kvinge c35adef145 [jenkins] Update the urls for html reports. (#4119)
* [jenkins] Update the urls for html reports.

The urls for html reports changed as a consequence of a Jenkins update [1], so
update how we construct the links accordingly.

See also:

* https://xamarinhq.slack.com/archives/C03CCJNR7/p1526646040000120
* https://xamarinhq.slack.com/archives/C03CCJNR7/p1526653512000249

[1] https://wiki.jenkins.io/display/JENKINS/HTML+Publisher+Plugin (update to v1.16)

* Remove extra closing parenthesis.
2018-06-12 14:37:03 +02:00
Sebastien Pouliot fb322c4d15 [jenkins] Clean keystore on bots before running tests (#3754)
Because if invalid data gets into the store then some unit tests
will always fail on that particular bot.

Fix https://github.com/xamarin/maccore/issues/640
2018-06-12 14:37:03 +02:00
Rolf Bjarne Kvinge 90b6c17946
[jenkins] Allow codesign without permission dialogs as well. (#4220) 2018-06-12 05:21:28 -07:00
Rolf Bjarne Kvinge 29d671b51a
Add support for building on Jenkins. (#4159) (#4180)
* Add support for building on Jenkins. (#4159)

Add support for building on internal Jenkins.

Jenkins has been configured to build every branch on xamarin/xamarin-macios that contains a `jenkins/Jenkinsfile`, which means it will start working as soon as this PR is merged.

Results will be posted as statuses on each commit, which can be viewed using the url `https://github.com/xamarin/xamarin-macios/commits/<branch>`:

![screenshot 2018-06-01 11 12 57](https://user-images.githubusercontent.com/249268/40832932-c3b05eb0-658c-11e8-9670-8de5fcc23407.png)

* The `continuous-integration/jenkins/branch` status links to the jenkins job.
* The other two are XI and XM packages (the `Jenkins-` prefix will be removed once we officially switch from Wrench to Jenkins).

More detailed information will be added as a comment to each commit, which can be seen by clicking on the commit and scrolling to the bottom (url of the format `https://github.com/xamarin/xamarin-macios/commit/<sha1>`)

![screenshot 2018-06-01 11 14 33](https://user-images.githubusercontent.com/249268/40833014-fd8772f4-658c-11e8-8a35-5df46bfb16c7.png)

Unfortunately GitHub does not display the commit statuses when viewing a single commit, so to view those statuses you'll have to view the list of commits (the `/commits/` url). Tip: it's possible to use `<sha1>` instead of `<branch>` (and vice versa for that matter) if you're interested in the statuses of a particular commit.

Pull requests will also be built (only from contributors with write access), but by default nothing will be done (the job will exit immediately, although a green check mark will still show up). Jenkins will **not** add a comment in the pull request in this case.

However, if the label `build-package` [1] is set for a pull request, the internal jenkins job will run (it will do everything except the local xharness test run: this includes creating and publishing packages, creating various diffs, run tests on older macOS versions, test docs, etc). A detailed comment will also be added to the pull request (see below for multiple examples), which means that there will be two Jenkins comments: one for the public Jenkins which builds every PR, and one for the internal Jenkins [2].

[1] I don't quite like the name of the label, because it doesn't get even close to explain all that will actually happen, but `run-on-internal-jenkins-and-create-package` is a bit too long IMHO... Also it's non-obvious that this is the label to apply if the reason for executing on the internal jenkins is some other reason (for instance to test a maccore bump). Other ideas:

* `run-internal-jenkins`: doesn't make it obvious that a package will be created (which is probably the most common reason to want to run on internal jenkins)
* We could have multiple labels that mean the same thing: `build-package`, `internal-build`, `run-internal-jenkins`, etc, but it's redundant and I don't quite like it either.
* Any other ideas?

[2] I'm noticing now that these two look quite similar and this might end up confusing (the main difference is that the comment from the public jenkins will say **Build success/failure** and **Build comment file:** at the top. If something goes wrong the failure will also show up differently). Should this be made clearer?

* Make the Jenkins packages official.

* [Jenkins] Create artifacts.json and set a GH status as 'Jenkins: Artifacts'.

* [jenkins] Include the url in artifacts.json

* [jenkins] Add sha256 checksum to artifacts.json as well.

* [Jenkins] Enable xamarin before provisioning so that we auto-provision Xcode.

* [jenkins] Fix passing flags to configure.

Quoting empty CONFIGURE_FLAGS ends up doing this:

    ./configure "" --disable-ios-device

and since configure parses arguments until it finds an empty argument, it
would stop parsing at the first argument, effectively not disabling the device
build.

So don't quote CONFIGURE_FLAGS when invoking configure. shellcheck doesn't
quite like this, but the better code is much more complex, and not really
needed, so just add an exception.
2018-06-07 07:08:14 -07:00
Rolf Bjarne Kvinge dbe1051da4
Add support for building on Jenkins. (#4159)
Add support for building on internal Jenkins.

Jenkins has been configured to build every branch on xamarin/xamarin-macios that contains a `jenkins/Jenkinsfile`, which means it will start working as soon as this PR is merged.

Results will be posted as statuses on each commit, which can be viewed using the url `https://github.com/xamarin/xamarin-macios/commits/<branch>`:

![screenshot 2018-06-01 11 12 57](https://user-images.githubusercontent.com/249268/40832932-c3b05eb0-658c-11e8-9670-8de5fcc23407.png)

* The `continuous-integration/jenkins/branch` status links to the jenkins job.
* The other two are XI and XM packages (the `Jenkins-` prefix will be removed once we officially switch from Wrench to Jenkins).

More detailed information will be added as a comment to each commit, which can be seen by clicking on the commit and scrolling to the bottom (url of the format `https://github.com/xamarin/xamarin-macios/commit/<sha1>`)

![screenshot 2018-06-01 11 14 33](https://user-images.githubusercontent.com/249268/40833014-fd8772f4-658c-11e8-8a35-5df46bfb16c7.png)

Unfortunately GitHub does not display the commit statuses when viewing a single commit, so to view those statuses you'll have to view the list of commits (the `/commits/` url). Tip: it's possible to use `<sha1>` instead of `<branch>` (and vice versa for that matter) if you're interested in the statuses of a particular commit.

Pull requests will also be built (only from contributors with write access), but by default nothing will be done (the job will exit immediately, although a green check mark will still show up). Jenkins will **not** add a comment in the pull request in this case.

However, if the label `build-package` [1] is set for a pull request, the internal jenkins job will run (it will do everything except the local xharness test run: this includes creating and publishing packages, creating various diffs, run tests on older macOS versions, test docs, etc). A detailed comment will also be added to the pull request (see below for multiple examples), which means that there will be two Jenkins comments: one for the public Jenkins which builds every PR, and one for the internal Jenkins [2].

[1] I don't quite like the name of the label, because it doesn't get even close to explain all that will actually happen, but `run-on-internal-jenkins-and-create-package` is a bit too long IMHO... Also it's non-obvious that this is the label to apply if the reason for executing on the internal jenkins is some other reason (for instance to test a maccore bump). Other ideas:

* `run-internal-jenkins`: doesn't make it obvious that a package will be created (which is probably the most common reason to want to run on internal jenkins)
* We could have multiple labels that mean the same thing: `build-package`, `internal-build`, `run-internal-jenkins`, etc, but it's redundant and I don't quite like it either.
* Any other ideas?

[2] I'm noticing now that these two look quite similar and this might end up confusing (the main difference is that the comment from the public jenkins will say **Build success/failure** and **Build comment file:** at the top. If something goes wrong the failure will also show up differently). Should this be made clearer?
2018-06-04 19:40:16 -04:00
Rolf Bjarne Kvinge c3e6d2f2c0 [jenkins] Revert unintended change that prevents the keychain from unlocking properly. (#4158) 2018-05-29 16:42:43 -04:00
Rolf Bjarne Kvinge c993da4c3b
[jenkins] Fix scripts to be shellcheck-happy. (#4148)
A few general categories of fixes:

* Sprinkle lots of quotes everywhere.
* Don't use environment variables in the format string to printf, instead pass them as arguments.
* Don't use backticks to execute commands (it's deprecated), use the new "$(...)" syntax instead.
2018-05-29 11:03:54 -04:00
Rolf Bjarne Kvinge 0845efd80f
[tests] Make sure accessing the keychain doesn't make macOS show any dialogs. (#4141) 2018-05-29 07:18:03 -04:00
Rolf Bjarne Kvinge 35ea4630fc
[jenkins] Update the urls for html reports. (#4119)
* [jenkins] Update the urls for html reports.

The urls for html reports changed as a consequence of a Jenkins update [1], so
update how we construct the links accordingly.

See also:

* https://xamarinhq.slack.com/archives/C03CCJNR7/p1526646040000120
* https://xamarinhq.slack.com/archives/C03CCJNR7/p1526653512000249

[1] https://wiki.jenkins.io/display/JENKINS/HTML+Publisher+Plugin (update to v1.16)

* Remove extra closing parenthesis.
2018-05-24 09:04:14 -04:00
Rolf Bjarne Kvinge 15e3bf39ce
[d15-7] [jenkins] Create comment file for PR builds. (#3799) (#3859)
* [jenkins] Create comment file for PR builds. (#3799)

* [jenkins] Create comment file for PR builds.

* [tools] Create stamp file after doing things that might modify files we care about. (#3864)

We have consistency checks to verify that no unexpected files are modified
done when comparing APIs in for a pull request.

Unfortunately the check didn't take into account that checking out the
revision to do the API check against might modify some of the files in the
consistency check itself, thus triggering the consistency check.

Fix this by only verify timestamps of files modified after checkout out the
revision, which is the only thing we care about anyway.

For examples see PR #3855 or PR #3850.

* [jenkins] Don't succeed if something went wrong when creating API or generator diff. (#3865)

Ref: https://github.com/xamarin/xamarin-macios/pull/3855#issuecomment-378441993
2018-04-05 07:37:08 +02:00
Rolf Bjarne Kvinge d267a508d5
[jenkins] Don't succeed if something went wrong when creating API or generator diff. (#3865)
Ref: https://github.com/xamarin/xamarin-macios/pull/3855#issuecomment-378441993
2018-04-04 15:36:30 +02:00
Rolf Bjarne Kvinge 9d2a886f86
[jenkins] Create comment file for PR builds. (#3799)
* [jenkins] Create comment file for PR builds.
2018-04-02 14:49:03 +02:00
Sebastien Pouliot 9c58c4513a
[jenkins] Clean keystore on bots before running tests (#3754)
Because if invalid data gets into the store then some unit tests
will always fail on that particular bot.

Fix https://github.com/xamarin/maccore/issues/640
2018-03-15 12:25:53 -05:00
Sam Schwarz 098011f67d Update run-tests to use file. (#2789) 2017-09-27 19:31:19 +02:00
Manuel de la Pena aa38ab68ac [Jenkins] Add nuint xml logs (#883)
* [Jenkins] Make test to write output as an xml file so that it can be parsed by the jenkins bot.

* Point to the correct Touvh.Unit repo.

* Use the available property to determine if we are being ran in Jenkins.

* Log where are test results stored.

* Add @MonkeyWrench: prefix.

* Ensure that we do set the build env in jenkins/run-tests.sh

* Do not mix Wrench with Jenkins. The reports in jenkins can be Xml, in Wrench we prefer the old style.

* Ensure that the main node of the unit tests does contain the target, that will improve the tests results reporting.

* Revert "Fix binding project LinkWithAttributes generation to prevent rebuilds" (#1018)

* Added xslt to be used to keep the old Test Reports until we move to only Jenkins reports.

* Add an extra log for the xslt transformation.

* Point to the correcto dir in jenkins.

* Deal with the xslt once we have finished rather than in a batch.

* Remove noise.

* Readd case removed in rebase.

* Fix indentation.

* Skip lock keychain.
2016-11-15 19:04:37 +01:00
Manuel de la Pena 009c8a0aa2 [Jenkins] Add different steps to be executed in jenkins. (#856)
* [Jenkins] Add different steps to be executed in jenkins.

* Remove old jenkins.sh
2016-09-21 16:46:00 +02:00