abc03e25ac928820093aa698cd250c0dcff2e910
[osm/tests.git] / devops-stages / stage-test.sh
1 #!/bin/sh
2 # Licensed under the Apache License, Version 2.0 (the "License");
3 # you may not use this file except in compliance with the License.
4 # You may obtain a copy of the License at
5 #
6 # http://www.apache.org/licenses/LICENSE-2.0
7 #
8 # Unless required by applicable law or agreed to in writing, software
9 # distributed under the License is distributed on an "AS IS" BASIS,
10 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
11 # implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
14 # python3 -m rflint testsuites
15 echo "Checking tabs in robot files. No tabs should be present"
16 tabs_in_testsuite="y"
17 tabs_in_lib="y"
18 ! grep -ri " " robot-systest/testsuite && tabs_in_testsuite=""
19 ! grep -ri " " robot-systest/lib && tabs_in_lib=""
20 [ -n "${tabs_in_testsuite}" ] && echo "There are tabs in robot-systest/testsuite" && exit 1
21 [ -n "${tabs_in_lib}" ] && echo "There are tabs in robot-systest/lib" && exit 1
22 echo "No tabs are present in robot files"
23 exit 0
24