diff --git a/.github/workflows/config.yml b/.github/workflows/config.yml index 223614529..1fdc57c70 100644 --- a/.github/workflows/config.yml +++ b/.github/workflows/config.yml @@ -149,14 +149,14 @@ jobs: export EXTRA_DEB=${{ matrix.EXTRA_DEB }} export ROS_DISTRO=${{ matrix.ROS_DISTRO }} export ROS_PARALLEL_TEST_JOBS="-j2" - export CATKIN_PARALLEL_JOBS="-i" + export CATKIN_PARALLEL_JOBS="-i -j2" export ROSDEP_ADDITIONAL_OPTIONS="-n -q -r --ignore-src --skip-keys=python-google-cloud-texttospeech-pip --skip-keys=python-dialogflow-pip" # Skip installation of grpcio by pip because it causes error export BEFORE_SCRIPT="sudo pip install virtualenv==15.1.0" export USE_TRAVIS=true export USE_DOCKER=false export DOCKER_IMAGE=${{ matrix.CONTAINER }} export NOT_TEST_INSTALL=true - export ROS_PARALLEL_JOBS="--make-args LANG=C.UTF-8 LC_ALL=C.UTF-8" + export ROS_PARALLEL_JOBS="-j8 --make-args LANG=C.UTF-8 LC_ALL=C.UTF-8" set +o nounset export CI_SOURCE_PATH=$(pwd) diff --git a/dialogflow_task_executive/requirements.in.noetic b/dialogflow_task_executive/requirements.in.noetic index 7fe2d496f..63615e454 100644 --- a/dialogflow_task_executive/requirements.in.noetic +++ b/dialogflow_task_executive/requirements.in.noetic @@ -3,3 +3,4 @@ google-api-core[grpc]==1.33.0 grpcio-status==1.48.1 googleapis-common-protos[grpc]==1.56.2 protobuf==3.20.1 # fix Could not find a version that matches protobuf<4.0.0dev,<5.0.0dev,>=3.15.0,>=3.20.1,>=4.21.3 (from google-api-core[grpc]==1.33.1->dialogflow==1.1.1->-r requirements.in (line 1)) +grpcio==1.54.0 # via google-api-core, googleapis-common-protos, grpcio-status diff --git a/dialogflow_task_executive/test/test_rospy_node.py b/dialogflow_task_executive/test/test_rospy_node.py index 318d6c8d6..a56f75054 100644 --- a/dialogflow_task_executive/test/test_rospy_node.py +++ b/dialogflow_task_executive/test/test_rospy_node.py @@ -27,11 +27,15 @@ def test_rosnode(self): full_scripts_dir = os.path.join(pkg_dir, scripts_dir) if not os.path.exists(full_scripts_dir): continue - for filename in [f for f in map(lambda x: os.path.join(full_scripts_dir, x), os.listdir(full_scripts_dir)) if os.path.isfile(f) and f.endswith('.py')]: + for filename in [f for f in map(lambda x: x, os.listdir(full_scripts_dir)) if os.path.isfile(f) and f.endswith('.py')]: print("Check if {} is loadable".format(filename)) - # https://stackoverflow.com/questions/4484872/why-doesnt-exec-work-in-a-function-with-a-subfunction - exec(open(filename, encoding='utf-8').read()) in globals(), locals() - self.assertTrue(True) + import subprocess + try: + ret = subprocess.check_output(['rosrun', pkg_name, filename], stderr=subprocess.STDOUT) + except subprocess.CalledProcessError as e: + print("Catch runtime error ({}), check if this is expect".format(e.output)) + self.assertTrue('Check the device is connected and recognized' in e.output) + if __name__ == '__main__': rostest.rosrun('test_rospy_node', pkg_name, TestRospyNode, sys.argv) diff --git a/dialogflow_task_executive/test/test_rospy_node.test b/dialogflow_task_executive/test/test_rospy_node.test index e47acaf68..c692f54ca 100644 --- a/dialogflow_task_executive/test/test_rospy_node.test +++ b/dialogflow_task_executive/test/test_rospy_node.test @@ -1,3 +1,3 @@ <launch> - <test pkg="dialogflow_task_executive" type="test_rospy_node.py" test-name="ros_rospy_node" /> + <test pkg="dialogflow_task_executive" type="test_rospy_node.py" test-name="ros_rospy_node" time-limit="120" retry="3" /> </launch> diff --git a/julius_ros/test/julius.test b/julius_ros/test/julius.test index 06cfce3b1..361fc0259 100644 --- a/julius_ros/test/julius.test +++ b/julius_ros/test/julius.test @@ -15,7 +15,7 @@ <node name="rosbag_play" pkg="rosbag" type="play" args="--delay 10 $(find julius_ros)/test/wave.bag" /> - <test test-name="test_julius_dnn_$(arg dnn)" pkg="julius_ros" type="test_julius.py" time-limit="60" > + <test test-name="test_julius_dnn_$(arg dnn)" pkg="julius_ros" type="test_julius.py" time-limit="120" retry="3" > <rosparam subst_value="true"> dnn: $(arg dnn) </rosparam>