Skip to content

Commit

Permalink
Testing setting screen res on AzureCIs
Browse files Browse the repository at this point in the history
  • Loading branch information
Greg Blumberg committed Jan 12, 2019
1 parent df71071 commit b4ae265
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 19 deletions.
34 changes: 15 additions & 19 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,31 +10,27 @@ trigger:
# https://docs.microsoft.com/azure/devops/pipelines/languages/javascript?view=vsts
strategy:
matrix:

linux:
imageName: 'ubuntu-16.04'
screen_w: 1280
screen_h: 1024
screen_d: 8
mac:
imageName: 'macos-10.13'
screen_w: 1280
screen_h: 1024
screen_d: 8
windows:
imageName: 'vs2017-win2016'

screen_w: 1280
screen_h: 1024
screen_d: 8

pool:
vmImage: $(imageName)

steps:
#- script: sudo install -d -m 0777 /usr/local/miniconda/
# displayName: Fix Conda permissions (Mac)
# condition: eq( variables['Agent.OS'], 'Darwin')

#- script: sudo install -d -m 0777 /usr/share/miniconda/
# displayName: Fix Conda permissions (Linux)
# condition: eq( variables['Agent.OS'], 'Linux')

#- script: echo "HELLO"
# displayName: Fix Conda permissions (Windows)
# condition: eq( variables['Agent.OS'], 'Windows_NT')

- task: CondaEnvironment@1
displayName: 'Install Conda and packages'
Expand All @@ -43,14 +39,8 @@ steps:
packageSpecs: 'python=3 numpy=1.15.* pyside pytest pip python-dateutil requests setuptools'
installOptions: '-q -c conda-forge'

#- script: |
# which python
# conda activate test-env
# conda install -y -c conda-forge numpy=1.15.* pyside pytest pip python-dateutil requests setuptools
# displayName: "Install packages"

- script: which python & which pip & conda list
displayName: "Status"
displayName: "Dump Python Install Status"

- script: |
python setup.py -q install --user
Expand All @@ -70,13 +60,19 @@ steps:
- script: |
system_profiler SPDisplaysDataType | grep Resolution
sudo python ci/screen.py
sudo chmod +x ci/cscreen
./ci/cscreen -x $(screen_w) -y $(screen_h) -d $(screen_d)
sudo python ci/screen.py
sudo python setup.py -q install
sudo pytest -v
sudo mv examples/data/14061619.png examples/data/14061619_mac.png
displayName: "Installing code and running tests (macOS)"
condition: eq( variables['Agent.OS'], 'Darwin')

- script: |
python ci/screen.py
PowerShell -Command "iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/set-screenresolution.ps1'))"
PowerShell -Command {Set-ScreenResolution $(screen_w) $(screen_h)}
python ci/screen.py
python setup.py -q install --user
pytest -v
Expand Down
Binary file added ci/cscreen
Binary file not shown.

0 comments on commit b4ae265

Please sign in to comment.