cuda-unit-test.yml 874 Bytes
Newer Older
1
2
3
4
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.

trigger:
5
  - main
6
7
8
9
10
11
12
13
14

pool:
  name: SuperBench CI
  vmImage: ubuntu-latest

container:
  image: nvcr.io/nvidia/pytorch:20.12-py3

steps:
15
16
17
  - script: |
      echo "##vso[task.prependpath]$HOME/.local/bin"
    displayName: Export path
18
19
  - script: |
      python3 -m pip install .[test,torch]
20
      make postinstall
21
    displayName: Install dependencies
22
  - script: |
23
      SB_MICRO_PATH=$PWD/bin make cppbuild
24
    displayName: Build benchmarks
25
26
27
28
  - script: |
      python3 setup.py lint
    displayName: Run code lint
  - script: |
29
      SB_MICRO_PATH=$PWD/bin python3 setup.py test
30
    displayName: Run unit tests
31
    timeoutInMinutes: 10
32
  - script: |
33
      bash <(curl -s https://codecov.io/bash) -cF cuda-unit-test
34
    displayName: Report coverage results
35
36
    env:
      CODECOV_TOKEN: $(codecovToken)