@@ -12,63 +12,41 @@ jobs:
12
12
variables :
13
13
azure_tmpdir : $(Agent.TempDirectory)
14
14
devtools : $(azure_tmpdir)/devtools
15
- test_dir : mushr_rhc_ros/test
15
+ CatkinProjectDir : /catkin_ws/src/$(Build.Repository.Name)
16
16
17
- container : prlmushr/mushr:xenial
17
+ container : prlmushr/mushr:bionic
18
18
19
19
steps :
20
- - script : git clone https://github.com/prl-mushr/devtools.git $(devtools)
20
+ - bash : git clone https://github.com/prl-mushr/devtools.git $(devtools)
21
21
displayName : Get devtools
22
22
23
- - bash : |
24
- sudo apt-get update
25
- wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh
26
- bash miniconda.sh -b -p $HOME/miniconda
27
- echo "##vso[task.prependpath]$HOME/miniconda/bin"
28
- displayName: 'Get conda and add to path'
29
-
30
- - bash : |
31
- conda config --set always_yes yes --set changeps1 no
32
- conda update -q conda
33
- conda env create --file $(devtools)/lint-env.yaml
34
- displayName: Install dependencies and create Anaconda environment
35
-
36
- - bash : |
37
- set -e
38
- source activate lint
39
- source /opt/ros/"$ROS_DISTRO"/setup.bash
40
-
41
- $(devtools)/bin/mushr_lint_flake8 .
23
+ - bash : /ros_entrypoint.sh $(devtools)/bin/mushr_lint_flake8 .
42
24
displayName : flake8
43
25
condition : succeededOrFailed()
44
26
45
- - bash : |
46
- set -e
47
- source activate lint
48
- source /opt/ros/"$ROS_DISTRO"/setup.bash
49
-
50
- $(devtools)/bin/mushr_lint_isort . --check
27
+ - bash : /ros_entrypoint.sh $(devtools)/bin/mushr_lint_isort . --check
51
28
displayName : isort
52
29
condition : succeededOrFailed()
53
30
54
- - bash : |
55
- set -e
56
- source activate lint
57
- source /opt/ros/"$ROS_DISTRO"/setup.bash
58
-
59
- $(devtools)/bin/mushr_lint_black . --check
31
+ - bash : /ros_entrypoint.sh $(devtools)/bin/mushr_lint_black . --check
60
32
displayName : black
61
33
condition : succeededOrFailed()
62
34
63
35
- bash : |
64
- source activate lint
65
- source /opt/ros/"$ROS_DISTRO"/setup.bash
36
+ source /opt/ros/melodic/setup.bash
37
+
38
+ sudo chown -R $(whoami) /catkin_ws
66
39
67
- sudo rosdep init
68
- rosdep update
40
+ mkdir -p $(CatkinProjectDir)
41
+ cp -r * $(CatkinProjectDir)
69
42
70
- # You can add any preamble here (install packages, load configuration, etc.) to setup testing
43
+ cd /catkin_ws
44
+ # build and source setup files
45
+ catkin_make
46
+ source devel/setup.bash
71
47
72
- python -m nose2 -v --pretty-assert -s $(test_dir)
73
- displayName: Run tests (nose2)
48
+ # test
49
+ cd $(CatkinProjectDir)
50
+ ./test.sh
51
+ displayName: Run tests
74
52
condition: succeededOrFailed()
0 commit comments