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

97 Коммитов

Автор SHA1 Сообщение Дата
Rolf Bjarne Kvinge 8bf4e0e5e6
[tests] Fix sample tests to take into account when a platform has been disabled. (#9774)
* [tests] Fix sample tests to take into account when a platform has been disabled.

* [devops] The INCLUDE_MAC/INCLUDE_IOS variables might not exist.
2020-10-06 17:33:03 +02:00
Manuel de la Pena dcb0c93ab0 [Xcode12] Bring xcode 12 changes into main. 2020-09-23 16:05:22 -04:00
Connor Adsit 746e26f6ac
Use provisionator built-ins for custom functions (#9671) 2020-09-22 14:24:02 -04:00
Manuel de la Pena eb9b690fe0 Merge xcode12 into d16-8. 2020-09-18 17:51:52 -04:00
Alex Soto 8383b14382
[xcode12] Rename master to main (#9631)
* Fix links that point to master to point to main instead.
* Implement support in the sample tester for specifying the default branch for
  each sample repo.
* Fix various text / documentation to say 'main' instead of 'master.'
* Push to 'main' instead of 'master' in xamarin-macios-data.
* Fix xharness to make 'main' the special branch with regards to documentation tests as opposed to 'master'.
* Fix various CI to use 'main' instead of 'master'.

This is a backport of PR #9561
2020-09-15 07:09:29 -04:00
monojenkins ab3839a7d6
[DevOps] As with jenkins, remove old simulators. (#9552)
Co-authored-by: Manuel de la Pena <mandel@microsoft.com>
2020-08-31 18:00:53 -04:00
Manuel de la Pena 36ca984c12
[DevOps] As with jenkins, remove old simulators. (#9551) 2020-08-31 13:19:34 -04:00
monojenkins 4526ed6110
[d16-8] [DevOps] Set the status to pending once the checks have started. (#9448)
Once we have done all the check of the bot, set the status of the commit
to pending since the next task is going to run the tests.

This way we ensure that the pending status should be cleaned at the end
rather than be left behind.


Co-authored-by: Manuel de la Pena <mandel@microsoft.com>
2020-08-24 10:57:09 -04:00
Manuel de la Pena db0ac65975
[DevOps] Set the status to pending once the checks have started. (#9444)
Once we have done all the check of the bot, set the status of the commit
to pending since the next task is going to run the tests.

This way we ensure that the pending status should be cleaned at the end
rather than be left behind.
2020-08-21 10:29:11 -04:00
monojenkins 0ad3c4757c
[d16-8] [DevOps] Report the correct bot used. (#9404)
The tests are not executed in the same agent that sets the github
status, for that reason, the github comment is not giving the correct
bot name, but the name of the bot that executed the commit message and
not the tests.

Add an output var in the runTests step to set the bot name and pass it
to the comment job in a different bot.


Co-authored-by: Whitney Schmidt <whschm@microsoft.com>
Co-authored-by: Manuel de la Pena <mandel@microsoft.com>
2020-08-19 17:46:24 -04:00
monojenkins e2fc755347
[DevOps] Just clean the xamarin-macios dir to ensure we do not delete maccore creds. (#9397)
The credentials for maccore are downloaded to a pat file (to be found).
When we call make git-clean, because we do use the -x options, all
files are deleted, including the pat file.

We move to call git clean -xdf inside xamarin-macios, which will delete
the test result files.

Once we find the exact path pattern, we can update the make git-clean to
not remove them but this commit unblocks the failing CI builds.

Co-authored-by: Manuel de la Pena <mandel@microsoft.com>
2020-08-18 17:40:40 -04:00
Manuel de la Pena c20cbfe301
[DevOps] Just clean the xamarin-macios dir to ensure we do not delete maccore creds. (#9396)
The credentials for maccore are downloaded to a pat file (to be found).
When we call make git-clean, because we do use the -x options, all
files are deleted, including the pat file.

We move to call git clean -xdf inside xamarin-macios, which will delete
the test result files.

Once we find the exact path pattern, we can update the make git-clean to
not remove them but this commit unblocks the failing CI builds.
2020-08-18 15:11:59 -04:00
Sebastien Pouliot dafef3dfea
[tools] Fix message typo in device-tests.yml (#9373) 2020-08-14 09:02:03 -04:00
Manuel de la Pena 53dcedc060
[DevOps] Add missing envi var to ensure we can set the status of the build. (#9263) 2020-08-03 16:21:52 -04:00
Manuel de la Pena ec30ba0f6b
[DevOps] Report the correct bot used. (#9250)
* [DevOps] Report the correct bot used.

The tests are not executed in the same agent that sets the github
status, for that reason, the github comment is not giving the correct
bot name, but the name of the bot that executed the commit message and
not the tests.

Add an output var in the runTests step to set the bot name and pass it
to the comment job in a different bot.

* Update tools/devops/device-tests/scripts/GitHub.psm1

Co-authored-by: Whitney Schmidt <whschm@microsoft.com>

Co-authored-by: Whitney Schmidt <whschm@microsoft.com>
2020-07-30 21:29:02 -04:00
Manuel de la Pena f2ce1b885a
[DevOps] The powershell in Windows is older, we do not support the param. (#9223) 2020-07-30 17:36:21 -04:00
Manuel de la Pena 77965e03ce
[DevOps] Both labs use the same utility pool, lets keep it in one place. (#9225) 2020-07-30 10:08:14 -04:00
Manuel de la Pena c54065c2cf
[DevOps] If test fail but pipeline builds, set the correct status. (#9161)
Depending on the pipeline run, we should have the following result:

* failed: issues with bots or provisioning (red in the UI)
* partiallySucceeded: no issues with bots but failing tests.
* succeeded: no issues with bots and all tests pass.

This adds a psh cmdlet that allows to set the result AND sets the
correct result when we have test failures.


Co-authored-by: Whitney Schmidt <whschm@microsoft.com>
2020-07-29 16:58:47 -04:00
Manuel de la Pena 820859b7ab
[DevOps] Clean all before we run the tests. (#9172) (#9182) 2020-07-28 16:35:59 -04:00
Manuel de la Pena 5d60d6d1c9
[Devops] Use the deployment pool. (#9160) 2020-07-23 15:50:19 -04:00
Manuel de la Pena 685a616de0
[DevOps] Clean all before we run the tests. (#9172) 2020-07-23 15:45:55 -04:00
Manuel de la Pena fcc410f36a
[DevOps] Add debugging messages from when we fail the ./configure (#9102)
Some bots are giving error with this step. Try to add some verbosity and
ensure that $? is 0 when done.
2020-07-15 20:13:57 -04:00
Manuel de la Pena 3fccc1e3e0
[DevOps] If we cannot clear the hd, continue. (#9101)
Few things:

1. Move from Write-Error to Write-Debug so that we do not set the exit
code and an error.
2. Ig we fail in the Clear-HD step, continue, we should be ok or cancel
if not enough space is found.
2020-07-15 20:13:34 -04:00
Manuel de la Pena f13fe4ba30
[DevOps] In a self-hosted pool we need to specify the os. (#9100) 2020-07-15 18:51:37 -04:00
Manuel de la Pena 773df34fde
[DevOps] Fix issues with the xm storage path. (#9043)
* [DevOps] Fix issues with the xm stroage path.

For some reason, and it is very probably a bug in the azurepipelines,
the following bash code creates a path with an extra single quote at the
end:

```bash
 P=jenkins/xamarin-macios/$BUILD_LANE/$BUILD_REVISION/$ID/device-tests

echo "##vso[task.setvariable variable=XM_STORAGE_PATH]$P"
```

* Should it do it? Not, it should not.
* Does it do it? Yes, it does.

We work around it via td -d \'\" and remove all single and double quotes
in the string. How long did it take to discover this? More than it
should have.

There is another interesting bug with the variable expansion, the
following
```bash
echo '##vso[task.setvariable variable=XAMARIN_STORAGE_PATH;isOutput=true]$P'
```
Does not equal
```bash
echo '##vso[task.setvariable variable=XAMARIN_STORAGE_PATH;isOutput=true]'$P
```

The first will not expand the variable, the second one will. We do need
the value of $P not '$P'.


Co-authored-by: Whitney Schmidt <51677938+whitneyschmidt@users.noreply.github.com>
2020-07-10 17:19:59 -04:00
Manuel de la Pena 9eff2f2964
[DevOps] Move back to self hosted windows pools. (#9040)
The microsoft hosted images have a limit of 10gb, or logs are getting
close to that size when expanded, therefore we will get into issues.
Move back to the self-hosted pool before we have problems.
2020-07-08 18:57:56 -04:00
Manuel de la Pena f4d165863a
[DevOps] Clean all workspaces and try to fix our space problems. (#9028) 2020-07-07 18:45:50 -04:00
Manuel de la Pena ce244b7ccd
[DevOps] Release device bots as soon as possible. (#8979)
The upload of the results takes 2 hours:

* 1 hour uploading to vsts test results.
* 1 hour uploading to vsdrops.

This means that we are blocking a device bot for an extra hours (since
the vsdrops is done in a windows bot) when it is not needed. We could
add both uploads to the vsdrops job, but since steps cannot be ran in
parallel, it means that we re waiting for 2 hours when we really do not
have to.

We create two jobs to parallelize the upload of files and we release the
device bot ASAP. That means that our device bots can be free to get new
jobs (and they are the bottle neck) while the windows bots perform the
different uploads.

To make things easier a template that downloads the artifacts was added
so that there is not much code repetition.
2020-06-30 22:19:54 -04:00
Manuel de la Pena b0bcbb2272
[DevOps] Explicitly allow empty xamarin storage paths. (#8977) 2020-06-30 13:15:54 -04:00
Manuel de la Pena 2372a6cfcd
[DevOps] Fix stupid param mistake. (#8971) 2020-06-26 18:27:43 -04:00
Manuel de la Pena 9c91a4ec3c
[DevOp] Allow $amarinStorage to be empty. (#8963)
pwsh will complain if a mandatory parameter is empty. Remove the attr
and allow it to be empty since the if statements do check fir it.
2020-06-26 16:51:21 -04:00
Manuel de la Pena 74dc21d71e
[DevOps] fix quotes. (#8959) 2020-06-26 08:02:05 -04:00
Whitney Schmidt 5580e873ca
[DevOps] Add error handling for incorrect storage path (#8958)
* add error handling for storage path

* Revert "add error handling for storage path"

This reverts commit 751e54c254.

* revert whitespace changes, only add real change

* small fixes
2020-06-25 18:10:54 -04:00
Manuel de la Pena 2daa9088cd
[DevOps] Add the agent name to find the porivioning issues faster. (#8953)
Add the name of the agent that is added by the pipeline on the comments
posted in github.
2020-06-25 09:54:07 -04:00
Manuel de la Pena bf57e81467
[DevOps] Fix broken link. (#8952) 2020-06-25 08:56:14 -04:00
Manuel de la Pena 00a8a13df8
[DevOps] Return a success even when Clear-HD has issues. (#8951)
This is a workaround since in some bot we hit issue https://github.com/PowerShell/PowerShell/issues/9246
2020-06-25 08:55:50 -04:00
Manuel de la Pena 13bd5d2d59
[DevOps] Clean summary message. (#8945) 2020-06-24 19:36:05 -04:00
Manuel de la Pena 88c9276a09
[DevOps] Using netcat over ssh to check if port is open. (#8946)
Nicer than failing on ssh and faster to check if the ssh port is open.
2020-06-24 19:35:37 -04:00
Manuel de la Pena 8c081605a0
[DevOps] Allow to use vsdrops AND xamarin storage. (#8916)
Use both in those labs that support xamarin-storage so that we have a
backup. To do so, move the parameter to be a bool but keep the rest of
the logic the same.


Co-authored-by: Rolf Bjarne Kvinge <rolf@xamarin.com>
2020-06-24 18:01:51 -04:00
Manuel de la Pena 3cf2fc1316
[DevOps] Do not fail the tests is xamarin-storage cannot be reached. (#8912)
Try to create the folder in xamarin-storage, if that fails, rather than
stop with an error, execute the tests and st an env var.

Once the tests are complete, when adding the summaries, check if we did
fail to reach xamarin-storage and notify it.

This will make sure that tests won't fail if:

* xamarin-storage dies.
* bots are not in the vpn and could not reach xamarin-storage.
2020-06-19 20:18:35 -04:00
Manuel de la Pena 670d68c86c
[DevOps] Improve the comments added in GitHub. (#8898)
Comments were ugly. Clean a little the markdown.
2020-06-19 11:45:21 -04:00
Manuel de la Pena 78730b8ceb
[DevOps] Update contexts to be more clear. (#8896)
The contexts are the ones that link a status with a device run. Update
them so that we do know the labe used (and remove a typo where we used
TvOS).
2020-06-18 17:10:01 -04:00
Manuel de la Pena 1b6b5dec20
[Devops] Use correct variables template on ddfun tvos pipeline. (#8895) 2020-06-18 15:28:47 -04:00
Manuel de la Pena 96e14746b3
[Devops] Fix typo in beta device pipeline. (#8894) 2020-06-18 15:15:37 -04:00
Manuel de la Pena ed8a00152e
[Devops] Add support for yaml pipelines in the old device pipelines. (#8862)
This commit moves all the different pipelines we have to fully use yaml.
That includes the old ddfun pipeline that was using a mix between using
yaml and the UI interface to configure it.

The new pipelines are found under the tools/devops/device-tests
directory. All of the use a very similar structure and therefore we use
a template. The README.md inside the directory should explain most of
the logic and the devices-tests.yml contains comments for each of the
steps.

Most of the bash scripts have been moved to use pwsh which is inside the
scripts directory and contains tests. Tests can be ran via:

```bash
make -C tools/devops/device-tests/scripts run-tests
```

This commit will only affect the ddfun pipeline that will need to be
updated to use the new yml path. All the other pipelines are not
affected and they will be to be updated manually.

The pipelines support two different storages for the html report.

* xamarin-storage: Old school.
* vsdrops: New age.

Unfortunatly we yet do not know how to workaround the fact that vsdrops
does not serve the files, therefore we use the xamarin-storage in all
pipelines but those in the ddfun lab because they do not have the right
access.

This later can be easily changed editing the
tools/devops/device-tests/tempaltes/cambridge-variables.yml which will
update all the pipelines in the cambridge lab.

PS: Sorry for the size.
2020-06-18 14:15:59 -04:00
Manuel de la Pena 602fb4a675
[d16-7][Devops] Move to main rather than using a testing branch. (#8878) 2020-06-17 17:02:03 -04:00
Manuel de la Pena 1d5557c328
[DevOps] Move away from a testing branch and use main. (#8874) 2020-06-17 12:59:44 -04:00
Manuel de la Pena a20f8ddcbe
[Devtools] Do not try to install tools via brew if present.] (#8872) 2020-06-17 11:27:26 -04:00
Rolf Bjarne Kvinge 95e42b9266
Rename master to main. (#8851)
* Fix links that point to master to point to main instead.
* Implement support in the sample tester for specifying the default branch for
  each sample repo.
* Fix various text / documentation to say 'main' instead of 'master.'
* Push to 'main' instead of 'master' in xamarin-macios-data.
* Fix xharness to make 'main' the special branch with regards to documentation tests as opposed to 'master'.
* Fix various CI to use 'main' instead of 'master'.
* Bump maccore

    New commits in xamarin/maccore:

    * xamarin/maccore@ed6d146822 Rename 'master' to 'main'. (#2233)

    Diff: 424fa26148..ed6d146822
2020-06-16 15:51:44 +02:00
Alex Soto 52509f9925
[devops] Add Policheck tool to our pipeline (#8802)
New commits in xamarin/maccore:

* xamarin/maccore@714066a4b6 Add PoliCheckExclusions.xml (#2228) (#2229)

Diff: ef861db73e..714066a4b6
2020-06-08 15:16:04 -04:00