azure-pipelines-integrationtests.yml 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. # Starter pipeline
  2. # Start with a minimal pipeline that you can customize to build and deploy your code.
  3. # Add steps that build, run tests, deploy, and more:
  4. # https://aka.ms/yaml
  5. trigger:
  6. - master
  7. jobs:
  8. - job: Mac
  9. pool:
  10. name: 'AvaloniaMacPool'
  11. steps:
  12. - task: UseDotNet@2
  13. displayName: 'Use .NET Core SDK 6.0.404'
  14. inputs:
  15. version: 6.0.404
  16. - task: UseDotNet@2
  17. displayName: 'Use .NET Core SDK 7.0.101'
  18. inputs:
  19. version: 7.0.101
  20. - script: system_profiler SPDisplaysDataType |grep Resolution
  21. - script: |
  22. pkill node
  23. appium &
  24. pkill IntegrationTestApp
  25. ./build.sh CompileNative
  26. rm -rf $(osascript -e "POSIX path of (path to application id \"net.avaloniaui.avalonia.integrationtestapp\")")
  27. pkill IntegrationTestApp
  28. ./samples/IntegrationTestApp/bundle.sh
  29. open -n ./samples/IntegrationTestApp/bin/Debug/net7.0/osx-arm64/publish/IntegrationTestApp.app
  30. pkill IntegrationTestApp
  31. - task: DotNetCoreCLI@2
  32. inputs:
  33. command: 'test'
  34. projects: 'tests/Avalonia.IntegrationTests.Appium/Avalonia.IntegrationTests.Appium.csproj'
  35. - script: |
  36. pkill IntegrationTestApp
  37. pkill node
  38. - job: Windows
  39. pool:
  40. vmImage: 'windows-2022'
  41. steps:
  42. - task: UseDotNet@2
  43. displayName: 'Use .NET Core SDK 6.0.404'
  44. inputs:
  45. version: 6.0.404
  46. - task: UseDotNet@2
  47. displayName: 'Use .NET Core SDK 7.0.101'
  48. inputs:
  49. version: 7.0.101
  50. - task: Windows Application Driver@0
  51. inputs:
  52. OperationType: 'Start'
  53. AgentResolution: '4K'
  54. displayName: 'Start WinAppDriver'
  55. - task: DotNetCoreCLI@2
  56. inputs:
  57. command: 'build'
  58. projects: 'samples/IntegrationTestApp/IntegrationTestApp.csproj'
  59. - task: DotNetCoreCLI@2
  60. retryCountOnTaskFailure: 3
  61. inputs:
  62. command: 'test'
  63. projects: 'tests/Avalonia.IntegrationTests.Appium/Avalonia.IntegrationTests.Appium.csproj'
  64. - task: Windows Application Driver@0
  65. inputs:
  66. OperationType: 'Stop'
  67. displayName: 'Stop WinAppDriver'