|
78 | 78 | displayName: 'Get legacy checkpoints'
|
79 | 79 |
|
80 | 80 | - bash: |
|
81 |
| - python -m coverage run --source pytorch_lightning -m pytest pytorch_lightning tests -v --durations=50 |
| 81 | + python -m pytest pytorch_lightning tests -v --cov=pytorch_lightning --junitxml=$(Build.StagingDirectory)/test-results.xml --durations=50 |
82 | 82 | displayName: 'Testing: standard'
|
83 | 83 |
|
84 | 84 | - bash: |
|
|
88 | 88 | - bash: |
|
89 | 89 | python -m coverage report
|
90 | 90 | python -m coverage xml
|
91 |
| - codecov --token=$(CODECOV_TOKEN) --flags=gpu,pytest --name="GPU-coverage" --env=linux,azure |
| 91 | + python -m coverage html |
| 92 | + python -m codecov --token=$(CODECOV_TOKEN) --commit=$(Build.SourceVersion) --flags=gpu,pytest --name="GPU-coverage" --env=linux,azure |
| 93 | + ls -l |
92 | 94 | displayName: 'Statistics'
|
93 | 95 |
|
| 96 | + - task: PublishTestResults@2 |
| 97 | + displayName: 'Publish test results' |
| 98 | + inputs: |
| 99 | + testResultsFiles: '$(Build.StagingDirectory)/test-results.xml' |
| 100 | + testRunTitle: '$(Agent.OS) - $(Build.DefinitionName) - Python $(python.version)' |
| 101 | + condition: succeededOrFailed() |
| 102 | + |
| 103 | + - task: PublishCodeCoverageResults@1 |
| 104 | + displayName: 'Publish coverage report' |
| 105 | + inputs: |
| 106 | + codeCoverageTool: 'cobertura' |
| 107 | + summaryFileLocation: 'coverage.xml' |
| 108 | + reportDirectory: '$(Build.SourcesDirectory)/htmlcov' |
| 109 | + testRunTitle: '$(Agent.OS) - $(Build.BuildNumber)[$(Agent.JobName)] - Python $(python.version)' |
| 110 | + condition: succeededOrFailed() |
| 111 | + |
94 | 112 | - bash: |
|
95 | 113 | python -m pytest benchmarks -v --maxfail=2 --durations=0
|
96 | 114 | displayName: 'Testing: benchmarks'
|
|
0 commit comments