Skip to content

full-check.yml: Test expected output more thoroughly #66

full-check.yml: Test expected output more thoroughly

full-check.yml: Test expected output more thoroughly #66

Workflow file for this run

name: full-check
on: [push, pull_request]
jobs:
build:
strategy:
fail-fast: false
matrix:
include:
- cc: gcc-13
clang_major_version: null
runs-on: ubuntu-22.04
- cc: clang-18
clang_major_version: 18
runs-on: ubuntu-22.04
runs-on: ${{ matrix.runs-on }}
steps:
- uses: actions/checkout@v4
- name: clang_repo
if: "${{ contains(matrix.cc, 'clang') }}"
run: |
set -x
source /etc/os-release
wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add -
sudo add-apt-repository "deb http://apt.llvm.org/${UBUNTU_CODENAME}/ llvm-toolchain-${UBUNTU_CODENAME}-${{ matrix.clang_major_version }} main"
- name: clang_install
if: "${{ contains(matrix.cc, 'clang') }}"
run: |-
sudo apt-get update
sudo apt-get install --yes --no-install-recommends -V \
clang-${{ matrix.clang_major_version }} \
libclang-rt-${{ matrix.clang_major_version }}-dev
- name: first_build
run: |
./autogen.sh
./configure CC=${{ matrix.cc }} CFLAGS='-std=c99 -Wall -Wextra -pedantic'
make
sudo make install
sudo make uninstall
make distclean
- name: second_build
run: |
./autogen.sh
./configure CC=${{ matrix.cc }} \
CFLAGS='-fsanitize=address -fno-omit-frame-pointer' \
LDFLAGS='-fsanitize=address'
make
sudo make install
- name: run_program
run: |
dcfldd if=.github/workflows/test.txt of=/tmp/test2.txt hash=md5,sha1,sha256,sha384,sha512 2>.github/workflows/actual-stderr.txt
diff -u .github/workflows/{actual,expected}-stderr.txt
ls -lh /tmp/test2.txt
head -n3 /tmp/test2.txt | grep -i autopkgtest
- name: test_make_dist
run: |
make distclean
./autogen.sh
./configure CC=${{ matrix.cc }}
make dist
mkdir test_dist
mv dcfldd-*.tar.gz test_dist
cd test_dist
pwd
tar -xvf dcfldd-*.tar.gz
rm -f dcfldd-*.tar.gz
cd dcfldd-*
./autogen.sh
./configure CC=${{ matrix.cc }}
make
ls
sudo make install
sudo make uninstall
make distclean