69ae4eb39395297cd730283ca24687370311bced
[kconfig-hardened-check.git] / .github / workflows / main.yml
1 name: functional test
2
3 on:
4   push:
5     branches: [ master ]
6   pull_request:
7     branches: [ master ]
8
9 jobs:
10   check_all_configs:
11
12     runs-on: ubuntu-latest
13
14     strategy:
15       max-parallel: 4
16       fail-fast: false
17       matrix:
18         python-version: [3.6, 3.7, 3.8]
19         # github runner with python 3.5 currently fails to install this package
20
21     steps:
22
23 #   - uses: actions/checkout@v2
24
25     - name: Set up Python ${{ matrix.python-version }}
26       uses: actions/setup-python@v1
27       with:
28         python-version: ${{ matrix.python-version }}
29
30     - name: Install
31       run: |
32         python -m pip install --upgrade pip
33         pip --verbose install git+https://github.com/a13xp0p0v/kconfig-hardened-check
34
35     - name: Try
36       run: |
37         kconfig-hardened-check
38
39     - name: Check all configs
40       run: |
41         echo ">>>>> check all configs <<<<<"
42         CONFIG_DIR=`find /opt/hostedtoolcache/Python/ -name config_files`
43         CONFIGS=`find $CONFIG_DIR -type f|grep "\.config"`
44         COUNT=0
45         for C in $CONFIGS
46         do
47                 COUNT=$(expr $COUNT + 1)
48                 echo -e "\n>>>>> checking config number $COUNT <<<<<"
49                 kconfig-hardened-check -c $C || exit
50         done
51         echo -e "\n>>>>> checking $COUNT configs is done <<<<<"