12 runs-on: ubuntu-latest
18 # Current ubuntu-latest (Ubuntu 22.04) provides the following versions of Python:
19 python-version: ['3.7', '3.8', '3.9', '3.10', '3.11']
23 - name: Set up Python ${{ matrix.python-version }}
24 uses: actions/setup-python@v4
26 python-version: ${{ matrix.python-version }}
28 - name: Install package
30 python -m pip install --upgrade pip
31 echo "Install the package via pip..."
32 pip --verbose install git+https://github.com/a13xp0p0v/kconfig-hardened-check
33 echo "Run the installed tool..."
34 kconfig-hardened-check
36 - name: Check all configs with the installed tool
38 echo "Check all configs with the installed tool..."
39 CONFIG_DIR=`find /opt/hostedtoolcache/Python/ -name config_files`
40 KCONFIGS=`find $CONFIG_DIR -type f | grep -e "\.config" -e "\.gz"`
44 COUNT=$(expr $COUNT + 1)
45 echo -e "\n>>>>> checking kconfig number $COUNT <<<<<"
46 kconfig-hardened-check -c $C -l /proc/cmdline
48 echo -e "\nHave checked $COUNT kconfigs"
50 - name: Get source code for collecting coverage
51 uses: actions/checkout@v3
53 - name: Run the functional tests and collect the coverage
56 sh .github/workflows/functional_test.sh
58 - name: Prepare final coverage report
60 coverage xml -i -o coverage.xml
62 - name: Handle coverage
63 uses: codecov/codecov-action@v3
66 flags: functional_test
67 name: functional_test_upload
68 fail_ci_if_error: true